*PING* [PATCH] c++: fix cases of core1001/1322 by not dropping cv-qualifier of function parameter of type of typename or decltype[PR101402,PR102033,PR102034,PR102039,PR102044]

2021-09-24 Thread nick huang via Gcc-patches
These bugs are considered duplicate cases of PR51851 which has been suspended since 2012, an issue known as "core1001/1322". Considering this background, it deserves a long comment to explain. Many people believed the root cause of this family of bugs is related with the nature of how and when

Re: *PING* [PATCH] c++: fix cases of core1001/1322 by not dropping cv-qualifier of function parameter of type of typename or decltype[PR101402,PR102033,PR102034,PR102039,PR102044]

2021-09-24 Thread Jason Merrill via Gcc-patches
I already responded to this patch: https://gcc.gnu.org/pipermail/gcc-patches/2021-September/579527.html

Re: *PING* [PATCH] c++: fix cases of core1001/1322 by not dropping cv-qualifier of function parameter of type of typename or decltype[PR101402,PR102033,PR102034,PR102039,PR102044]

2021-09-25 Thread nick huang via Gcc-patches
d of bugs. It happens during template function declaration stage #1 when producing template declarator. Instead of doing a later-correction-effort in PR92010, my patch tries to at least avoid dropping "const" in case of "typename" and "decltype" during template f

Re: *PING* [PATCH] c++: fix cases of core1001/1322 by not dropping cv-qualifier of function parameter of type of typename or decltype[PR101402,PR102033,PR102034,PR102039,PR102044]

2021-09-26 Thread nick huang via Gcc-patches
>>template >>struct A >>{ >> void f(T); >>}; >> >>template >>void A::f(const T) >>{ } >> >>which is certainly questionable code, but is currently also accepted by >>clang and EDG compilers. I just found out that clang actually correctly reject this code during specialization. (https://www.g

Re: *PING* [PATCH] c++: fix cases of core1001/1322 by not dropping cv-qualifier of function parameter of type of typename or decltype[PR101402,PR102033,PR102034,PR102039,PR102044]

2021-09-28 Thread Jason Merrill via Gcc-patches
On 9/25/21 15:15, nick huang wrote: Why doesn't the PR92010 fix address these testcases as well? 3. PR92010 creates new functions of "rebuild_function_or_method_type" and by using gdb to trace PR101402 code as following: template struct A { typedef T arr[3]; }; template void f(const typ