summaryrefslogtreecommitdiffstats
path: root/clang/test/SemaCXX/overloaded-builtin-operators.cpp
diff options
context:
space:
mode:
authorRichard Smith <richard@metafoo.co.uk>2019-10-23 17:54:10 -0700
committerRichard Smith <richard@metafoo.co.uk>2019-10-24 14:58:29 -0700
commit70f59b5bbc84d195b4c7ee1597dcae4e73d3c479 (patch)
tree3ab997cf0cd33142c5ab9ded2cad4e6dacdfa8b5 /clang/test/SemaCXX/overloaded-builtin-operators.cpp
parent33fca97880d3bd6ab4888b6eeb72bddff536e37a (diff)
downloadbcm5719-llvm-70f59b5bbc84d195b4c7ee1597dcae4e73d3c479.tar.gz
bcm5719-llvm-70f59b5bbc84d195b4c7ee1597dcae4e73d3c479.zip
When diagnosing an ambiguity, only note the candidates that contribute
to the ambiguity, rather than noting all viable candidates.
Diffstat (limited to 'clang/test/SemaCXX/overloaded-builtin-operators.cpp')
-rw-r--r--clang/test/SemaCXX/overloaded-builtin-operators.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/clang/test/SemaCXX/overloaded-builtin-operators.cpp b/clang/test/SemaCXX/overloaded-builtin-operators.cpp
index 4fa376aed03..d237dfe6c09 100644
--- a/clang/test/SemaCXX/overloaded-builtin-operators.cpp
+++ b/clang/test/SemaCXX/overloaded-builtin-operators.cpp
@@ -194,10 +194,9 @@ struct A {
};
void test_dr425(A a) {
- // FIXME: lots of candidates here!
(void)(1.0f * a); // expected-error{{ambiguous}} \
// expected-note 4{{candidate}} \
- // expected-note {{remaining 140 candidates omitted; pass -fshow-overloads=all to show them}}
+ // expected-note {{remaining 8 candidates omitted; pass -fshow-overloads=all to show them}}
}
// pr5432
@@ -237,9 +236,10 @@ namespace PR8477 {
(void)(foo - zero);
(void)(zero + foo);
(void)(zero[foo]);
+ // FIXME: It would be nice to report fewer candidates here.
(void)(foo - foo); // expected-error{{use of overloaded operator '-' is ambiguous}} \
// expected-note 4{{built-in candidate operator-}} \
- // expected-note{{candidates omitted}}
+ // expected-note{{142 candidates omitted}}
return foo[zero] == zero;
}
}
OpenPOWER on IntegriCloud