Douglas Gregor
0fea62d0c7
For a C++ delete expression where the operand is of class type that
...
has a single conversion to pointer-to-object type, implicitly convert
to that pointer-to-object type (C++ [expr.delete]p1).
llvm-svn: 81401
2009-09-09 23:39:55 +00:00
Anders Carlsson
2418712039
Fix an off by one error when trying to perform copy initialization of operator new and operator delete arguments. Sebastian, please review.
...
llvm-svn: 72670
2009-05-31 19:49:47 +00:00
Sebastian Redl
4d226cf45f
When there are any member new operators, global versions aren't looked up at all.
...
llvm-svn: 71780
2009-05-14 18:11:41 +00:00
Douglas Gregor
ac1fb65d0c
Make sure to use RequireCompleteType rather than testing for
...
incomplete types. RequireCompleteType is needed when the type may be
completed by instantiating a template.
llvm-svn: 67643
2009-03-24 19:52:54 +00:00
Daniel Dunbar
a45cf5b6b0
Rename clang to clang-cc.
...
Tests and drivers updated, still need to shuffle dirs.
llvm-svn: 67602
2009-03-24 02:24:46 +00:00
Sebastian Redl
1df2bbe7f9
Update new expression to make use of Declarator::getSourceRange().
...
References are not objects; implement this in Type::isObjectType().
llvm-svn: 64152
2009-02-09 18:24:27 +00:00
Sebastian Redl
2175b6a767
Make one expected-diag directive match exactly one actual diagnostic.
...
This uncovers some bugs, so several test cases now fail.
llvm-svn: 64025
2009-02-07 19:52:04 +00:00
Douglas Gregor
dd430f7ec9
Centralize error reporting of improper uses of incomplete types in the
...
new DiagnoseIncompleteType. It provides additional information about
struct/class/union/enum types when possible, either by pointing to the
forward declaration of that type or by pointing to the definition (if
we're in the process of defining that type).
Fixes <rdar://problem/6500531>.
llvm-svn: 62521
2009-01-19 19:26:10 +00:00
Sebastian Redl
33a3101d43
Code cleanup in new handling.
...
llvm-svn: 60557
2008-12-04 22:20:51 +00:00
Sebastian Redl
f84512a360
Fix some diagnostics and enhance test cases. Now tests member new and ambiguous overloads.
...
llvm-svn: 60542
2008-12-04 17:24:46 +00:00
Sebastian Redl
faf6808e7a
Overload resolution for the operator new function. Member version is still untested.
...
llvm-svn: 60503
2008-12-03 20:26:15 +00:00
Sebastian Redl
db36b9b962
Make the parser handle ::new and ::delete correctly.
...
llvm-svn: 60421
2008-12-02 16:35:44 +00:00
Sebastian Redl
351bb78a10
Handle new by passing the Declaration to the Action, not a processed type.
...
llvm-svn: 60413
2008-12-02 14:43:59 +00:00
Douglas Gregor
3ff3cf5f21
Test another error message, make sure to verify C++ new and delete tests
...
llvm-svn: 60007
2008-11-25 04:08:05 +00:00
Chris Lattner
03c4041cb5
make the 'to match this' diagnostic a note.
...
llvm-svn: 59921
2008-11-23 23:17:07 +00:00
Sebastian Redl
bd150f431e
Implementation of new and delete parsing and sema.
...
This version uses VLAs to represent arrays. I'll try an alternative way next, but I want this safe first.
llvm-svn: 59835
2008-11-21 19:14:01 +00:00