[clang] Fix assertion failure during conversion function overload resolution. (PR #98671)

Matheus Izvekov via cfe-commits cfe-commits at lists.llvm.org
Wed Jul 24 15:25:42 PDT 2024


mizvekov wrote:

> That said... an example like the following sidesteps all these issues and still crashes clang, so I think the above comments are somewhat orthogonal to this patch (except that I think we should have something like this as a test case instead of the current test case):
> 
> ```c++
> template<typename T> concept C = true;
> template<typename T> concept D = C<T> && true;
> 
> struct X {
>   template<C T> operator T();
>   template<D T> operator T();
> };
> 
> auto p = &X::operator int;
> ```

FYI that code should be affected by https://github.com/llvm/llvm-project/issues/18291
I am currently working on a fix for that issue, since it affects CWG2398 stuffs as well.

https://github.com/llvm/llvm-project/pull/98671


More information about the cfe-commits mailing list