llvm/llvm-project

Clang elides the wrong part of the template type in error message.

Open

#180046 opened on Feb 5, 2026

View on GitHub
 (10 comments) (0 reactions) (0 assignees)C++ (26,378 stars) (10,782 forks)batch import
clang:frontendgood first issue

Description

Repro: https://godbolt.org/z/9bYzd3WPG

Error message:error: no viable conversion from returned value of type 'S3<S2<...>>' to function return type 'S3<S2<...>>'

Expected: error: no viable conversion from returned value of type 'S3<const S2<int>>' to function return type 'S3<S2<int>>'

Contributor guide