- Sep 02, 2013
-
-
Alexander Kornienko authored
llvm-svn: 189765
-
Alexander Kornienko authored
llvm-svn: 189762
-
Alexander Kornienko authored
both tools/clang and llvm directories. llvm-svn: 189761
-
Renato Golin authored
llvm-svn: 189759
-
Alexander Kornienko authored
Summary: Store first and last newline position in the token text for string literals and comments to avoid doing .find('\n') for each possible solution. Reviewers: djasper Reviewed By: djasper CC: cfe-commits, klimek Differential Revision: http://llvm-reviews.chandlerc.com/D1556 llvm-svn: 189758
-
Alexander Kornienko authored
Summary: Test clang-format's handling of empty .clang-format files. Reviewers: djasper Reviewed By: djasper CC: cfe-commits, klimek Differential Revision: http://llvm-reviews.chandlerc.com/D1562 llvm-svn: 189757
-
Daniel Jasper authored
Before, constructs like: using A::operator+; caused a segfault. This fixes llvm.org/PR17050. llvm-svn: 189749
-
Pavel Labath authored
This is an improved version of r186498. It enables ExprEngine to reason about temporary object destructors. However, these destructor calls are never inlined, since this feature is still broken. Still, this is sufficient to properly handle noreturn temporary destructors. Now, the analyzer correctly handles expressions like "a || A()", and executes the destructor of "A" only on the paths where "a" evaluted to false. Temporary destructor processing is still off by default and one has to explicitly request it by setting cfg-temporary-dtors=true. Reviewers: jordan_rose CC: cfe-commits Differential Revision: http://llvm-reviews.chandlerc.com/D1259 llvm-svn: 189746
-
Daniel Jasper authored
Before: #define OPERATION_CASE(name) \ case OP_name: \ return operations::Operation##name After: #define OPERATION_CASE(name) \ case OP_name: \ return operations::Operation##name llvm-svn: 189743
-
Chandler Carruth authored
fallback syntax used when we fail to find a '.clang-format' file. Adjust variable names appropriately. Update the editor integration pieces that specify a '-style' option to specify it as '-style=file'. I left the functionality in place because even if the preferred method is to use '.clang-format' files, this way if someone needs to clobber the style in their editor we show how to do so in these examples. Also check in a '.clang-format' file for Clang to ensure that separate checkouts and builds of Clang from LLVM can still get the nice formatting. =] This unfortunately required nuking the test for the absence of a '.clang-format' file as now the directory happening to be under your clang source tree will cause there to always be a file. ;] llvm-svn: 189741
-
- Sep 01, 2013
-
-
Aaron Ballman authored
llvm-svn: 189731
-
- Aug 31, 2013
-
-
Benjamin Kramer authored
llvm-svn: 189721
-
Richard Trieu authored
InitializedEntity::EntityKind as an index for one of its %select. Over time, EntityKind has been expanded, but the diagnostic text has not been updated. This adds additional text to the %select to cover the new enum values. A comment has been added to the end of the enum regarding this situation. This fixes the crasher in PR17043. llvm-svn: 189716
-
Aaron Ballman authored
llvm-svn: 189712
-
Aaron Ballman authored
llvm-svn: 189711
-
Eric Christopher authored
llvm-svn: 189710
-
Eric Christopher authored
a windows compatible builtin header. Currently uses x86intrin.h for implementing intel intrinsics in a clang specific manner. llvm-svn: 189709
-
Fariborz Jahanian authored
of some sort (but not an object, block pointer or CF pointers), and is not annotated with the objc_returns_inner_pointer attribute, we should suggest NS_RETURNS_INNER_POINTER annotation for these methods. llvm-svn: 189707
-
DeLesley Hutchins authored
Patch by chris.wailes@gmail.com Adds the 'consumable' attribute that can be attached to classes. This replaces the previous method of scanning a class's methods to see if any of them have consumed analysis attributes attached to them. If consumed analysis attributes are attached to methods of a class that isn't marked 'consumable' a warning is generated. llvm-svn: 189702
-
- Aug 30, 2013
-
-
Jordan Rose authored
This will never happen in the analyzed code code, but can happen for checkers that over-eagerly dereference pointers without checking that it's safe. UnknownVal is a harmless enough value to get back. Fixes an issue added in r189590, caught by our internal buildbot. llvm-svn: 189688
-
Fariborz Jahanian authored
specified NSUInteger as the followup typedef. With this change, NS_OPTIONS is only inferred based on looking up how enumerators are speficied (if they her hexadecimal, power of 2, or have bitwise constant expressions). llvm-svn: 189682
-
Samuel Benzaquen authored
Reduce the number of symbols by changing how templates are instantiated per function bound in the registry. Summary: Reduce the number of symbols by changing how templates are instantiated per function bound in the registry. This change reduces the number of sections in Registry.cpp.o by a little over 10%. Reviewers: klimek CC: cfe-commits, revane Differential Revision: http://llvm-reviews.chandlerc.com/D1557 llvm-svn: 189676
-
Benjamin Kramer authored
llvm-svn: 189670
-
Hans Wennborg authored
llvm-svn: 189664
-
Daniel Jasper authored
Almost by accident, clang-format seems to be able to format protocol buffer definitions (https://code.google.com/p/protobuf/). The only change is that a space is required between numeric constants and opening square brackets (for default values). While this might in theory be used for array subscripts (int val = 4[MyArray]), I have not seen this pattern in practice much. If this is wrong, we can make this smarter in the future. llvm-svn: 189663
-
Daniel Jasper authored
Before: namespace n { enum Type { One, Two, // missing }; int i; } void g() { } After: namespace n { enum Type { One, Two, // missing }; int i; } void g() {} llvm-svn: 189662
-
Hans Wennborg authored
This never really worked. Even if we find and execute link.exe in the VS bin dir this way, link.exe wouldn't find the DLLs it needs, libraries, etc. It also causes trouble when the user has multiple versions of VS installed, one of them is in the path, but this code finds the other one (PR17041). Revert until we can fix this properly. > Windows ToolChain: add VS bin dir to PogramPaths > > We have a lot of fancy logic to find Visual Studio, which is currently used > to set the system header include paths. > > Use the same code to set the ProgramPaths, which is used for finding programs > such as link.exe. Previously, Clang would just search PATH for link.exe, > but now it should find it if it's able to find Visual Studio. llvm-svn: 189661
-
Yunzhong Gao authored
llvm-svn: 189660
-
Pavel Labath authored
Summary: Previously, Sema was reusing parts of the AST when synthesizing an assignment operator, turning it into a AS-dag. This caused problems for the static analyzer, which assumed an expression appears in the tree only once. Here I make sure to always create a fresh Expr, when inserting something into the AST, fixing PR16745 in the process. Reviewers: doug.gregor CC: cfe-commits, jordan_rose Differential Revision: http://llvm-reviews.chandlerc.com/D1425 llvm-svn: 189659
-
Daniel Jasper authored
Before: aaaaaaaaaa(bbbbbbbbbbbbbbbbbbbbbbbbb.ccccccccccccccccc( dddddddddddddddddddddddddddddd)); aaaaaaaaaaa(bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb( dddddddddddddddddddddddddddddd)); After: aaaaaaaaaaa(bbbbbbbbbbbbbbbbbbbbbbbbb.ccccccccccccccccc( dddddddddddddddddddddddddddddd)); aaaaaaaaaaa(bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb( dddddddddddddddddddddddddddddd)); This was overlooked when interducing the new builder-type call detection in r189337. Also, some minor reorganization of a test. llvm-svn: 189658
-
Daniel Jasper authored
While this looks kind of nice, it wastes horizontal space and does not seem to be common in the LLVM codebase. Before: return llvm::StringSwitch<Reference::Kind>(name) .StartsWith(".eh_frame_hdr", ORDER_EH_FRAMEHDR) .StartsWith(".eh_frame", ORDER_EH_FRAME) .StartsWith(".init", ORDER_INIT) .StartsWith(".fini", ORDER_FINI) .StartsWith(".hash", ORDER_HASH) .Default(ORDER_TEXT); After: return llvm::StringSwitch<Reference::Kind>(name) .StartsWith(".eh_frame_hdr", ORDER_EH_FRAMEHDR) .StartsWith(".eh_frame", ORDER_EH_FRAME) .StartsWith(".init", ORDER_INIT) .StartsWith(".fini", ORDER_FINI) .StartsWith(".hash", ORDER_HASH) .Default(ORDER_TEXT); llvm-svn: 189657
-
Daniel Jasper authored
Before: aaaaaaaaaaaaa->aaaaaaaaaaaaaaaaaaaaaaaa()->aaaaaaaaaaaaaae( 0)->aaaaaaaaaaaaaaa(); After: aaaaaaaaaaaaa->aaaaaaaaaaaaaaaaaaaaaaaa() ->aaaaaaaaaaaaaae(0) ->aaaaaaaaaaaaaaa(); llvm-svn: 189655
-
Yunzhong Gao authored
The patch was discussed in Phabricator. See: http://llvm-reviews.chandlerc.com/D1281 llvm-svn: 189649
-
Richard Smith authored
llvm-svn: 189647
-
Richard Smith authored
from a PCH/module. llvm-svn: 189646
-
Richard Smith authored
llvm-svn: 189645
-
Charles Davis authored
Based on a patch by Benno Rice! llvm-svn: 189644
-
Eric Christopher authored
again. This test should a) test IR or be moved, and b) get an actual option for the dwarf pub sections. llvm-svn: 189633
-
Richard Smith authored
llvm-svn: 189629
-
Fariborz Jahanian authored
should infer migration to NS_OPTIONS. llvm-svn: 189628
-