summaryrefslogtreecommitdiffstats
path: root/clang/lib
Commit message (Collapse)AuthorAgeFilesLines
...
* Use CXXTemporaryObjectExpr for explicitly-constructed temporaries. WeDouglas Gregor2010-03-022-5/+28
| | | | | | | used to do this, but it got lost when we switched functional-style cast syntax over to using the new initialization code. Fixes PR6457. llvm-svn: 97568
* Register all parameters even if they didn't occur in the function body.Zhongxing Xu2010-03-021-0/+6
| | | | | | | We may query their liveness because they are added to store when passing argument values. llvm-svn: 97562
* Unify initializer-instantiation code for variable declarations andDouglas Gregor2010-03-021-85/+93
| | | | | | base/member initializers. llvm-svn: 97560
* Simplify code.Anders Carlsson2010-03-021-8/+7
| | | | llvm-svn: 97551
* Inspired by seeing "MIPS" go by in the commits, I've gone ahead andJohn McCall2010-03-022-10/+34
| | | | | | | | | | | implemented a (codegen) target hook for __builtin_extend_pointer. I'm also making it return a uint64_t instead of an unsigned word; this comports with typical usage (i.e. the one use I know of). I don't know if any of the existing targets requires this hook to be set (other than x86 and x86_64, which I know do not). llvm-svn: 97547
* Rename BaseOffset to Offset and make it signed in preparation of more ↵Anders Carlsson2010-03-021-10/+11
| | | | | | construction vtable work. llvm-svn: 97546
* Add in some more MIPS command line options.Eric Christopher2010-03-023-1/+101
| | | | | | Patch by Oleksandr Tymoshenko! llvm-svn: 97544
* After much consultation aimed at figuring out what this builtin actuallyJohn McCall2010-03-021-0/+16
| | | | | | | does, document the results and then implement __builtin_extend_pointer for platforms where it's a no-op. llvm-svn: 97540
* Fix an amusing typo that completely the re-introduction of parametersDouglas Gregor2010-03-021-1/+1
| | | | | | | | | | | for the purposes of parsing default arguments. In effect, we would re-introduce the parameter with a default argument N times (where N is the number of parameters preceding the parameter with a default argument). This showed up when a defaulted parameter of a member function of a local class shadowed a parameter of the enclosing function. Fixes PR6383. llvm-svn: 97534
* Cast a pointer to 'long long' to satisfy all compilation models.Fariborz Jahanian2010-03-021-1/+3
| | | | | | Satisfies radar 7703202. llvm-svn: 97532
* Add commentDouglas Gregor2010-03-021-1/+2
| | | | llvm-svn: 97528
* When we're parsing template names as part of base-specifiers, we areDouglas Gregor2010-03-011-1/+1
| | | | | | | | *not* entering the context of the nested-name-specifier. This was causing us to look into an uninstantiated template that we shouldn't look into. Fixes PR6376. llvm-svn: 97524
* Split out types that are non-canonical unless dependent as their ownJohn McCall2010-03-014-7/+62
| | | | | | | | | | | category. Use this in a few places to eliminate unnecessary TST cases and do some future-proofing. Provide terrible manglings for typeof. Mangle decltype with some hope of accuracy. Our manglings for some of the cases covered in the testcase are different from gcc's, which I've raised as an issue with the ABI list. llvm-svn: 97523
* More rewriter of nested blocks fun stuff.Fariborz Jahanian2010-03-011-19/+28
| | | | | | Radar 7696893. llvm-svn: 97520
* Unbreak the buildDouglas Gregor2010-03-011-1/+1
| | | | llvm-svn: 97519
* Keep an explicit stack of function and block scopes, each element ofDouglas Gregor2010-03-019-136/+198
| | | | | | | | | | | | | | | | | | | | which has the label map, switch statement stack, etc. Previously, we had a single set of maps in Sema (for the function) along with a stack of block scopes. However, this lead to funky behavior with nested functions, e.g., in the member functions of local classes. The explicit-stack approach is far cleaner, and we retain a 1-element cache so that we're not malloc/free'ing every time we enter a function. Fixes PR6382. Also, tweaked the unused-variable warning suppression logic to look at errors within a given Scope rather than within a given function. The prior code wasn't looking at the right number-of-errors count when dealing with blocks, since the block's count would be deallocated before we got to ActOnPopScope. This approach works with nested blocks/functions, and gives tighter error recovery. llvm-svn: 97518
* Fix the lookup of names used in a friend declaration to not attempt toChandler Carruth2010-03-011-2/+3
| | | | | | | re-declare them. This fixes PR6317. Also add the beginnings of an interesting test case for p1 of [class.friend] which also covers PR6317. llvm-svn: 97499
* fix PR5933: don't warn about unused variables if a function has other errors ↵Chris Lattner2010-03-011-1/+2
| | | | | | in it. llvm-svn: 97498
* Implement jump checking for initialized c++ variables, implementingChris Lattner2010-03-016-12/+41
| | | | | | | | | | | | | | | | | | a fixme and PR6451. Only perform jump checking if the containing function has no errors, and add the infrastructure needed to do this. On the testcase in the PR, we produce: t.cc:6:3: error: illegal goto into protected scope goto later; ^ t.cc:7:5: note: jump bypasses variable initialization X x; ^ llvm-svn: 97497
* Start detangling the BlockSemaInfo/Sema mess. No functionality change.Douglas Gregor2010-03-012-22/+37
| | | | llvm-svn: 97494
* Allow a '0' precision in format strings (as the man page says it is okay).Ted Kremenek2010-03-011-10/+18
| | | | | | Fixes <rdar://problem/7700339>. llvm-svn: 97482
* The latest draft uses 'dt' to mangle member expressions, and now so do we.John McCall2010-03-011-9/+3
| | | | llvm-svn: 97479
* When looking for a redeclaration of a static variable, only look for ↵Douglas Gregor2010-03-011-1/+1
| | | | | | redeclarations. Fixes PR6449 llvm-svn: 97478
* When instantiating a function-scoped enum, make sure that it and itsDouglas Gregor2010-03-012-1/+10
| | | | | | | enumeration constants get placed into the local instantiation hash table. Fixes PR6375. llvm-svn: 97471
* Robustify instantiation of templates when there are errors in theDouglas Gregor2010-03-013-6/+8
| | | | | | | | | template definition. Do this both by being more tolerant of errors in our asserts and by not dropping a variable declaration completely when its initializer is ill-formed. Fixes the crash-on-invalid in PR6375, but not the original issue. llvm-svn: 97463
* Don't infinite-loop if TryAnnotateCXXScopeToken fails to annotate but doesn'tJohn McCall2010-03-011-0/+2
| | | | | | | | | signal an error. This can happen even when the current token is '::' if this is a ::new or ::delete expression. This was an oversight in my recent parser refactor; fixes PR 5825. llvm-svn: 97462
* Finish pushing source-location information though TreeTransform'sDouglas Gregor2010-03-012-8/+17
| | | | | | TransformDefinition. llvm-svn: 97445
* When looking for the instantiated declaration that corresponds to aDouglas Gregor2010-03-014-42/+86
| | | | | | | given declaration in a template, make sure that the context we're searching through is complete. Fixes PR6376. llvm-svn: 97444
* Since now we store the cast type with an ElementRegion, there isZhongxing Xu2010-03-015-27/+17
| | | | | | no need to store a type with SymbolRegionValue. llvm-svn: 97437
* Assert when loading from a code text region instead of returning an unknown ↵Zhongxing Xu2010-03-011-1/+3
| | | | | | silently. llvm-svn: 97436
* Don't warn about case-value conversions from a negative value to aDouglas Gregor2010-03-011-7/+5
| | | | | | | | larger unsigned value, since this is implementation-defined behavior. (We previously suppressed this warning when converting from a signed value to an unsigned value of the same size). llvm-svn: 97430
* Improve name mangling for dependently-scoped declaration references.Douglas Gregor2010-02-281-1/+12
| | | | llvm-svn: 97422
* Add name mangling for DeclRefExprs that refer to external namesDouglas Gregor2010-02-281-2/+8
| | | | llvm-svn: 97418
* Remove debug output.Anders Carlsson2010-02-281-2/+0
| | | | llvm-svn: 97407
* Handle unused functions in construction vtables correctly.Anders Carlsson2010-02-281-9/+17
| | | | llvm-svn: 97406
* pull some altivec stuff out of line.Chris Lattner2010-02-281-0/+66
| | | | llvm-svn: 97405
* Warn about the deprecated string literal -> char* conversion. Fixes PR6428.Douglas Gregor2010-02-283-6/+11
| | | | llvm-svn: 97404
* Implement PR6423 by using one token of lookahead to disambiguate Chris Lattner2010-02-282-9/+73
| | | | | | | | | | | | | | | | | | | | | | | | | | an *almost* always incorrect case. This only does the lookahead in the insanely unlikely case, so it shouldn't impact performance. On this testcase: struct foo { } typedef int x; Before: t.c:3:9: error: cannot combine with previous 'struct' declaration specifier typedef int x; ^ After: t.c:2:2: error: expected ';' after struct } ^ ; llvm-svn: 97403
* When laying out vtables for virtual bases in construction vtables, we need ↵Anders Carlsson2010-02-281-3/+16
| | | | | | to check if the vtable is a primary base in the layout class. llvm-svn: 97402
* Support constant-evaluation of __builtin_nans* as well as the correct constantJohn McCall2010-02-281-13/+33
| | | | | | | | evaluation of __builtin_nan*. Most of the work to make this work is in LLVM. Fixes <rdar://problem/7696712> and part of PR 5255. llvm-svn: 97383
* Use getBody() to get the function definition when the decl referenced is notZhongxing Xu2010-02-281-1/+1
| | | | | | definition. llvm-svn: 97373
* More improvements to construction vtables; we know handle vbase offsets ↵Anders Carlsson2010-02-281-42/+51
| | | | | | correctly (I hope). llvm-svn: 97361
* Opt into the Verifier now that it's an opt-in feature ofDan Gohman2010-02-281-1/+10
| | | | | | addPassesToEmitFile. llvm-svn: 97358
* Pass information about whether a base is virtual or not down to ↵Anders Carlsson2010-02-283-19/+37
| | | | | | getCtorVtable, we need this information in the vtable builder. llvm-svn: 97356
* Add new function.Anders Carlsson2010-02-281-2/+8
| | | | llvm-svn: 97353
* Fix to dumpLayout; we want to be able to dump address points even if the ↵Anders Carlsson2010-02-271-31/+34
| | | | | | vtable doesn't have any methods. llvm-svn: 97350
* Debian sid moved these headers into /4.4 and left /4.4.3 as a symlink. Update.Nick Lewycky2010-02-271-1/+3
| | | | | | Also, add support for 32-bit x86 Debian sid. llvm-svn: 97347
* Add a simple construction vtable test.Anders Carlsson2010-02-271-6/+22
| | | | llvm-svn: 97344
* Start fleshing out construction vtable support.Anders Carlsson2010-02-271-10/+38
| | | | llvm-svn: 97342
* Enable the new vtable layout code for vtables that aren't construction ↵Anders Carlsson2010-02-271-5/+9
| | | | | | vtables. (This doesn't mean that we emit LLVM IR using it yet, it just means that it's running and hopefully not crashing or asserting). llvm-svn: 97341
OpenPOWER on IntegriCloud