summaryrefslogtreecommitdiff
path: root/test/SemaCXX/default1.cpp
diff options
context:
space:
mode:
authorDimitry Andric <dim@FreeBSD.org>2013-12-22 00:07:40 +0000
committerDimitry Andric <dim@FreeBSD.org>2013-12-22 00:07:40 +0000
commitbfef399519ca9b8a4b4c6b563253bad7e0eeffe0 (patch)
treedf8df0b0067b381eab470a3b8f28d14a552a6340 /test/SemaCXX/default1.cpp
parent6a0372513edbc473b538d2f724efac50405d6fef (diff)
Diffstat (limited to 'test/SemaCXX/default1.cpp')
-rw-r--r--test/SemaCXX/default1.cpp11
1 files changed, 8 insertions, 3 deletions
diff --git a/test/SemaCXX/default1.cpp b/test/SemaCXX/default1.cpp
index c8c197e153d4..b661776b6ef5 100644
--- a/test/SemaCXX/default1.cpp
+++ b/test/SemaCXX/default1.cpp
@@ -21,7 +21,7 @@ struct X {
X(int);
};
-void j(X x = 17);
+void j(X x = 17); // expected-note{{'::j' declared here}}
struct Y { // expected-note 2{{candidate}}
explicit Y(int);
@@ -46,8 +46,13 @@ int l () {
int i () {
void j (int f = 4);
{
- void j (int f); // expected-note{{'j' declared here}}
- j(); // expected-error{{too few arguments to function call, single argument 'f' was not specified}}
+ void j (int f);
+ j(); // expected-error{{too few arguments to function call, expected 1, have 0; did you mean '::j'?}}
+ }
+ void jj (int f = 4);
+ {
+ void jj (int f); // expected-note{{'jj' declared here}}
+ jj(); // expected-error{{too few arguments to function call, single argument 'f' was not specified}}
}
}