| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
|
|
|
|
| |
Switch some warnings over to errors which should never have been warnings
in the first place. (Also, a minor fix to the preprocessor rules for
integer literals while I'm here.)
llvm-svn: 186903
|
| |
|
|
| |
llvm-svn: 186899
|
| |
|
|
|
|
|
|
| |
__byref_variable_layout.
rdar://problem/14386148
llvm-svn: 186898
|
| |
|
|
|
|
|
| |
protocols by ignoring cases where all protocol properties
and methods are optional.
llvm-svn: 186895
|
| |
|
|
|
|
| |
Fixes rdar://problem/14386148
llvm-svn: 186894
|
| |
|
|
|
|
|
|
|
|
| |
getLocForEndOfToken() isn't guaranteed to succeed; if it doesn't, make sure
we do something sane.
Fixes PR16673. I'm not sure how to write a testcase for this short of grepping
through the diagnostic output.
llvm-svn: 186889
|
| |
|
|
|
|
|
|
|
|
|
| |
compiler itself.
The headers in the compiler's own resource include directory are
system headers, which means we don't stat() them eagerly when loading
a module. Use module.map as a proxy for these headers and the compiler
itself. Fixes <rdar://problem/13856838>.
llvm-svn: 186870
|
| |
|
|
| |
llvm-svn: 186864
|
| |
|
|
|
|
| |
Warning should be emitted only for InitListExpr nodes.
llvm-svn: 186859
|
| |
|
|
|
|
| |
have shift/bitwise operators or are power of 2.
llvm-svn: 186856
|
| |
|
|
|
|
|
|
| |
ARC errors in the checking phase.
rdar://14490204
llvm-svn: 186850
|
| |
|
|
| |
llvm-svn: 186848
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
signatures with the same name.
Summary:
Add support for overloaded matchers.
This composes with other features, like supporting polymorphic matchers.
Reviewers: klimek
CC: cfe-commits, revane
Differential Revision: http://llvm-reviews.chandlerc.com/D1188
llvm-svn: 186836
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Based on Peter Collingbourne's destructor patches.
Prior to this change, clang was considering ?1 to be the complete
destructor and the base destructor, which was wrong. This lead to
crashes when clang tried to emit two LLVM functions with the same name.
In this ABI, TUs with non-inline dtors might not emit a complete
destructor. They are emitted as inline thunks in TUs that need them,
and they always delegate to the base dtors of the complete class and its
virtual bases. This change uses the DeferredDecls machinery to emit
complete dtors as needed.
Currently in clang try body destructors can catch exceptions thrown by
virtual base destructors. In the Microsoft C++ ABI, clang may not have
the destructor definition, in which case clang won't wrap the virtual
virtual base destructor calls in a try-catch. Diagnosing this in user
code is TODO.
Finally, for classes that don't use virtual inheritance, MSVC always
calls the base destructor (?1) directly. This is a useful code size
optimization that avoids emitting lots of extra thunks or aliases.
Implementing it also means our existing tests continue to pass, and is
consistent with MSVC's output.
We can do the same for Itanium by tweaking GetAddrOfCXXDestructor, but
it will require further testing.
Reviewers: rjmccall
CC: cfe-commits
Differential Revision: http://llvm-reviews.chandlerc.com/D1066
llvm-svn: 186828
|
| |
|
|
|
|
| |
Now we can save GD.getDecl() in D and shorten some casts.
llvm-svn: 186826
|
| |
|
|
|
|
| |
when initializing aggregate/union types, no matter if static or not.
llvm-svn: 186817
|
| |
|
|
|
|
|
|
|
|
|
|
| |
No functionality change.
In Sema helper functions:
* renamed isTypeName as HasTypenameKeyword
In UsingDecl:
* renamed get/setUsingLocation to get/setUsingLoc
* renamed is/setTypeName as has/setTypename
llvm-svn: 186816
|
| |
|
|
| |
llvm-svn: 186807
|
| |
|
|
|
|
| |
any default template arguments, not if it inherits some.
llvm-svn: 186804
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
A constructor for an abstract class does not call constructors for virtual
base classes, so it is not an error if no initializer is present for the
virtual base and the virtual base cannot be default initialized.
Also provide a (disabled by default, for now) warning for the case where a
virtual base class's initializer is ignored in an abstract class's constructor,
and address a defect in DR257 where it was not carried through to C++11's rules
for implicit deletion of special member functions.
Based on a patch by Maurice Bos.
llvm-svn: 186803
|
| |
|
|
|
|
| |
[-Wdocumentation]
llvm-svn: 186802
|
| |
|
|
|
|
|
|
|
| |
optimize, to follow the permissions granted in N3664. Under those rules, only
calls generated by new-expressions and delete-expressions are permitted to be
optimized, and direct calls to ::operator new and ::operator delete must be
treated as normal calls.
llvm-svn: 186799
|
| |
|
|
|
|
| |
consistency with other fields and to be explicit about bit count.
llvm-svn: 186796
|
| |
|
|
| |
llvm-svn: 186795
|
| |
|
|
| |
llvm-svn: 186794
|
| |
|
|
| |
llvm-svn: 186793
|
| |
|
|
| |
llvm-svn: 186770
|
| |
|
|
|
|
| |
implicit conversion sequence.
llvm-svn: 186769
|
| |
|
|
|
|
|
|
|
| |
The functionality is equivalent to the GCC attribute. Variables of tagged
types will be warned about as unused if they are not used in any way
except for possible (even non-trivial) ctors/dtors called. Useful for tagging
classes like std::string (which is not part of this commit).
llvm-svn: 186765
|
| |
|
|
| |
llvm-svn: 186764
|
| |
|
|
|
|
|
|
| |
Every #include is surrounded by #if 0 in order to comment it out, which adds
lines. That is fixed up right after, but that all can be inside #if part
that is not processed, so fix up also after every end of a conditional part.
llvm-svn: 186763
|
| |
|
|
| |
llvm-svn: 186762
|
| |
|
|
|
|
|
|
|
|
| |
Diag ID is used throughout clang as a sentinel id meaning "this is an
invalid diagnostic id." Confusingly, Diag ID maps to a valid, usable,
diagnostic id. Instead, start diagnostic ids at ID one.
Incidently, remove an unused element from StaticDiagInfo.
llvm-svn: 186760
|
| |
|
|
|
|
|
| |
template. Passing around dependent types can lead to integral arguments that
cannot be evaluated.
llvm-svn: 186757
|
| |
|
|
|
|
|
|
|
|
|
|
| |
A class with a field of non-POD-for-layout type is not POD-for-layout.
This computation should not depend on whether the field is of POD type
in the language sense.
Fixes PR16537.
Patch by Josh Magee.
llvm-svn: 186741
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
This is the same way GenericSelectionExpr works, and it's generally a
more consistent approach.
A large part of this patch is devoted to caching the value of the condition
of a ChooseExpr; it's needed to avoid threading an ASTContext into
IgnoreParens().
Fixes <rdar://problem/14438917>.
llvm-svn: 186738
|
| |
|
|
|
|
|
|
| |
templates and explicit specializations
This patch essentially removes all the FIXMEs following calls to DeduceTemplateArguments() that want to keep track of deduction failure info.
llvm-svn: 186730
|
| |
|
|
|
|
|
|
| |
diagnosis of bad template argument deductions."
This reverts commit a730f548325756d050d4caaa28fcbffdae8dfe95.
llvm-svn: 186729
|
| |
|
|
|
|
|
| |
Make sure we correctly expand packs which expand to another
pack in a function type.
llvm-svn: 186728
|
| |
|
|
|
|
| |
bad template argument deductions.
llvm-svn: 186727
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
I'm not sure how to write a test for this; the following shows the
difference in -ast-dump:
template <int x> struct A {};
template <class T> struct B { };
template <class ...Args> using C = A<(__is_trivially_constructible(Args...))>;
template <class ...Args> using D = C<B<Args>...>;
However, I can't seem to write a test that triggers a visible difference
in behavior.
llvm-svn: 186726
|
| |
|
|
|
|
|
| |
The mode doesn't actually do anything yet, but this provides a
way to get into it.
llvm-svn: 186720
|
| |
|
|
|
|
|
|
|
|
|
|
| |
the selector family
Summary: In ARC mode, clang emits a warning if the result of an 'init' method is unused but miss cases where the method does not follows the Cocoa naming convention but is properly declared as an init family method.
CC: cfe-commits, eli.friedman
Differential Revision: http://llvm-reviews.chandlerc.com/D1163
llvm-svn: 186718
|
| |
|
|
|
|
| |
declaration which can be migrated to NS_ENUM.
llvm-svn: 186716
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary:
Add printToStream*(llvm::raw_ostream&) methods to Diagnostics, and reimplement everything based on streams instead of concatenating strings.
Also, fix some functions to start with lowercase to match the style guide.
Reviewers: klimek
CC: cfe-commits, revane
Differential Revision: http://llvm-reviews.chandlerc.com/D1187
llvm-svn: 186715
|
| |
|
|
|
|
|
|
|
|
|
|
| |
Canonical types are unchanged. The type printer had to be changed to
avoid printing any non-default implicit calling convention as well as
the calling convention attribute.
Reviewers: rjmccall
Differential Revision: http://llvm-reviews.chandlerc.com/D1132
llvm-svn: 186714
|
| |
|
|
|
|
|
|
|
|
| |
When we see a pack, and replace it with a template argument which is
also a pack, we want to use the pack pattern, not the expanded pack.
The caller should take care of expanding the pack afterwards.
Fixes PR16646.
llvm-svn: 186713
|
| |
|
|
|
|
| |
-mcheck-zero-division.
llvm-svn: 186710
|
| |
|
|
|
|
|
|
|
|
| |
"@synthesize of 'weak' property is only
allowed in ARC" errors.
rdar://14461559
llvm-svn: 186709
|
| |
|
|
|
|
| |
single diagnostic that selects. No functional changes intended.
llvm-svn: 186708
|