| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
numerous CFG and UninitializedValues analysis changes:
1) Change the CFG to include the DeclStmt for conditional variables, instead of using the condition itself as a faux DeclStmt.
2) Update ExprEngine (the static analyzer) to understand (1), so not to regress.
3) Update UninitializedValues.cpp to initialize all tracked variables to Uninitialized at the start of the function/method.
4) Only use the SelfReferenceChecker (SemaDecl.cpp) on global variables, leaving the dataflow analysis to handle other cases.
The combination of (1) and (3) allows the dataflow-based -Wuninitialized to find self-init problems when the initializer
contained control-flow.
llvm-svn: 128858
|
|
|
|
|
|
|
|
| |
Microsoft mode.
This fixes a bunch of errors when compiling MSVC header files with the -DDLL flag.
llvm-svn: 128457
|
|
|
|
|
|
|
|
|
|
|
| |
This is basically the same idea as the warning on uninitialized uses of
fields within an initializer list. As such, it is on by default and
under -Wuninitialized.
Original patch by Richard Trieu, with some massaging from me on the
wording and grouping of the diagnostics.
llvm-svn: 128376
|
|
|
|
|
|
| |
usually useless, but not always.
llvm-svn: 128326
|
|
|
|
|
|
| |
parse it though, although that will change shortly.
llvm-svn: 128277
|
|
|
|
|
|
| |
redeclaration context of each declaration in the identifier chain. Should fix Linux self-host
llvm-svn: 128210
|
|
|
|
|
|
|
|
|
| |
AttributeLists do not accumulate over the lifetime of parsing, but are
instead reused. Also make the arguments array not require a separate
allocation, and make availability attributes store their stuff in
augmented memory, too.
llvm-svn: 128209
|
|
|
|
| |
llvm-svn: 128118
|
|
|
|
| |
llvm-svn: 128075
|
|
|
|
|
|
| |
specifier occurs explicitly.
llvm-svn: 127877
|
|
|
|
| |
llvm-svn: 127876
|
|
|
|
|
|
|
|
| |
reference-to-void type). Don't crash if it does.
Also fix an issue where type source information for the resulting type was being lost.
llvm-svn: 127811
|
|
|
|
|
|
| |
dependent scope and produce an error (rather than crashing). Fixes PR8979.
llvm-svn: 127749
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
forward-looking "goto" statement, make sure to insert it *after* the
last declaration in the identifier resolver's declaration chain that
is either outside of the function/block/method's scope or that is
declared in that function/block/method's specific scope. Previously,
we could end up inserting the label ahead of declarations in inner
scopes, confusing C++ name lookup.
Fixes PR9491/<rdar://problem/9140426> and <rdar://problem/9135994>.
Note that the crash-on-invalid PR9495 is *not* fixed. That's a
separate issue.
llvm-svn: 127737
|
|
|
|
|
|
|
|
|
| |
cannot yet be resolved, be sure to push the new label declaration into
the right place within the identifier chain. Otherwise, name lookup in
C++ gets confused when searching for names that are lexically closer
than the label. Fixes PR9463.
llvm-svn: 127623
|
|
|
|
| |
llvm-svn: 127596
|
|
|
|
|
|
|
|
| |
Change the interface to expose the new information and deal with the enormous fallout.
Introduce the new ExceptionSpecificationType value EST_DynamicNone to more easily deal with empty throw specifications.
Update the tests for noexcept and fix the various bugs uncovered, such as lack of tentative parsing support.
llvm-svn: 127537
|
|
|
|
| |
llvm-svn: 127404
|
|
|
|
|
|
| |
a...", it appears to cause us to reject various valid codes.
llvm-svn: 127373
|
|
|
|
| |
llvm-svn: 127330
|
|
|
|
|
|
| |
varienty of cases. // rdar://9092208
llvm-svn: 127257
|
|
|
|
|
|
| |
keywords for Objective-C+ and C++0x.
llvm-svn: 127253
|
|
|
|
|
|
| |
range for declarations using postfix types.
llvm-svn: 127251
|
|
|
|
| |
llvm-svn: 127225
|
|
|
|
|
|
| |
dependent scope and produce an error (rather than crashing). Fixes PR8979.
llvm-svn: 127206
|
|
|
|
|
|
|
|
| |
It will accept flexible array in union and also as the sole element of a struct/class.
Fixes rdar://9065507.
llvm-svn: 127171
|
|
|
|
|
|
|
|
|
|
|
| |
of a C++0x inline namespace within enclosing namespaces, as noted in
C++0x [namespace.def]p8.
Fixes <rdar://problem/9006349>, a libc++ failure where Clang was
rejected an explicit specialization of std::swap (since libc++ puts it
into an inline, versioned namespace std::__1).
llvm-svn: 127162
|
|
|
|
| |
llvm-svn: 127120
|
|
|
|
| |
llvm-svn: 127119
|
|
|
|
| |
llvm-svn: 127111
|
|
|
|
|
|
| |
trigger the ExprTemplates.empty() check at the end of a function body
llvm-svn: 127046
|
|
|
|
| |
llvm-svn: 127042
|
|
|
|
| |
llvm-svn: 126939
|
|
|
|
| |
llvm-svn: 126888
|
|
|
|
|
|
|
| |
which is important for libclang's token-annotation and
where's-my-cursor functionality. Fixes <rdar://problem/9004439>.
llvm-svn: 126887
|
|
|
|
|
|
|
| |
used for attributes that are okay to inherit when written on a parameter.
Dependent on LLVM r126827.
llvm-svn: 126828
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
nested-name-speciciers within elaborated type names, e.g.,
enum clang::NestedNameSpecifier::SpecifierKind
Fixes in this iteration include:
(1) Compute the type-source range properly for a dependent template
specialization type that starts with "template template-id ::", as
in a member access expression
dep->template f<T>::f()
This is a latent bug I triggered with this change (because now we're
checking the computed source ranges for dependent template
specialization types). But the real problem was...
(2) Make sure to set the qualifier range on a dependent template
specialization type appropriately. This will go away once we push
nested-name-specifier locations into dependent template
specialization types, but it was the source of the
valgrind errors on the buildbots.
llvm-svn: 126765
|
|
|
|
|
|
| |
location information for elaborated types. *sigh*
llvm-svn: 126753
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
information for qualifier type names throughout the parser to address
several problems.
The commit message from r126737:
Push nested-name-specifier source location information into elaborated
name types, e.g., "enum clang::NestedNameSpecifier::SpecifierKind".
Aside from the normal changes, this also required some tweaks to the
parser. Essentially, when we're looking at a type name (via
getTypeName()) specifically for the purpose of creating an annotation
token, we pass down the flag that asks for full type-source location
information to be stored within the returned type. That way, we retain
source-location information involving nested-name-specifiers rather
than trying to reconstruct that information later, long after it's
been lost in the parser.
With this change, test/Index/recursive-cxx-member-calls.cpp is showing
much improved results again, since that code has lots of
nested-name-specifiers.
llvm-svn: 126748
|
|
|
|
|
|
| |
buildbot breakage.
llvm-svn: 126746
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
name types, e.g., "enum clang::NestedNameSpecifier::SpecifierKind".
Aside from the normal changes, this also required some tweaks to the
parser. Essentially, when we're looking at a type name (via
getTypeName()) specifically for the purpose of creating an annotation
token, we pass down the flag that asks for full type-source location
information to be stored within the returned type. That way, we retain
source-location information involving nested-name-specifiers rather
than trying to reconstruct that information later, long after it's
been lost in the parser.
With this change, test/Index/recursive-cxx-member-calls.cpp is showing
much improved results again, since that code has lots of
nested-name-specifiers.
llvm-svn: 126737
|
|
|
|
|
|
|
|
| |
source-location information. We don't actually preserve this
information in any of the resulting TypeLocs (yet), so it doesn't
matter.
llvm-svn: 126693
|
|
|
|
|
|
|
| |
tag definitions. Also, add support for template instantiation of
NestedNameSpecifierLocs.
llvm-svn: 126470
|
|
|
|
|
|
| |
Sema::PopBlockOrFunctionScope(). No real functionality change.
llvm-svn: 126287
|
|
|
|
|
|
| |
in the same declaration group in the template instantiation case.
llvm-svn: 126279
|
|
|
|
|
|
|
|
| |
* Flag indicating 'we're parsing this auto typed variable's initializer' moved from VarDecl to Sema
* Temporary template parameter list for auto deduction is now allocated on the stack.
* Deduced 'auto' types are now uniqued.
llvm-svn: 126139
|
|
|
|
|
|
| |
This fixes PR 8738, 9060 and 9132.
llvm-svn: 126069
|
|
|
|
|
|
| |
correct and is not worth fixing. Fixes PR8396.
llvm-svn: 126035
|
|
|
|
|
|
|
| |
own weird little DenseMap. Hey look, we now emit unused label
warnings deterministically, amazing.
llvm-svn: 125813
|
|
|
|
|
|
|
|
|
|
| |
making them be template instantiated in a more normal way and
make them handle attributes like other decls.
This fixes the used/unused label handling stuff, making it use
the same infrastructure as other decls.
llvm-svn: 125771
|