[lld][WebAssembly] Reinstate mistakenly disabled test. NFC
[llvm-project.git] / clang / test / Parser / cxx-extra-virtual-specifiers.cpp
blobf09883424dc8a457c0b7158572d19126f26a01a7
1 // RUN: %clang_cc1 -fsyntax-only -verify -fdiagnostics-parseable-fixits %s
3 class A {
4 virtual void foo();
5 };
6 class B : public A {
7 void foo() override;
8 };
10 void B::foo() override {} // expected-error {{'override' specifier is not allowed outside a class definition}}
11 // CHECK: fix-it:"{{.*}}":{[[@LINE-1]]:15-[[@LINE-1]]:24}:""
13 void f1() override; // expected-error {{'override' specifier is not allowed}}
15 void f2() override {} // expected-error {{'override' specifier is not allowed}}
17 void test() {
18 void f() override; // expected-error {{'override' specifier is not allowed}}