https://gcc.gnu.org/bugzilla/show_bug.cgi?id=96960
Jason Merrill <jason at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |jason at gcc dot gnu.org Summary|ICE in |[C++20] ICE in |tsubst_copy_and_build, at |tsubst_copy_and_build, at |cp/pt.c:20531 from lambda |cp/pt.c:20531 from lambda |in return-type-requirement |in return-type-requirement --- Comment #2 from Jason Merrill <jason at gcc dot gnu.org> --- This has to do with type_deducible_p's use of tf_partial. That function is left over from the days before P1084; we still kind of treat return type requirements as deduction rather than simply checking the constraint. Though other places where we do need to do deduction work properly: C0<char [([] { return 42; }())]> auto x = 42; int f(C0<char [([] { return 42; }())]> auto x); int y = f(42);