Author: aaronpuchert Date: Tue Jun 18 16:40:17 2019 New Revision: 363754 URL: http://llvm.org/viewvc/llvm-project?rev=363754&view=rev Log: Fix tests after r363749
We changed -Wmissing-prototypes there, which was used in these tests via -Weverything. Modified: cfe/trunk/test/Preprocessor/Weverything_pragma.c cfe/trunk/test/Preprocessor/pragma_diagnostic.c cfe/trunk/test/Preprocessor/pushable-diagnostics.c cfe/trunk/test/SemaCXX/warn-everthing.cpp Modified: cfe/trunk/test/Preprocessor/Weverything_pragma.c URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/test/Preprocessor/Weverything_pragma.c?rev=363754&r1=363753&r2=363754&view=diff ============================================================================== --- cfe/trunk/test/Preprocessor/Weverything_pragma.c (original) +++ cfe/trunk/test/Preprocessor/Weverything_pragma.c Tue Jun 18 16:40:17 2019 @@ -7,6 +7,7 @@ #define UNUSED_MACRO1 1 // expected-warning{{macro is not used}} void foo() // expected-warning {{no previous prototype for function}} +// expected-note@-1{{declare 'static' if the function is not intended to be used outside of this translation unit}} { // A diagnostic without DefaultIgnore, and not part of a group. (void) L'ab'; // expected-warning {{extraneous characters in character constant ignored}} Modified: cfe/trunk/test/Preprocessor/pragma_diagnostic.c URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/test/Preprocessor/pragma_diagnostic.c?rev=363754&r1=363753&r2=363754&view=diff ============================================================================== --- cfe/trunk/test/Preprocessor/pragma_diagnostic.c (original) +++ cfe/trunk/test/Preprocessor/pragma_diagnostic.c Tue Jun 18 16:40:17 2019 @@ -39,12 +39,15 @@ void ppo(){} // First test that we do no #pragma clang diagnostic warning "-Weverything" void ppp(){} // expected-warning {{no previous prototype for function 'ppp'}} +// expected-note@-1{{declare 'static' if the function is not intended to be used outside of this translation unit}} #pragma clang diagnostic ignored "-Weverything" // Reset it. void ppq(){} #pragma clang diagnostic error "-Weverything" // Now set to error void ppr(){} // expected-error {{no previous prototype for function 'ppr'}} +// expected-note@-1{{declare 'static' if the function is not intended to be used outside of this translation unit}} #pragma clang diagnostic warning "-Weverything" // This should not be effective void pps(){} // expected-error {{no previous prototype for function 'pps'}} +// expected-note@-1{{declare 'static' if the function is not intended to be used outside of this translation unit}} Modified: cfe/trunk/test/Preprocessor/pushable-diagnostics.c URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/test/Preprocessor/pushable-diagnostics.c?rev=363754&r1=363753&r2=363754&view=diff ============================================================================== --- cfe/trunk/test/Preprocessor/pushable-diagnostics.c (original) +++ cfe/trunk/test/Preprocessor/pushable-diagnostics.c Tue Jun 18 16:40:17 2019 @@ -23,17 +23,21 @@ void ppo0(){} // first verify that we do #pragma clang diagnostic warning "-Weverything" void ppr1(){} // expected-warning {{no previous prototype for function 'ppr1'}} +// expected-note@-1{{declare 'static' if the function is not intended to be used outside of this translation unit}} #pragma clang diagnostic push // push again #pragma clang diagnostic ignored "-Weverything" // Set to ignore in this level. void pps2(){} #pragma clang diagnostic warning "-Weverything" // Set to warning in this level. void ppt2(){} // expected-warning {{no previous prototype for function 'ppt2'}} +// expected-note@-1{{declare 'static' if the function is not intended to be used outside of this translation unit}} #pragma clang diagnostic error "-Weverything" // Set to error in this level. void ppt3(){} // expected-error {{no previous prototype for function 'ppt3'}} +// expected-note@-1{{declare 'static' if the function is not intended to be used outside of this translation unit}} #pragma clang diagnostic pop // pop should go back to warning level void pps1(){} // expected-warning {{no previous prototype for function 'pps1'}} +// expected-note@-1{{declare 'static' if the function is not intended to be used outside of this translation unit}} #pragma clang diagnostic pop // Another pop should disble it again Modified: cfe/trunk/test/SemaCXX/warn-everthing.cpp URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/test/SemaCXX/warn-everthing.cpp?rev=363754&r1=363753&r2=363754&view=diff ============================================================================== --- cfe/trunk/test/SemaCXX/warn-everthing.cpp (original) +++ cfe/trunk/test/SemaCXX/warn-everthing.cpp Tue Jun 18 16:40:17 2019 @@ -9,5 +9,6 @@ public: }; void testPR12271() { // expected-warning {{no previous prototype for function 'testPR12271'}} +// expected-note@-1{{declare 'static' if the function is not intended to be used outside of this translation unit}} PR12271 a[1][1]; } _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits