summaryrefslogtreecommitdiffstats
path: root/clang
Commit message (Collapse)AuthorAgeFilesLines
...
* Parse class-virt-specifier-seqs.Anders Carlsson2011-01-226-23/+95
| | | | llvm-svn: 124036
* More work on ClassVirtSpecifiers.Anders Carlsson2011-01-223-5/+37
| | | | llvm-svn: 124035
* Add test from PR9026.Rafael Espindola2011-01-221-1/+19
| | | | llvm-svn: 124034
* revert r123977 and r123978 to fix PR9026.Rafael Espindola2011-01-224-96/+78
| | | | llvm-svn: 124033
* Start stubbing out a ClassVirtSpecifiers class.Anders Carlsson2011-01-222-10/+34
| | | | llvm-svn: 124032
* A member function template cannot be virtual.Anders Carlsson2011-01-223-1/+16
| | | | llvm-svn: 124031
* Use a FunctionType::get overload that doesn't require an empty vector.Benjamin Kramer2011-01-221-5/+2
| | | | llvm-svn: 124029
* Improve our parse recovery on 'case blah;' and 'default;'.John McCall2011-01-222-6/+32
| | | | llvm-svn: 124025
* Send code generation for xvalues down the same path as lvaluesDouglas Gregor2011-01-222-2/+2
| | | | llvm-svn: 124023
* Debug info generation for rvalue referencesDouglas Gregor2011-01-222-6/+10
| | | | llvm-svn: 124020
* Update const_cast semantics for rvalue references. Add tests forDouglas Gregor2011-01-223-5/+37
| | | | | | reinterpret_cast and const_cast using rvalue references. llvm-svn: 124007
* Teach static_cast and dynamic_cast about rvalue references.Douglas Gregor2011-01-223-13/+51
| | | | llvm-svn: 124006
* Add a test for "perfect" forwardingDouglas Gregor2011-01-211-0/+22
| | | | llvm-svn: 124005
* Provide -Wuninitialized-experimental fixitsTed Kremenek2011-01-213-17/+34
| | | | | | | for floats, and also check if 'nil' is declared when suggesting it for initializing ObjC pointers. llvm-svn: 124004
* When throwing an elidable object, first try to treat the subexpressionDouglas Gregor2011-01-212-5/+12
| | | | | | | as an rvalue per C++0x [class.copy]p33. If that fails, try again with the original subexpression. llvm-svn: 124002
* Generalize the NRVO move-construction-based initialization routine. No ↵Douglas Gregor2011-01-212-30/+37
| | | | | | functionality change llvm-svn: 123996
* Add basic fixits for -Wuninitialized-experimentalTed Kremenek2011-01-213-2/+23
| | | | | | | to suggest initializations for pointer and ObjC pointer types. llvm-svn: 123995
* Enhance -Wuninitialized-experimental diagnosticsTed Kremenek2011-01-214-32/+82
| | | | | | | | to issue the warning at an uninitialized variable's declaration, but to issue notes at possible uninitialized uses (which could be multiple). llvm-svn: 123994
* Implement the preference for move-construction over copy-constructionDouglas Gregor2011-01-217-41/+158
| | | | | | | | | | | | when returning an NRVO candidate expression. For example, this properly picks the move constructor when dealing with code such as MoveOnlyType f() { MoveOnlyType mot; return mot; } The previously-XFAIL'd rvalue-references test case now works, and has been moved into the appropriate paragraph-specific test case. llvm-svn: 123992
* We love parenthesesDouglas Gregor2011-01-211-2/+2
| | | | llvm-svn: 123983
* Promote the static getNRVOCandidate() function, which computed theDouglas Gregor2011-01-215-23/+48
| | | | | | | | | | | | | NRVO candidate for a return statement, to Sema::getCopyElisionCandidate(), and teach it enough to also determine the NRVO candidate for a throw expression. We still don't use the latter information, however. Along the way, implement core issue 1148, which eliminates copy elision from catch parameters and clarifies that copy elision cannot occur from function parameters (which we already implemented). llvm-svn: 123982
* Implement core issue 1164, which concerns the partial ordering ofDouglas Gregor2011-01-212-47/+97
| | | | | | f(T&) and f(T&&). llvm-svn: 123981
* Add unique_ptr example to test the use of rvalue references. I'll growDouglas Gregor2011-01-211-0/+88
| | | | | | this example further as more rvalue-reference features come online. llvm-svn: 123980
* Add test for overload resolution's preference for binding an rvalueDouglas Gregor2011-01-212-3/+38
| | | | | | | reference to an rvalue rather than binding a const-qualified lvalue reference to that rvalue. llvm-svn: 123979
* Eliminate an unused variableDouglas Gregor2011-01-211-4/+0
| | | | llvm-svn: 123978
* Update the reference-binding implementation used for overloadDouglas Gregor2011-01-214-74/+96
| | | | | | | | resolution to match the latest C++0x working paper's semantics. The implementation now matching up with the reference-binding implementation used for initialization. llvm-svn: 123977
* More testing to C++0x [temp.deduct.call]p3Douglas Gregor2011-01-211-0/+22
| | | | llvm-svn: 123967
* Implement the special template argument deduction rule for T&& in aDouglas Gregor2011-01-213-3/+64
| | | | | | | | | | | call (C++0x [temp.deduct.call]p3). As part of this, start improving the reference-binding implementation used in the computation of implicit conversion sequences (for overload resolution) to reflect C++0x semantics. It still needs more work and testing, of course. llvm-svn: 123966
* Sema: process non-inheritable attributes on function declarations earlyPeter Collingbourne2011-01-213-30/+29
| | | | | | | This allows us to simplify the handling for the overloadable attribute, removing a number of FIXMEs. llvm-svn: 123961
* Sema: support for processing non-inheritable declaration attributes earlyPeter Collingbourne2011-01-212-24/+53
| | | | llvm-svn: 123960
* Generalise support for non-inheritable attributesPeter Collingbourne2011-01-216-88/+102
| | | | | | | | | | | | | | | | | | | | | | | | | Inheritable attributes on declarations may be inherited by any later redeclaration at merge time. By contrast, a non-inheritable attribute will not be inherited by later redeclarations. Non-inheritable attributes may be semantically analysed early, allowing them to influence the redeclaration/overloading process. Before this change, the "overloadable" attribute received special handling to be treated as non-inheritable, while all other attributes were treated as inheritable. This patch generalises the concept, while removing a FIXME. Some CUDA location attributes are also marked as non-inheritable in order to support special overloading semantics (to be introduced in a later patch). The patch introduces a new Attr subclass, InheritableAttr, from which all inheritable attributes derive. Non-inheritable attributes simply derive from Attr. N.B. I did not review every attribute to determine whether it should be marked non-inheritable. This can be done later on an incremental basis, as this change does not affect default functionality. llvm-svn: 123959
* Add more reference-binding examples from the C++0x working paper, all of ↵Douglas Gregor2011-01-211-3/+28
| | | | | | which seem to be working fine llvm-svn: 123955
* Move cheking of kext into canDevirtualizeMemberFunctionCalls().Fariborz Jahanian2011-01-212-17/+17
| | | | | | Improve on test case. Per Doug's comment. wip. llvm-svn: 123954
* Improve the diagnostic that complains about binding an rvalueDouglas Gregor2011-01-213-3/+5
| | | | | | reference to an lvalue. llvm-svn: 123953
* More work to bring reference binding up to the latest C++0xDouglas Gregor2011-01-213-8/+37
| | | | | | | | | | specification. In particular, an rvalue reference can bind to an initializer expression that is an lvalue if the referent type and the initializer expression type are not reference-related. This is a newer formulation to the previous "rvalue references can never bind to lvalues" rule. llvm-svn: 123952
* When performing reference binding via a conversion function, performDouglas Gregor2011-01-212-11/+5
| | | | | | | type checking based on the actual reference type we're trying to bind the result to, rather than stripping the reference. llvm-svn: 123950
* Initialize a variable, found by Ted.Fariborz Jahanian2011-01-201-1/+1
| | | | llvm-svn: 123948
* Fix a use of uninitialized variables, found by Ted!Douglas Gregor2011-01-201-7/+9
| | | | llvm-svn: 123947
* Removing debug printing logic from UninitializedValuesV2.Ted Kremenek2011-01-201-16/+0
| | | | llvm-svn: 123944
* Relax CFG assertions in UninitializedValuesV2 whenTed Kremenek2011-01-202-14/+41
| | | | | | | | | | | handling pseudo-path sensitivity, and instead use those assertion conditions as dynamic checks. These assertions would be violated when analyzing a CFG where some branches where optimized away during CFG construction because their branch conditions could be trivially determined. llvm-svn: 123943
* Add test case for <rdar://problem/8891119>. InTed Kremenek2011-01-201-0/+17
| | | | | | | | | earlier revisions Clang was incorrectly warning about an incomplete @implementation when a property was getting synthesized. This got fixed somewhere down the line. llvm-svn: 123939
* Add rudimentary path-sensitivity to UnintializedValuesV2Ted Kremenek2011-01-202-18/+180
| | | | | | | | | | | | analysis for short-circuited operations. For branch written like "if (x && y)", we maintain two sets of dataflow values for the outgoing branches. This suppresses some common false positives for -Wuninitialized-experimental. This change introduces some assertion failures when running on the LLVM codebase. WIP. llvm-svn: 123923
* apple kext abi requires all vf calls, including qualifiedFariborz Jahanian2011-01-204-3/+62
| | | | | | vf calls, be made indirect. This patch is towards that goal. llvm-svn: 123922
* Enhance AnalysisConsumer to also visit functionsTed Kremenek2011-01-202-39/+59
| | | | | | and methods defined within 'namespace X { ... }'. llvm-svn: 123921
* More tests for reference binding in the presence of rvalueDouglas Gregor2011-01-201-0/+27
| | | | | | | references. Note that we're currently failing reference binding to a function lvalue. llvm-svn: 123920
* Start refactoring reference binding to more closely match the C++0xDouglas Gregor2011-01-202-37/+57
| | | | | | | working paper's structure. The only functional change here is that we now handling binding to array rvalues, which we would previously reject. llvm-svn: 123918
* Diagnose when a virtual member function marked final is overridden.Anders Carlsson2011-01-204-19/+35
| | | | llvm-svn: 123916
* Merge test.Rafael Espindola2011-01-202-7/+9
| | | | llvm-svn: 123914
* Add some tests for reference-collapsing and referencing bindingDouglas Gregor2011-01-206-11/+78
| | | | | | | | | involving rvalue references, to start scoping out what is and what isn't implemented. In the process, tweak some standards citations, type desugaring, and teach the tentative parser about && in ptr-operator. llvm-svn: 123913
* Fix the computation of alignment for fields of packed+aligned structs.John McCall2011-01-205-15/+69
| | | | | | Part of the fix for PR8413. llvm-svn: 123904
OpenPOWER on IntegriCloud