================ @@ -115,3 +116,39 @@ static_assert(!noexcept(typeid((Polymorphic<true, false>&&) Polymorphic<true, fa static_assert(!noexcept(typeid(*&(const Polymorphic<true, true>&) Polymorphic<true, true>{}))); static_assert(!noexcept(typeid(*&(const Polymorphic<false, true>&) Polymorphic<false, true>{}))); static_assert(!noexcept(typeid(*&(const Polymorphic<true, false>&) Polymorphic<true, false>{}))); + +template<bool B> +struct X { + template<typename T> void f(); +}; +template<typename T> +void f1() { + X<noexcept(typeid(*T{}))> dependent; + dependent.f<void>(); + // expected-error@-1 {{use 'template' keyword to treat 'f' as a dependent template name}} ---------------- Sirraide wrote:
Perhaps I’m just being a bit slow today, but it took me a few seconds to realise that this is testing *whether* the `noexcept(...)` is correctly marked as dependent here; imo that deserves a comment so whoever looks at this next doesn’t end up as confused as I was just now https://github.com/llvm/llvm-project/pull/95846 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits