1 namespace ignore { 2 struct Dummy {}; 3 auto_ret(T x)4template <typename T> auto auto_ret(T x) { return 0; } with_tag()5[[gnu::abi_tag("test")]] int with_tag() { return 0; } with_tag_template()6template <typename T> [[gnu::abi_tag("test")]] int with_tag_template() { 7 return 0; 8 } 9 decltype_auto_ret(T x)10template <typename T> decltype(auto) decltype_auto_ret(T x) { return 0; } 11 } // namespace ignore 12 13 template <typename T> with_tag_template_returns_ignore(T x)14[[gnu::abi_tag("test")]] ignore::Dummy with_tag_template_returns_ignore(T x) { 15 return {}; 16 } 17 main()18int main() { 19 auto v1 = ignore::auto_ret<int>(5); 20 auto v2 = ignore::with_tag(); 21 auto v3 = ignore::decltype_auto_ret<int>(5); 22 auto v4 = ignore::with_tag_template<int>(); 23 auto v5 = with_tag_template_returns_ignore<int>(5); 24 } 25