summaryrefslogtreecommitdiffstats
path: root/clang/test/SemaCXX/undefined-internal.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Add r180263 back, but fix hasBraces() to be correct during parsing.Rafael Espindola2013-04-261-0/+7
| | | | | | | | Original commit message: Fix a case in linkage computation that should check for single line extern "C". llvm-svn: 180591
* Revert r180263. It's causing failures.Bill Wendling2013-04-251-7/+0
| | | | llvm-svn: 180583
* Fix a case in linkage computation that should check for single line extern "C".Rafael Espindola2013-04-251-0/+7
| | | | llvm-svn: 180263
* When marking derived classes' virtual methods ODR-used in order to triggerNick Lewycky2013-02-141-0/+17
| | | | | | | instantiation in order to permit devirtualization later in codegen, skip over pure functions since those can't be devirtualization targets. llvm-svn: 175116
* The meat of this patch is in BuildCXXMemberCalLExpr where we make it useNick Lewycky2013-02-121-0/+37
| | | | | | | | | | | | MarkMemberReferenced instead of marking functions referenced directly. An audit of callers to MarkFunctionReferenced and DiagnoseUseOfDecl also caused a few other changes: * don't mark functions odr-used when considering them for an initialization sequence. Do mark them referenced though. * the function nominated by the cleanup attribute should be diagnosed. * operator new/delete should be diagnosed when building a 'new' expression. llvm-svn: 174951
* Apply the pure-virtual odr rule to other constructs which can call overloadedNick Lewycky2013-02-071-0/+38
| | | | | | operators. llvm-svn: 174584
* This patch makes "&Cls::purevfn" not an odr use. This isn't what the standardNick Lewycky2013-02-021-0/+19
| | | | | | | | | says, but that's a defect (to be filed). "Cls::purevfn()" is still an odr use. Also fixes a bug that caused us to not mark the function referenced just because we didn't want to mark it odr used. llvm-svn: 174242
* Fix ODR-use of a MemberExpr to check before marking a pure function used. RemoveNick Lewycky2013-01-311-0/+13
| | | | | | a workaround for this bug from the -Wundefined-internals warning. llvm-svn: 174020
* Don't warn for undefined but used decls that are external because of a typedef.Rafael Espindola2012-12-291-0/+18
| | | | | | | | This fixes pr14736. It is fairly ugly, but I don't think we can do much better as we have to wait at least until the end of the typedef to know if the function will have external linkage or not. llvm-svn: 171240
* Make sure template argument deduction is consistently performed in an ↵Eli Friedman2012-02-081-0/+11
| | | | | | unevaluated context. llvm-svn: 150049
* Suppress the used-but-not-defined warning for static data members while I ↵Eli Friedman2012-02-041-4/+7
| | | | | | look into a rather nasty bug in the new odr-use marking code. llvm-svn: 149731
* Add some code to accurately perform odr-used marking for variables per the ↵Eli Friedman2012-02-021-0/+45
| | | | | | C++11 rules. llvm-svn: 149641
* Rough fix for PR9323 that prevents Clang from marking copy constructorChandler Carruth2011-02-251-0/+17
| | | | | | | | | | | | | | | | declarations as referenced when in fact we're not going to even form a call in the AST. This is significant because we attempt to allow as an extension classes with intentionally private and undefined copy constructors to have temporaries bound to references, and so shouldn't warn about the lack of definition for that copy constructor when the class is internal. Doug, John wasn't really satisfied with the presence of overloading at all. This is a stop-gap and there may be a better solution. If you can give me some hints for how you'd prefer to see this solved, I'll happily switch things over. llvm-svn: 126480
* Don't warn about static const integral data members with in-line constantJohn McCall2011-02-211-0/+21
| | | | | | | | initializers just because they don't have a proper out-of-line definition. Such code is technically ill-formed but is too common and too unlikely to be a problem to be seriously worth worrying about. llvm-svn: 126137
* Warn about code that uses variables and functions with internal linkageJohn McCall2011-02-191-0/+86
without defining them. This should be an error, but I'm paranoid about "uses" that end up not actually requiring a definition. I'll revisit later. Also, teach IR generation to not set internal linkage on variable declarations, just for safety's sake. Doing so produces an invalid module if the variable is not ultimately defined. Also, fix several places in the test suite where we were using internal functions without definitions. llvm-svn: 126016
OpenPOWER on IntegriCloud