- Mar 13, 2009
-
-
Chris Lattner authored
etc and make freestanding imply it. llvm-svn: 66972
-
Daniel Dunbar authored
llvm-svn: 66968
-
Chris Lattner authored
llvm-svn: 66961
-
Chris Lattner authored
llvm-svn: 66955
-
Chris Lattner authored
llvm-svn: 66954
-
Douglas Gregor authored
- C++ function casts, e.g., T(foo) - sizeof(), alignof() More importantly, this allows us to verify that we're performing overload resolution during template instantiation, with argument-dependent lookup and the "cached" results of name lookup from the template definition. llvm-svn: 66947
-
Fariborz Jahanian authored
corresponding to block pointer. llvm-svn: 66940
-
Daniel Dunbar authored
llvm-svn: 66939
-
Ted Kremenek authored
to return an owning pointer. llvm-svn: 66934
-
Mike Stump authored
llvm-svn: 66931
-
Douglas Gregor authored
llvm-svn: 66924
-
Douglas Gregor authored
instantiation for binary operators. This change moves most of the operator-overloading code from the parser action ActOnBinOp to a new, parser-independent semantic checking routine CreateOverloadedBinOp. Of particular importance is the fact that CreateOverloadedBinOp does *not* perform any name lookup based on the current parsing context (it doesn't take a Scope*), since it has to be usable during template instantiation, when there is no scope information. Rather, it takes a pre-computed set of functions that are visible from the context or via argument-dependent lookup, and adds to that set any member operators and built-in operator candidates. The set of functions is computed in the parser action ActOnBinOp based on the current context (both operator name lookup and argument-dependent lookup). Within a template, the set computed by ActOnBinOp is saved within the type-dependent AST node and is augmented with the results of argument-dependent name lookup at instantiation time (see TemplateExprInstantiator::VisitCXXOperatorCallExpr). Sadly, we can't fully test this yet. I'll follow up with template instantiation for sizeof so that the real fun can begin. llvm-svn: 66923
-
Daniel Dunbar authored
- Enough stuff works now we can test argument parsing & pipelining. llvm-svn: 66913
-
Daniel Dunbar authored
llvm-svn: 66912
-
Daniel Dunbar authored
- language recognition was recognizing prefixes incorrectly. - -x none wasn't working. - test for "can lipo" was backwords. - missed a '"' in -ccc-print-phases llvm-svn: 66911
-
Chris Lattner authored
really horrible extensions that are disabled by default but that can be accepted by -fheinous-gnu-extensions (but which always emit a warning when enabled). As our first instance of this, implement PR3788/PR3794, which allows non-lvalues in inline asms in contexts where lvalues are required. bleh. llvm-svn: 66910
-
Chris Lattner authored
llvm-svn: 66909
-
Daniel Dunbar authored
llvm-svn: 66908
-
Daniel Dunbar authored
-ccc-print-options. llvm-svn: 66907
-
Daniel Dunbar authored
llvm-svn: 66906
-
rdar://problem/6675489Steve Naroff authored
Also changed BlockDecl API to be more consistent (wrt FunctionDecl). llvm-svn: 66904
-
Ted Kremenek authored
conditions. Currently the analyzer does not reason well about promotions/truncations of symbolic values, so at branch conditions when we see: if (condition) and condition is something like a 'short' or 'char', essentially ignore the promotion to 'int' so that we track constraints on the original symbolic value. We only ignore the casts if the underlying type has the same or fewer bits as the converted type. This fixes: <rdar://problem/6619921> llvm-svn: 66899
-
rdar://problem/6451399Steve Naroff authored
This solution is much simpler (and doesn't add any per-scope overhead, which concerned Chris). The only downside is the LabelMap is now declared in two places (Sema and BlockSemaInfo). My original fix tried to unify the LabelMap in "Scope" (which would support nested functions in general). In any event, this fixes the bug given the current language definition. If/when we decide to support GCC style nested functions, this will need to be tweaked. llvm-svn: 66896
-
Ted Kremenek authored
llvm-svn: 66894
-
Steve Naroff authored
Remove ActiveScope (revert http://llvm.org/viewvc/llvm-project?view=rev&revision=65694 and http://llvm.org/viewvc/llvm-project?view=rev&revision=66741). Will replace with something better today... llvm-svn: 66893
-
Ted Kremenek authored
is 64-bit. I used his suggestion of doing a direct bitwidth/signedness conversion of the 'offset' instead of just changing the sign. For more information, see: http://lists.cs.uiuc.edu/pipermail/cfe-dev/2009-March/004587.html llvm-svn: 66892
-
Daniel Dunbar authored
llvm-svn: 66889
-
Daniel Dunbar authored
llvm-svn: 66888
-
Daniel Dunbar authored
llvm-svn: 66887
-
Daniel Dunbar authored
to perform). Still doesn't do anything interesting. - This code came out much cleaner than in ccc with the reworked phases & mapping of types to lists of compilation steps (phases) to perform. llvm-svn: 66885
-
Gabor Greif authored
llvm-svn: 66884
-
Daniel Dunbar authored
llvm-svn: 66883
-
Daniel Dunbar authored
provide information about what steps should be done for a particular file type. llvm-svn: 66881
-
Daniel Dunbar authored
llvm-svn: 66880
-
Chris Lattner authored
defaults to off. When enabled, it emits range info along with the file/line/col information for a diagnostic. This allows tools that textually parse the output of clang to know where the ranges are, even if they span multiple lines. For example, with: $ clang exprs.c -fprint-source-range-info We now produce: exprs.c:21:11:{21:12-21:13}: warning: use of unary operator that may be intended as compound assignment (+=) var =+ 5; // expected-warning {{use of unary operator that may be intended as compound assignment (+=)}} ^~ exprs.c:22:11:{22:12-22:13}: warning: use of unary operator that may be intended as compound assignment (-=) var =- 5; // expected-warning {{use of unary operator that may be intended as compound assignment (-=)}} ^~ exprs.c:36:13:{36:3-36:12}: error: assignment to cast is illegal, lvalue casts are not supported (float*)X = P; // expected-error {{assignment to cast is illegal, lvalue casts are not supported}} ~~~~~~~~~ ^ exprs.c:41:4:{41:3-41:4}: error: called object type 'int' is not a function or function pointer X(); // expected-error {{called object type 'int' is not a function or function pointer}} ~^ exprs.c:45:15:{45:8-45:14}{45:17-45:24}: error: invalid operands to binary expression ('int *' and '_Complex float') P = (P-42) + Gamma*4; // expected-error {{invalid operands to binary expression ('int *' and '_Complex float')}} ~~~~~~ ^ ~~~~~~~ exprs.c:61:7:{61:16-61:22}: error: invalid application of '__alignof' to bitfield R = __alignof(P->x); // expected-error {{invalid application of '__alignof' to bitfield}} expected-warning {{extension used}} ^ ~~~~~~ Note the range info after the column in the initial diagnostic. This is obviously really annoying if you're not a tool parsing the output of clang, which is why it is off by default. llvm-svn: 66862
-
Daniel Dunbar authored
llvm-svn: 66858
-
Daniel Dunbar authored
Also, add some FIXMEs, improve doxygen & comments. llvm-svn: 66857
-
Fariborz Jahanian authored
source being a non-pointer. llvm-svn: 66854
-
Douglas Gregor authored
C++ templates. In particular, keep track of the overloaded operators that are visible from the template definition, so that they can be merged with those operators visible via argument-dependent lookup at instantiation time. Refactored the lookup routines for argument-dependent lookup and for operator name lookup, so they can be called without immediately adding the results to an overload set. Instantiation of these expressions is completely wrong. I'll work on that next. llvm-svn: 66851
-
Daniel Dunbar authored
print-{multi-{directory,lib,os-directory}, search-dirs} as unsupported instead of handling separately. llvm-svn: 66848
-