https://gcc.gnu.org/bugzilla/show_bug.cgi?id=107539
--- Comment #1 from Franck Behaghel <franckbehaghel_gcc at protonmail dot com> --- Created attachment 53836 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=53836&action=edit main.cpp reduced testcase : g++ main.cpp main.cpp: In lambda function: main.cpp:222:61: internal compiler error: same canonical type node for different types ‘AlgorithmTemplate<typename decltype (algorithm)::type>’ and ‘AlgorithmTemplate<typename decltype (algorithm)::type>’ 222 | visitor (identity<AlgorithmTemplate<NewAlgorithm>> ()); | ^~