https://gcc.gnu.org/bugzilla/show_bug.cgi?id=84689
TC <rs2740 at gmail dot com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |rs2740 at gmail dot com --- Comment #1 from TC <rs2740 at gmail dot com> --- With library dependency removed: struct base { void operator()(int ) { } }; struct a : base { }; struct b : base { }; struct f: a, b { using a::operator(); using b::operator(); }; template<class T> auto g(int) -> decltype(T()(0), 0); template<class T> auto g(...) -> long; template<class, class> struct Same; template<class T> struct Same<T, T> {}; Same<decltype(g<f>(0)), long> s; Accepted by clang, rejected by gcc, who thinks that decltype(g<f>(0)) is int.