This patch wants to fix inline friend decl like
template <class F1> int foo(F1 X); template <int A1> struct A { template <class F1> friend int foo(F1 X) { return A1; } }; template struct A<1>; int a = foo(1.0);
Differential D149009
[Sema]Select correct lexical context during template instantiate HerrCai0907 on Apr 22 2023, 10:42 PM. Authored by
Details This patch wants to fix inline friend decl like template <class F1> int foo(F1 X); template <int A1> struct A { template <class F1> friend int foo(F1 X) { return A1; } }; template struct A<1>; int a = foo(1.0);
Diff Detail
Event TimelineComment Actions
|
I was originally REALLY suspicious about this function call here (and the setup with the out parameter/2nd variable here). but it seems that the 'true' argument (which, needs a /*ParamName */ comment) is specifically designed for this situation.