summaryrefslogtreecommitdiffstats
path: root/clang
Commit message (Collapse)AuthorAgeFilesLines
...
* clang-format: Fix test after recent flag change.Daniel Jasper2014-10-281-1/+1
| | | | llvm-svn: 220781
* [modules] Allow -I, -D, -W flags to change between building a module andRichard Smith2014-10-282-3/+45
| | | | | | | | explicitly using the resulting .pcm file. Unlike for an implicit module build, we don't need nor want to require these flags to match between the module and its users. llvm-svn: 220780
* clang-format: Don't put functions on a single line in Google's JavaDaniel Jasper2014-10-281-0/+1
| | | | | | style. llvm-svn: 220778
* Add valueDecl() matcher.Samuel Benzaquen2014-10-283-0/+17
| | | | | | | | | | | | Summary: Add valueDecl() matcher. Reviewers: klimek Subscribers: klimek, cfe-commits Differential Revision: http://reviews.llvm.org/D6005 llvm-svn: 220776
* clang/test/Modules/explicit-build.cpp: Tweak to meet win32's backslash.NAKAMURA Takumi2014-10-281-1/+1
| | | | llvm-svn: 220770
* Fix warning text: lower -> higherRichard Trieu2014-10-282-3/+3
| | | | llvm-svn: 220763
* Driver: remove a stray s that propagated in cross-windowsSaleem Abdulrasool2014-10-282-8/+8
| | | | | | The option is '--allow-multiple-definition' not '--allow-multiple-definitions'. llvm-svn: 220760
* Update for LLVM API change.Rafael Espindola2014-10-281-1/+1
| | | | llvm-svn: 220742
* Improve on the diagnostic in my last patch and change warningFariborz Jahanian2014-10-272-3/+3
| | | | | | to error. rdar://18768214. llvm-svn: 220740
* Remove unused variable.Richard Smith2014-10-271-2/+1
| | | | llvm-svn: 220738
* Use the newer/simple API for passing a diagnostic handler to the IR linker.Rafael Espindola2014-10-271-16/+5
| | | | llvm-svn: 220733
* [modules] Load .pcm files specified by -fmodule-file lazily.Richard Smith2014-10-277-116/+168
| | | | llvm-svn: 220731
* Objective-C ARC [qoi]. Issue diagnostic if __bridge castingFariborz Jahanian2014-10-274-5/+63
| | | | | | to C type a collection literal. rdar://18768214 llvm-svn: 220727
* Frontend: Don't include stdin in the dependency list for an object fileDavid Majnemer2014-10-271-2/+11
| | | | | | | | | GCC doesn't do this and it semes weird to include a file that we can't open. This fixes PR21362. llvm-svn: 220726
* Try to appease the C++ godsHans Wennborg2014-10-272-4/+4
| | | | | | | | Looks like some builds were not happy with the potentially-throwing move constructor that was added in r220723, and reached for the implicitly deleted copy constructor instead. llvm-svn: 220725
* Give TypoExprState a move constructor and assignment operator to appease ↵Hans Wennborg2014-10-272-0/+17
| | | | | | MSVC build llvm-svn: 220723
* Fix segfault in hasDeclContext for nodes that have no decl context.Samuel Benzaquen2014-10-272-2/+5
| | | | | | | | | | | | | | Summary: Some declarations do not have a declaration context, like TranslationUnitDecl. Fix hasDeclContext() to not segfault on these nodes. Reviewers: klimek Subscribers: klimek, cfe-commits Differential Revision: http://reviews.llvm.org/D6003 llvm-svn: 220719
* Frontend: Define __EXCEPTIONS if -fexceptions is passedDavid Majnemer2014-10-273-4/+7
| | | | | | | | | GCC defines __EXCEPTIONS, regardless of language mode, if -fexceptions is passed. We should do the same. This fixes PR21358. llvm-svn: 220714
* Do not insert asan paddings after fields that have flexible arrays.Kostya Serebryany2014-10-272-3/+38
| | | | | | | | | | | | | | | | | | | Summary: We should avoid a tail padding not only if the last field has zero size but also if the last field is a struct with a flexible array. If/when http://reviews.llvm.org/D5478 is committed, this will also handle the case of structs with zero-sized arrays. Reviewers: majnemer, rsmith Reviewed By: rsmith Subscribers: cfe-commits Differential Revision: http://reviews.llvm.org/D5924 llvm-svn: 220708
* c++11 patch to issue warning on missing 'override' on Fariborz Jahanian2014-10-276-6/+44
| | | | | | | overriding methods. Patch review by Richard Smith. rdar://18295240 llvm-svn: 220703
* Wire up LookupMemberExpr to use the new TypoExpr.Kaelyn Takata2014-10-276-19/+203
| | | | | | | | This includes adding the new TypoExpr-based lazy typo correction to LookupMemberExprInRecord as an alternative to the existing eager typo correction. llvm-svn: 220698
* Add a callback for recovering using a typo correction.Kaelyn Takata2014-10-274-14/+27
| | | | | | | Also keep track of the stack of Exprs visited during the tree transform so the callback can be passed the parent of the TypoExpr. llvm-svn: 220697
* Add simple way for a CorrectionCandidateCallback to reject exactKaelyn Takata2014-10-272-50/+72
| | | | | | | | | | | | | | | matches of the typo. Also be more proactive about checking a correction's visibility so that a correction requiring a module import can be distinguished from the original typo even if it looks identical. Otherwise the correction will be excluded and the diagnostic about needing the module import won't be emitted. Note that no change was made to checkCorrectionVisibility other than moving where it is at in SemaLookup.cpp. llvm-svn: 220696
* Start adding the infrastructure for handling TypoExprs.Kaelyn Takata2014-10-275-107/+393
| | | | | | | | | | | | | | | | Part of the infrastructure is a map from a TypoExpr to the Sema-specific state needed to correct it, along with helpers to ease dealing with the state. The the typo count is propagated up the stack of ExpressionEvaluationContextRecords when one is popped off of to avoid accidentally dropping TypoExprs on the floor. For example, the attempted correction of g() in test/CXX/class/class.mem/p5-0x.cpp happens with an ExpressionEvaluationContextRecord that is popped off the stack prior to ActOnFinishFullExpr being called and the tree transform for TypoExprs being run. llvm-svn: 220695
* Have TypoCorrectionConsumer remember the TypoCorrections it returned.Kaelyn Takata2014-10-272-9/+38
| | | | | | | | | | | Two additional methods are provided: one to return the current correction (the last correction returned by getNextCorrection), and one to "reset" the state so that getNextCorrection will return the previous corrections before returning any new corrections. Also ensure that all TypoCorrections have valid source ranges. llvm-svn: 220694
* Pass around CorrectionCandidateCallbacks as unique_ptrs soKaelyn Takata2014-10-2721-175/+179
| | | | | | TypoCorrectionConsumer can keep the callback around as long as needed. llvm-svn: 220693
* Add the initial TypoExpr AST node for delayed typo correction.Kaelyn Takata2014-10-2717-1/+57
| | | | llvm-svn: 220692
* Move TypoCorrectionConsumer into a header.Kaelyn Takata2014-10-272-152/+149
| | | | | | | | | This makes it available outside of SemaLookup.cpp, as needed for the forthcoming TypoExpr AST node which will keep a TypoCorrectionConsumer that provides the possible typo corrections for that TypoExpr. llvm-svn: 220691
* clang-format: Don't break after very short return types.Daniel Jasper2014-10-272-10/+16
| | | | | | | | | | | | | | Before: void SomeFunction(int parameter); After: void SomeFunction( int parameter); (Unless AlwaysBreakAfterDefinitionReturnType after type is set). llvm-svn: 220686
* clang-format: improve vim integration docsSaleem Abdulrasool2014-10-272-4/+4
| | | | | | | | | | Improve the documentation for vim integration of clang-format. Prefer the use of <c-o> to do the normal mode command execution to avoid side-effects of the escape and re-insertion (cursor movement). Tweak the macros to use a double return to avoid having to manually return control to the editor from the subprocess. llvm-svn: 220685
* clang-format: Fix bad merging of lines in nested blocks.Daniel Jasper2014-10-273-5/+18
| | | | | | | | | | | | | | | Before: SomeFunction([]() { #define A a return 43; }); After: SomeFunction([]() { #define A a return 43; }); llvm-svn: 220684
* Speed up clang-tidy when profiling in on.Samuel Benzaquen2014-10-271-15/+31
| | | | | | | | | | | | | | | | Summary: Speed up clang-tidy when profiling in on. It makes profiling runs twice as fast by reusing the time samples between the different actions. It also joins together the sampling of different matchers of the same check. Reviewers: alexfh Subscribers: klimek, cfe-commits Differential Revision: http://reviews.llvm.org/D5972 llvm-svn: 220682
* Allow thread sanitizer in clang driver on FreeBSDViktor Kutuzov2014-10-271-4/+9
| | | | | | http://reviews.llvm.org/D5999 llvm-svn: 220680
* clang-format: [Proto] Change formatting text-formatted options.Daniel Jasper2014-10-273-15/+19
| | | | | | | | | | | | | | Before: optional Type type = 1 [(mutate_options) = {vital : true abc : false}]; After: optional Type type = 1 [(mutate_options) = { vital : true abc : false }]; llvm-svn: 220679
* Prune CRLF.NAKAMURA Takumi2014-10-2711-380/+380
| | | | llvm-svn: 220678
* Revert rL220675 due to failures on check-clangViktor Kutuzov2014-10-271-6/+1
| | | | llvm-svn: 220677
* Allow thread sanitizer in clang driver on FreeBSDViktor Kutuzov2014-10-271-1/+6
| | | | | | Differential Revision: http://reviews.llvm.org/D5994 llvm-svn: 220675
* Fix unicode chars into ascii in comment lines.NAKAMURA Takumi2014-10-271-1/+1
| | | | llvm-svn: 220668
* Fix 80-column and other odd formatting.Eric Christopher2014-10-261-427/+388
| | | | llvm-svn: 220659
* Make VFS and FileManager match the current MemoryBuffer API.Benjamin Kramer2014-10-2618-186/+134
| | | | | | | This eliminates converting back and forth between the 3 formats and gives us a more homogeneous interface. llvm-svn: 220657
* ModuleMap.cpp: fix Windows build, take 2Hans Wennborg2014-10-261-2/+3
| | | | llvm-svn: 220646
* ModuleMap.cpp: fix VS2012 buildHans Wennborg2014-10-261-2/+3
| | | | llvm-svn: 220644
* Delete unused method and clangAST dependency it required.Daniel Jasper2014-10-263-15/+0
| | | | llvm-svn: 220640
* ModuleMap::addHeader(): Appease msc17.NAKAMURA Takumi2014-10-261-4/+16
| | | | llvm-svn: 220639
* Driver: reduce search logic duplicationSaleem Abdulrasool2014-10-252-21/+31
| | | | | | | Refactor the path search into a helper function to avoid duplicating the path handling for the search. NFC. llvm-svn: 220628
* test: attempt to make test more hermeticSaleem Abdulrasool2014-10-252-19/+14
| | | | | | | | Add a fake linker in to a sysroot to use for testing the driver's tool invocation. Should make the test behave similarly on all platforms. Addresses review comments from Reid Kleckner from SVN r220546. llvm-svn: 220625
* Driver: assume that all architectures are supported for libstc++Saleem Abdulrasool2014-10-251-8/+2
| | | | | | | | | Rather than asserting that the target is unsupported, make a guess at what the tree for a port would look like and use that for the search path. Addresses review comments from Ried Kleckner for SVN r220547. llvm-svn: 220624
* Lex: Fix an invalid access into a SmallStringDavid Majnemer2014-10-253-5/+14
| | | | | | | | | | | | | We would crash because we used operator[] to access past the end of a SmallString. This occured because our token had length zero. Instead, form the pointer using .data() and arithmetic. This is safe because this forms a one-past-the-end pointer and it is only used to compare with another one-past-the-end pointer. This fixes PR21379. llvm-svn: 220614
* Update for LLVM api change.Rafael Espindola2014-10-251-6/+31
| | | | llvm-svn: 220609
* Make this test a bit stricter by checking clang's output too.Rafael Espindola2014-10-251-1/+1
| | | | llvm-svn: 220604
OpenPOWER on IntegriCloud