We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent e8a0c87 commit d046919Copy full SHA for d046919
clang/test/SemaCXX/builtin-invoke.cpp
@@ -72,6 +72,14 @@ class std::reference_wrapper<InvalidSpecialization2> {
72
InvalidSpecialization2& get(); // expected-note 2 {{declared private here}}
73
};
74
75
+struct Incomplete; // expected-note {{forward declaration}}
76
+struct Incomplete2;
77
+
78
+void incomplete_test(Incomplete& incomplete) {
79
+ __builtin_invoke((int (Incomplete2::*)){}, incomplete); // expected-error {{incomplete type 'Incomplete' used in type trait expression}} \
80
+ expected-error {{indirection requires pointer operand ('Incomplete' invalid)}}
81
+}
82
83
void call() {
84
__builtin_invoke(func);
85
__builtin_invoke(nfunc);
0 commit comments