- Feb 19, 2012
-
-
Sebastian Redl authored
llvm-svn: 150928
-
Sebastian Redl authored
Get recursive initializer lists to work and add a test. Codegen of std::initializer_list is now complete. Onward to array new. llvm-svn: 150926
-
Sebastian Redl authored
Add a testcase for using objects with list-constructors, and fix a Sema crash by repeating an old hack. llvm-svn: 150925
-
Sebastian Redl authored
Fix a crash for nested initializer list initialization. Still does the wrong thing in CodeGen, in that it never destructs anything. llvm-svn: 150922
-
Ahmed Charles authored
llvm-svn: 150919
-
Rafael Espindola authored
configure's --with-gcc-toolchain. The configure option is now just a default value for the command line one. llvm-svn: 150898
-
- Feb 18, 2012
-
-
-
Richard Smith authored
complex numbers. Treat complex numbers as arrays of the corresponding component type, in order to make std::complex behave properly if implemented in terms of _Complex T. Apparently libstdc++'s std::complex is implemented this way, and we were rejecting a member like this: constexpr double real() { return __real__ val; } because it was marked constexpr but unable to produce a constant expression. llvm-svn: 150895
-
Ted Kremenek authored
Fix crash in analyzer diagnostic generation involving subexpressions of OpaqueValueExpr not appearing in the ParentMap. Fixes <rdar://problem/10797980>. llvm-svn: 150894
-
-
Richard Smith authored
rather than an lvalue referring to the scalar. llvm-svn: 150889
-
Ted Kremenek authored
Adopt ExprEngine and checkers to ObjC property refactoring. Everything was working, but now diagnostics are aware of message expressions implied by uses of properties. Fixes <rdar://problem/9241180>. llvm-svn: 150888
-
David Chisnall authored
llvm-svn: 150883
-
David Chisnall authored
llvm-svn: 150882
-
David Chisnall authored
This fixes PR5172 and allows clang to compile C++ programs on Solaris using the system headers. llvm-svn: 150881
-
Benjamin Kramer authored
llvm-svn: 150877
-
Douglas Gregor authored
eliminating a bunch of redundant code and properly modeling how the captures of outside blocks/lambdas affect the types seen by inner captures. This new scheme makes two passes over the capturing scope stack. The first pass goes up the stack (from innermost to outermost), assessing whether the capture looks feasible and stopping when it either hits the scope where the variable is declared or when it finds an existing capture. The second pass then walks down the stack (from outermost to innermost), capturing the variable at each step and updating the captured type and the type that an expression referring to that captured variable would see. It also checks type-specific restrictions, such as the inability to capture an array within a block. Note that only the first odr-use of each variable needs to do the full walk; subsequent uses will find the capture immediately, so multiple walks need not occur. The same routine that builds the captures can also compute the type of the captures without signaling errors and without actually performing the capture. This functionality is used to determine the type of declaration references as well as implementing the weird decltype((x)) rule within lambda expressions. The capture code now explicitly takes sides in the debate over C++ core issue 1249, which concerns the type of captures within nested lambdas. We opt to use the more permissive, more useful definition implemented by GCC rather than the one implemented by EDG. llvm-svn: 150875
-
Douglas Gregor authored
variable; it was previously duplicated, and one of the copies failed to account for outer non-mutable lambda captures. llvm-svn: 150872
-
Richard Smith authored
are represented as prvalues in C++; don't be fooled into thinking they're global lvalues. llvm-svn: 150870
-
rdar://problem/10885993Eli Friedman authored
This should probably be refactored... but it isn't completely obvious what refactoring is best. llvm-svn: 150869
-
Ted Kremenek authored
llvm-svn: 150868
-
Richard Smith authored
We had two separate issues here: firstly, varions functions were assuming that they did not need to perform semantic checks on trivial destructors (this is not true in C++11, where a trivial destructor can nonetheless be private or deleted), and a bunch of DiagnoseUseOfDecl calls were missing for uses of destructors. llvm-svn: 150866
-
Richard Smith authored
decent diagnostics. Finish the work of combining all the 'ShouldDelete' functions into one. In unifying the code, fix a minor bug where an anonymous union with a deleted default constructor as a member of a union wasn't being considered as making the outer union's default constructor deleted. llvm-svn: 150862
-
Chad Rosier authored
llvm-svn: 150859
-
Eric Christopher authored
with full types if they exist. rdar://10809898 and rdar://10209967 and rdar://10400981 llvm-svn: 150858
-
Eric Christopher authored
llvm-svn: 150857
-
Eric Christopher authored
emit less than complete types on purpose on occasion and so our caches aren't useful for this kind of lazy emitting. llvm-svn: 150856
-
Chad Rosier authored
llvm-svn: 150855
-
Ted Kremenek authored
Have conjured symbols depend on LocationContext, to add context sensitivity for functions called more than once. llvm-svn: 150849
-
- Feb 17, 2012
-
-
Anna Zaks authored
it aware of CString APIs that return the input parameter. Malloc Checker needs to know how the 'strcpy' function is evaluated. Introduce the dependency on CStringChecker for that. CStringChecker knows all about these APIs. Addresses radar://10864450 llvm-svn: 150846
-
Anna Zaks authored
(Ex: It was not treating __inline_strcpy as strcpy. Will add tests that rely on this later on.) llvm-svn: 150845
-
Fariborz Jahanian authored
until the end when all their ivars are known then. llvm-svn: 150844
-
Fariborz Jahanian authored
and some cleanup. llvm-svn: 150839
-
Richard Smith authored
llvm-svn: 150838
-
Fariborz Jahanian authored
patch. llvm-svn: 150825
-
David Chisnall authored
order to not be broken (by Solaris standards). llvm-svn: 150822
-
Douglas Gregor authored
functionality change. llvm-svn: 150817
-
Sebastian Redl authored
Don't know what I was thinking there. Fixes PR12023. llvm-svn: 150804
-
Sebastian Redl authored
We now generate temporary arrays to back std::initializer_list objects initialized with braces. The initializer_list is then made to point at the array. We support both ptr+size and start+end forms, although the latter is untested. Array lifetime is correct for temporary std::initializer_lists (e.g. call arguments) and local variables. It is untested for new expressions and member initializers. Things left to do: Massively increase the amount of testing. I need to write tests for start+end init lists, temporary objects created as a side effect of initializing init list objects, new expressions, member initialization, creation of temporary objects (e.g. std::vector) for initializer lists, and probably more. Get lifetime "right" for member initializers and new expressions. Not that either are very useful. Implement list-initialization of array new expressions. llvm-svn: 150803
-
Richard Smith authored
variable ends, if the variable has a trivial destructor and no mutable subobjects then emit an llvm.invariant.start call for it. globalopt knows to make the variable const when evaluating this. llvm-svn: 150798
-