- Sep 06, 2012
-
-
Jordan Rose authored
...and hopefully unbreak buildbots. My apologies! llvm-svn: 163267
-
Jordan Rose authored
These types are defined differently on 32-bit and 64-bit platforms, and trying to offer a fixit for one platform would only mess up the format string for the other. The Apple-recommended solution is to cast to a type that is known to be large enough and always use that to print the value. This should only have an impact on compile time if the format string is incorrect; in cases where the format string matches the definition on the current platform, no warning will be emitted. <rdar://problem/9135072&12164284> llvm-svn: 163266
-
Jordan Rose authored
No functionality change. llvm-svn: 163265
-
- Sep 05, 2012
-
-
Fariborz Jahanian authored
of a c-function for what it is. Otherwise, this func is treated as an overloadable c-function resulting in a crash much later. // rdar://11743706 llvm-svn: 163224
-
Abramo Bagnara authored
llvm-svn: 163208
-
Abramo Bagnara authored
llvm-svn: 163206
-
Chad Rosier authored
llvm-svn: 163188
-
- Sep 04, 2012
-
-
Joao Matos authored
llvm-svn: 163149
-
Joao Matos authored
llvm-svn: 163145
-
Chad Rosier authored
assume that if the 1st operands is an expression and the instruction mayStore, then it is a memory definition. llvm-svn: 163144
-
Chad Rosier authored
llvm-svn: 163142
-
- Sep 03, 2012
-
-
Chad Rosier authored
llvm-svn: 163126
-
Chad Rosier authored
llvm-svn: 163105
-
Chad Rosier authored
llvm-svn: 163102
-
- Sep 02, 2012
-
-
Joao Matos authored
Implemented parsing and AST support for the MS __leave exception statement. Also a minor fix to __except printing in StmtPrinter.cpp. Thanks to Aaron Ballman for review. llvm-svn: 163083
-
Joao Matos authored
Added a diagnostic for mismatched MS inheritance attributes. Also fixed the incomplete type member pointer size calculation under the MS ABI. llvm-svn: 163078
-
- Sep 01, 2012
-
-
Joao Matos authored
llvm-svn: 163039
-
Chris Lattner authored
don't warn about unused values when the unused value is a statement expression expanded from a macro. This is of dubious utility in general, but is specifically a major issue for the linux kernel. This resolves PR13747. llvm-svn: 163034
-
Joao Matos authored
llvm-svn: 163032
-
- Aug 31, 2012
-
-
DeLesley Hutchins authored
expressions, which should be ignored right now. llvm-svn: 163026
-
Fariborz Jahanian authored
property-dot syntax is used on an object whose capture causes retain cycle. // rdar://11702054 llvm-svn: 163017
-
Joao Matos authored
Improved MSVC __interface support by adding first class support for it, instead of aliasing to "struct" which had some incorrect behaviour. Patch by David Robins. llvm-svn: 163013
-
Fariborz Jahanian authored
in the diagnbostic. // rdar://11303469 llvm-svn: 163003
-
Eli Friedman authored
(__builtin_* etc.) so that it isn't possible to take their address. Specifically, introduce a new type to represent a reference to a builtin function, and a new cast kind to convert it to a function pointer in the operand of a call. Fixes PR13195. llvm-svn: 162962
-
Fariborz Jahanian authored
method parameter types which are reference to an objective-C pointer to object with no explicit ownership. // rdar://10907090 llvm-svn: 162959
-
- Aug 30, 2012
-
-
Douglas Gregor authored
constructor not user provided (and, therefore, non-trivial). Fixes <rdar://problem/11736429>. llvm-svn: 162947
-
Richard Trieu authored
initiated enum constant has the same value as another enum constant. For instance: enum test { A, B, C = -1, D, E = 1 }; Clang will warn that: A and D both have value 0 B and E both have value 1 A few exceptions are made to keep the noise down. Enum constants which are initialized to another enum constant, or an enum constant plus or minus 1 will not trigger this warning. Also, anonymous enums are not checked. llvm-svn: 162938
-
Fariborz Jahanian authored
__objc_yes/__objc_no to (BOOL)1/(BOOL)0 when BOOL is declared; otherwise it resorts to default of 'signed char'. This is important to selecting the correct Numeric API numberWithBool: Can't have a clang test for this. Will checkin and executable llvm test. // rdar://12156616 llvm-svn: 162922
-
Richard Smith authored
be filled in; they won't if the lambda's declarator has an invalid type. Instead take the parameters from the declarator directly. llvm-svn: 162904
-
Ted Kremenek authored
could not be attached to a CFTypeRef. Fixes <rdar://problem/12197822> llvm-svn: 162872
-
- Aug 29, 2012
-
-
Fariborz Jahanian authored
when assignment expression in conditional invloves property reference. // rdar://11066598 llvm-svn: 162846
-
Aaron Ballman authored
Reversing the logic since C99 mode is actually not an extension. Also, changing the group to the singular to match the diagnostic better. llvm-svn: 162838
-
Alexander Kornienko authored
Summary: Summary: Keep history of macro definitions and #undefs with corresponding source locations, so that we can later find out all macros active in a specified source location. We don't save the history in PCH (no need currently). Memory overhead is about sizeof(void*)*3*<number of macro definitions and #undefs>+<in-memory size of all #undef'd macros> I've run a test on a file composed of 109 .h files from boost 1.49 on x86-64 linux. Stats before this patch: *** Preprocessor Stats: 73222 directives found: 19171 #define. 4345 #undef. #include/#include_next/#import: 5233 source files entered. 27 max include stack depth 19210 #if/#ifndef/#ifdef. 2384 #else/#elif. 6891 #endif. 408 #pragma. 14466 #if/#ifndef#ifdef regions skipped 80023/451669/1270 obj/fn/builtin macros expanded, 85724 on the fast path. 127145 token paste (##) operations performed, 11008 on the fast path. Preprocessor Memory: 5874615B total BumpPtr: 4399104 Macro Expanded Tokens: 417768 Predefines Buffer: 8135 Macros: 1048576 #pragma push_macro Info: 0 Poison Reasons: 1024 Comment Handlers: 8 Stats with this patch: ... Preprocessor Memory: 7541687B total BumpPtr: 6066176 Macro Expanded Tokens: 417768 Predefines Buffer: 8135 Macros: 1048576 #pragma push_macro Info: 0 Poison Reasons: 1024 Comment Handlers: 8 In my test increase in memory usage is about 1.7Mb, which is ~28% of initial preprocessor's memory usage and about 0.8% of clang's total VMM allocation. As for CPU overhead, it should only be noticeable when iterating over all macros, and should mostly consist of couple extra dereferences and one comparison per macro + skipping of #undef'd macros. It's less trivial to measure, though, as the preprocessor consumes a very small fraction of compilation time. Reviewers: doug.gregor, klimek, rsmith, djasper Reviewed By: doug.gregor CC: cfe-commits, chandlerc Differential Revision: http://llvm-reviews.chandlerc.com/D28 llvm-svn: 162810
-
Fariborz Jahanian authored
and when used in property type declaration, is handled as type attribute. Do not issue the warning when declaraing the property. // rdar://12173491 llvm-svn: 162801
-
Chad Rosier authored
llvm-svn: 162797
-
- Aug 28, 2012
-
-
Aaron Ballman authored
Splitting the duplicated decl spec extension warning into two: one is an ExtWarn and the other a vanilla warning. This addresses PR13705, where const char const * wouldn't warn unless -pedantic was specified under the right conditions. llvm-svn: 162793
-
Peter Collingbourne authored
variables without a storage class within a function, to implement CUDA B.2.5: "__shared__ and __constant__ variables have implied static storage [duration]." llvm-svn: 162788
-
Chad Rosier authored
llvm-svn: 162786
-
Chad Rosier authored
the constraints, so in the interim we speculatively assume a 'r' constraint. This is expected to work for most cases on x86. llvm-svn: 162784
-
Hans Wennborg authored
This warns in two specific situations: 1) For potentially swapped function arguments, e.g. void foo(bool, float); foo(1.7, false); 2) Misplaced brackets around function call arguments, e.g. bool InRange = fabs(a - b < delta); Where the last argument in a function call is implicitly converted from bool to float, and the function returns a float which gets implicitly converted to bool. Patch by Andreas Eckleder! llvm-svn: 162763
-