| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
name mangling in the Itanium C++ ABI for lambda expressions is so
dependent on context, we encode the number used to encode each lambda
as part of the lambda closure type, and maintain this value within
Sema.
Note that there are a several pieces still missing:
- We still get the linkage of lambda expressions wrong
- We aren't properly numbering or mangling lambda expressions that
occur in default function arguments or in data member initializers.
- We aren't (de-)serializing the lambda numbering tables
llvm-svn: 150982
|
|
|
|
|
|
|
|
| |
TemplateIdAnnotation.
Found by valgrind.
llvm-svn: 150940
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
loop and switch statements, by teaching Scope that a function scope never has
a continue/break parent for the purposes of control flow. Remove the hack in
block and lambda expressions which worked around this by pretending that such
expressions were continue/break scopes.
Remove Scope::ControlParent, since it's unused.
In passing, teach default statements to recover properly from a missing ';', and
add a fixit for same to both default and case labels (the latter already
recovered correctly).
llvm-svn: 150776
|
|
|
|
|
|
|
| |
trailing return type but not a '()'. Recover by inserting the
parentheses. Thanks to Xeo on IRC for the example.
llvm-svn: 150727
|
|
|
|
|
|
|
|
| |
hold the used constructor itself.""
This reintroduces commit r150682 with a fix for the Bullet benchmark crash.
llvm-svn: 150685
|
|
|
|
|
|
|
|
|
|
| |
used constructor itself."
It leads to a compiler crash in the Bullet benchmark.
This reverts commit r12014.
llvm-svn: 150684
|
|
|
|
|
|
|
|
|
|
| |
constructor itself.
Holding the constructor directly makes no sense when list-initialized arrays come into play. The constructor is now held in a CXXConstructExpr, if construction is what is done. The new design can also distinguish properly between list-initialization and direct-initialization, as well as implicit default-initialization constructors and explicit value-initialization constructors. Finally, doing it this way removes redundance from the AST because CXXNewExpr doesn't try to handle both the allocation and the initialization responsibilities.
This breaks the static analysis of new expressions. I've filed PR12014 to track this.
llvm-svn: 150682
|
|
|
|
| |
llvm-svn: 150583
|
|
|
|
|
|
| |
[&values...] { print(values...); }
llvm-svn: 150497
|
|
|
|
|
|
| |
expressions. Array new still missing.
llvm-svn: 150346
|
|
|
|
|
|
|
|
| |
thing in cases involving array new.
Show that many cases using initializer list constructors work, in that they parse and pass semantic analysis.
llvm-svn: 150316
|
|
|
|
|
|
|
|
|
|
|
|
| |
default is '=', and reword the warning about explicitly capturing
'this' in such lambdas to indicate that only explicit capture is
banned.
Introduce Fix-Its for this and other "save the programmer from
themself" rules regarding what can be explicitly captured and what
must be implicitly captured.
llvm-svn: 150256
|
|
|
|
|
|
| |
process removed some naming ambiguities.
llvm-svn: 149870
|
|
|
|
| |
llvm-svn: 149127
|
|
|
|
| |
llvm-svn: 149124
|
|
|
|
|
|
|
|
| |
Pass a typo correction callback object from ParseCastExpr to
Sema::ActOnIdExpression to be a bit more selective about what kinds of
corrections will be allowed for unknown identifiers.
llvm-svn: 148973
|
|
|
|
|
|
|
| |
This makes all sorts of fun examples work with decltype.
Reviewed by Richard Smith.
llvm-svn: 148787
|
|
|
|
| |
llvm-svn: 148577
|
|
|
|
|
|
| |
and less error-prone way of handling the relevant cases. Towards marking of whether a declaration is used more accurately.
llvm-svn: 148522
|
|
|
|
|
|
| |
!=, %=, ^=, &=, *=, -=, |=, /=, <<=, <=, >=, and >>= to =.
llvm-svn: 148499
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
instead of just suggesting a ';'.
Old error:
plusequaldeclare1.cc:3:8: error: expected ';' at end of declaration
int x += 6;
^
;
New error:
plusequaldeclare1.cc:3:9: error: invalid '+=' at end of declaration; did you
mean '='?
int x += 6;
^~
=
llvm-svn: 148433
|
|
|
|
|
|
| |
This allows -Wswitch-enum to find switches that need updating when these enums are modified.
llvm-svn: 148281
|
|
|
|
|
|
| |
lambda parameters work correctly, recording more information into the AST.
llvm-svn: 147650
|
|
|
|
|
|
| |
pieces to build the lambda class and its call operator. Create an actual scope for the lambda body.
llvm-svn: 147595
|
|
|
|
|
|
| |
BlockLiteralContext. Use it to ensure semantic analysis of types isn't confused by the lack of a type specifier.
llvm-svn: 147522
|
|
|
|
| |
llvm-svn: 147517
|
|
|
|
|
|
| |
use it. Unconditionally error on lambda expressions because they don't work in any meaningful way yet.
llvm-svn: 147515
|
|
|
|
| |
llvm-svn: 147260
|
|
|
|
| |
llvm-svn: 146847
|
|
|
|
|
|
| |
Reviewed by Eli Friedman.
llvm-svn: 146738
|
|
|
|
| |
llvm-svn: 146155
|
|
|
|
| |
llvm-svn: 145785
|
|
|
|
|
|
|
| |
a class is marked 'final', from Alberto Ganesh Barbati! Fixes
PR11462.
llvm-svn: 145775
|
|
|
|
|
|
|
| |
entering the context of a nested-name-specifier. Fixes
<rdar://problem/10397846>.
llvm-svn: 143967
|
|
|
|
| |
llvm-svn: 143907
|
|
|
|
| |
llvm-svn: 142478
|
|
|
|
| |
llvm-svn: 142056
|
|
|
|
|
|
|
| |
'final', and don't accept (then silently discard) braced init lists in C++98
new-expressions.
llvm-svn: 142048
|
|
|
|
|
|
| |
Lack of half FP was a regression compared to llvm-gcc.
llvm-svn: 142016
|
|
|
|
|
|
|
| |
delimiter pairs and detect when we exceed the implementation limit for
nesting depth, from Aaron Ballman!
llvm-svn: 141782
|
|
|
|
|
|
|
|
|
|
|
| |
and DefaultFunctionArrayLvalueConversion. To prevent
significant regression for should-this-be-a-call fixits,
and to repair some such regression from the introduction of
bound member placeholders, make those placeholder checks
try to build calls appropriately. Harden the build-a-call
logic while we're at it.
llvm-svn: 141738
|
|
|
|
| |
llvm-svn: 140407
|
|
|
|
| |
llvm-svn: 140367
|
|
|
|
|
|
|
| |
erronously trigger the digraph correction fix-it. Include a new test to catch
this in the future.
llvm-svn: 140175
|
|
|
|
|
|
| |
It already works (and is useful with) macro locs as well.
llvm-svn: 140057
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
For instance:
template <class T> void E() {};
class F {};
void test() {
::E<::F>();
E<::F>();
}
Gives the following error messages:
error: found '<::' after a template name which forms the
digraph '<:' (aka '[') and a ':', did you mean '< ::'?
::E<::F>();
^~~
< ::
error: expected expression
E<::F>();
^
error: expected ']'
note: to match this '['
E<::F>();
This patch adds the digraph fix-it check right before the name lookup,
moves the shared checking code to a new function, and adds new
tests to catch future regressions.
llvm-svn: 140039
|
|
|
|
|
|
|
|
| |
that this flag must be used only for Microsoft extensions and not emulation; to avoid confusion with the new LangOptions::MicrosoftMode flag.
Many of the code now under LangOptions::MicrosoftExt will eventually be moved under the LangOptions::MicrosoftMode flag.
llvm-svn: 139987
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Previously we would cut off the source file buffer at the code-completion
point; this impeded code-completion inside C++ inline methods and,
recently, with buffering ObjC methods.
Have the code-completion inserted into the source buffer so that it can
be buffered along with a method body. When we actually hit the code-completion
point the cut-off lexing or parsing.
Fixes rdar://10056932&8319466
llvm-svn: 139086
|
|
|
|
|
|
| |
David Blaikie!
llvm-svn: 136876
|
|
|
|
|
|
|
|
| |
LLVM.h imports
them into the clang namespace.
llvm-svn: 135852
|