Apply the typo correction replacement location fix from r191450 to the
case when correcting for too many arguments (r191450 had only fixed the
problem for when there were too few arguments). Also fix the underlining
for both cases.
llvm-svn: 200268
diff --git a/clang/test/FixIt/typo-location-bugs.cpp b/clang/test/FixIt/typo-location-bugs.cpp
index 9c34a91..e44664d 100644
--- a/clang/test/FixIt/typo-location-bugs.cpp
+++ b/clang/test/FixIt/typo-location-bugs.cpp
@@ -19,3 +19,18 @@
pb->f(); // expected-error{{too few arguments to function call, expected 1, have 0; did you mean 'A::f'?}}
}
}
+
+namespace PR18608 {
+struct A {
+virtual void f() const;
+virtual void f(int x) const; // expected-note{{'A::f' declared here}}
+};
+
+struct B : public A {
+virtual void f() const;
+};
+
+void test(B b) {
+ b.f(1); // expected-error{{too many arguments to function call, expected 0, have 1; did you mean 'A::f'?}}
+}
+}