Wire up '-Wignored-qualifiers' to the warning on 'const' in 'const int f()'.
This flag and warning match GCC semantics. Also, move it to -Wextra as this is
a largely cosmetic issue and doesn't seem to mask problems. Subsequent fixes to
the tests which no longer by default emit the warning. Added explicit test
cases for both C and C++ behavior with the warning turned on.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@108325 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/test/SemaCXX/friend.cpp b/test/SemaCXX/friend.cpp
index 65e0da7..30abcbb 100644
--- a/test/SemaCXX/friend.cpp
+++ b/test/SemaCXX/friend.cpp
@@ -44,7 +44,7 @@
// PR5134
namespace test3 {
class Foo {
- friend const int getInt(int inInt = 0); // expected-warning{{'const' type qualifier on return type has no effect}}
+ friend const int getInt(int inInt = 0);
};
}