diff options
author | Fariborz Jahanian <fjahanian@apple.com> | 2009-09-15 22:15:23 +0000 |
---|---|---|
committer | Fariborz Jahanian <fjahanian@apple.com> | 2009-09-15 22:15:23 +0000 |
commit | 8b915e7048b20b0feb60ec90c365a8eb68360cd4 (patch) | |
tree | 10ef5cafce0554184195e95619ad0d59c898dd10 /test/SemaCXX/direct-initializer.cpp | |
parent | 13392aa6895bcdbbec4aa4abe48fb3d709f1e596 (diff) |
1) don't do overload resolution in selecting conversion
to pointer function for delete expression. 2)
Treat type conversion function and its 'const' version
as identical in building the visible conversion list.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@81930 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/SemaCXX/direct-initializer.cpp')
-rw-r--r-- | test/SemaCXX/direct-initializer.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/test/SemaCXX/direct-initializer.cpp b/test/SemaCXX/direct-initializer.cpp index e95ba22769..a9e2b2bb6e 100644 --- a/test/SemaCXX/direct-initializer.cpp +++ b/test/SemaCXX/direct-initializer.cpp @@ -36,15 +36,15 @@ void g() { } struct Base { - operator int*() const; // expected-note {{candidate function}} + operator int*() const; }; struct Derived : Base { - operator int*(); // expected-note {{candidate function}} + operator int*(); }; void foo(const Derived cd, Derived d) { - int *pi = cd; - int *ppi = d; // expected-error {{ambiguity in initializing value of type 'int *' with initializer of type 'struct Derived'}} + int *pi = cd; // expected-error {{incompatible type initializing 'struct Derived const', expected 'int *'}} + int *ppi = d; } |