[Bug c++/104652] It's impossible to declare non-first target function as a friend
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=104652 --- Comment #2 from Vorfeed Canal --- Thanks for showing a workaround: class Foo { public: explicit Foo(int f) : x(f) {} [[gnu::target("default")]] friend inline Foo bar(Foo& foo) { return Foo(foo.x); } [[gnu::target("
[Bug c++/104652] It's impossible to declare non-first target function as a friend
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=104652 Andrew Pinski changed: What|Removed |Added Ever confirmed|0 |1 Summary|It's impossible to