| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
|
|
|
| |
llvm-svn: 127111
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
template specialization types. This also required some parser tweaks,
since we were losing track of the nested-name-specifier's source
location information in several places in the parser. Other notable
changes this required:
- Sema::ActOnTagTemplateIdType now type-checks and forms the
appropriate type nodes (+ source-location information) for an
elaborated-type-specifier ending in a template-id. Previously, we
used a combination of ActOnTemplateIdType and
ActOnTagTemplateIdType that resulted in an ElaboratedType wrapped
around a DependentTemplateSpecializationType, which duplicated the
keyword ("class", "struct", etc.) and nested-name-specifier
storage.
- Sema::ActOnTemplateIdType now gets a nested-name-specifier, which
it places into the returned type-source location information.
- Sema::ActOnDependentTag now creates types with source-location
information.
llvm-svn: 126808
|
|
|
|
| |
llvm-svn: 125962
|
|
|
|
|
|
|
| |
own weird little DenseMap. Hey look, we now emit unused label
warnings deterministically, amazing.
llvm-svn: 125813
|
|
|
|
|
|
|
| |
normal "expression" completion. Fixes the most annoying
code-completion bug I've found.
llvm-svn: 125715
|
|
|
|
|
|
|
| |
by the code completion token, treat this as a class message send where
the opening square bracket is missing. Fixes <rdar://problem/6970911>.
llvm-svn: 125587
|
|
|
|
| |
llvm-svn: 125219
|
|
|
|
|
|
|
|
|
|
| |
semantics after the C++0x is_convertible type trait. This
implementation is not 100% complete, because it allows access errors
to be hard errors (rather than just evaluating false).
Original patch by Steven Watanabe!
llvm-svn: 124425
|
|
|
|
| |
llvm-svn: 124276
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
For example:
class A{
public:
A& operator=(const A& that) {
if (this != &that) {
this->A::~A();
this->A::A(that); // <=== explicit constructor call.
}
return *this;
}
};
More work will be needed to support an explicit call to a template constructor.
llvm-svn: 123735
|
|
|
|
|
|
| |
-Wint-to-pointer-cast.
llvm-svn: 123719
|
|
|
|
|
|
|
|
|
| |
parameter pack.
Note that we're missing proper libclang support for the new
SizeOfPackExpr expression node.
llvm-svn: 122813
|
|
|
|
|
|
| |
expression lists.
llvm-svn: 122764
|
|
|
|
|
|
|
| |
on array and function declarators. This is pretty far from complete, and I'll
revisit it later if someone doesn't beat me to it.
llvm-svn: 122535
|
|
|
|
|
|
| |
BinaryTypeTraitExpr.
llvm-svn: 121298
|
|
|
|
|
|
| |
New AST node introduced: BinaryTypeTraitExpr; to be reused for more intrinsics.
llvm-svn: 121074
|
|
|
|
| |
llvm-svn: 119966
|
|
|
|
|
|
| |
literal.
llvm-svn: 116754
|
|
|
|
|
|
|
|
| |
verify that we aren't in a message-send expression before digging into
the identifier or looking ahead more tokens. Fixes a regression
(<rdar://problem/8483253>) I introduced with bracket insertion.
llvm-svn: 114968
|
|
|
|
|
|
| |
errors. Improves code completion in yet another case.
llvm-svn: 114255
|
|
|
|
| |
llvm-svn: 114231
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
of a binary expression, continue on and parse the right-hand side of
the binary expression anyway, but don't call the semantic actions to
type-check. Previously, we would see the error and then, effectively,
skip tokens until the end of the statement.
The result should be more useful recovery, both in the normal case
(we'll actually see errors beyond the first one in a statement), but
it also helps code completion do a much better job, because we do
"real" code completion on the right-hand side of an invalid binary
expression rather than completing with the recovery completion. For
example, given
x = p->y
if there is no variable named "x", we can still complete after the p->
as a member expression. Along the recovery path, we would have
completed after the "->" as if we were in an expression context, which
is mostly useless.
llvm-svn: 114225
|
|
|
|
|
|
| |
the enclosing scope, which confuses gcc v3.4 to no end
llvm-svn: 114174
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
sends. These are far trickier than instance messages, because we
typically have something like
NSArray alloc]
where it appears to be a declaration of a variable named "alloc" up
until we see the ']' (or a ':'), and at that point we can't backtrace.
So, we use a combination of syntactic and semantic disambiguation to
treat this as a message send only when the type is an Objective-C type
and it has the syntax of a class message send (which would otherwise
be ill-formed).
llvm-svn: 114057
|
|
|
|
|
|
|
|
|
|
|
| |
narrow, almost useless case where we're inside a parenthesized
expression, e.g.,
(NSArray alloc])
The solution to the general case still eludes me.
llvm-svn: 114039
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
'[' is missing. Prior commits improving recovery also improved code
completion beyond the first selector, e.g., at or after the "to" in
calculator add:x to:y
but not after "calculator". We now provide the same completions for
calculator <CC>
that we would for
[calculator <CC>
if "calculator" is an expression whose type is something that can
receive Objective-C messages.
This code completion works for instance and super message sends, but not
class message sends.
llvm-svn: 113976
|
|
|
|
|
|
|
|
| |
super method:arg]
will now recover nicely and insert the '[' before 'super'.
llvm-svn: 113971
|
|
|
|
|
|
| |
a getFoo]
llvm-svn: 113969
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
part of parser recovery. For example, given:
a method1:arg];
we detect after parsing the expression "a" that we have the start of a
message send expression. We pretend we've seen a '[' prior to the a,
then parse the remainder as a message send. We'll then give a
diagnostic+fix-it such as:
fixit-objc-message.m:17:3: error: missing '[' at start of message
send expression
a method1:arg];
^
[
The algorithm here is very simple, and always assumes that the open
bracket goes at the beginning of the message send. It also only works
for non-super instance message sends at this time.
llvm-svn: 113968
|
|
|
|
|
|
|
|
| |
expression, e.g., after the '(' that could also be a type cast. Here,
we provide types as code-completion results in C/Objective-C (C++
already had them), although we wouldn't in a normal expression context.
llvm-svn: 113904
|
|
|
|
| |
llvm-svn: 113642
|
|
|
|
| |
llvm-svn: 113622
|
|
|
|
|
|
|
|
| |
with comma-separated lists. We never actually used the comma
locations, nor did we store them in the AST, but we did manage to
waste time during template instantiation to produce fake locations.
llvm-svn: 113495
|
|
|
|
| |
llvm-svn: 113356
|
|
|
|
| |
llvm-svn: 112905
|
|
|
|
| |
llvm-svn: 112577
|
|
|
|
|
|
| |
some issues being sorted out.
llvm-svn: 112493
|
|
|
|
|
|
|
|
|
|
| |
The extra data stored on user-defined literal Tokens is stored in extra
allocated memory, which is managed by the PreprocessorLexer because there isn't
a better place to put it that makes sure it gets deallocated, but only after
it's used up. My testing has shown no significant slowdown as a result, but
independent testing would be appreciated.
llvm-svn: 112458
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
an '&' expression from the second caller of ActOnIdExpression.
Teach template argument deduction that an overloaded id-expression
doesn't give a valid type for deduction purposes to a non-static
member function unless the expression has the correct syntactic
form.
Teach ActOnIdExpression that it shouldn't try to create implicit
member expressions for '&function', because this isn't a
permitted form of use for member functions.
Teach CheckAddressOfOperand to diagnose these more carefully.
Some of these cases aren't reachable right now because earlier
diagnostics interrupt them.
llvm-svn: 112258
|
|
|
|
|
|
|
|
|
| |
One who seeks the Tao unlearns something new every day.
Less and less remains until you arrive at non-action.
When you arrive at non-action,
nothing will be left undone.
llvm-svn: 112244
|
|
|
|
| |
llvm-svn: 111999
|
|
|
|
|
|
|
| |
M-x query-replace-regexp
\(Sema::\|Action::\|Parser::\|\)Owning\(Expr\|Stmt\)Result -> \2Result
llvm-svn: 111903
|
|
|
|
| |
llvm-svn: 111901
|
|
|
|
| |
llvm-svn: 111863
|
|
|
|
| |
llvm-svn: 111795
|
|
|
|
|
|
|
|
|
| |
- move DeclSpec &c into the Sema library
- move ParseAST into the Parse library
Reflect this change in a thousand different includes.
Reflect this change in the link orders.
llvm-svn: 111667
|
|
|
|
|
|
|
| |
the code-completion consumer. The consumer can use this information to
augument, filter, or display the code-completion results.
llvm-svn: 110858
|
|
|
|
|
|
|
| |
but we were parsing the C grammar. Handle the C++ grammar
appropriately. Fixes PR7794.
llvm-svn: 110445
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
parenthesized, unlike in C++, e.g.,
C has: typeof ( expression)
C++ has: typeof unary-expression
So, once we've parsed a parenthesized expression after typeof, we
should only go on to parse the postfix expression suffix if we're in
C++. Fixes <rdar://problem/8237491>.
llvm-svn: 109606
|
|
|
|
| |
llvm-svn: 108676
|