| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary:
This fixes PR17145 and avoids unknown pragma warnings.
This change does not attempt to map MSVC warning numbers to clang
warning flags. Perhaps in the future we will implement a mapping for
some common subset of Microsoft warnings, but for now we don't.
Reviewers: rsmith
CC: cfe-commits
Differential Revision: http://llvm-reviews.chandlerc.com/D1652
llvm-svn: 190726
|
|
|
|
| |
llvm-svn: 190515
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This patch is the first step to make module-map-files modular (instead
of requiring a single "module.map"-file per include directory). This
step adds a new "extern module" declaration that enables
module-map-files to reference one another along with a very basic
implementation.
The next steps are:
* Combine this with the use-declaration (from
http://llvm-reviews.chandlerc.com/D1546) in order to only load module
map files required for a specific compilation.
* Add an additional flag to start with a specific module-map-file (instead
of requiring there to be at least one "module.map").
Review: http://llvm-reviews.chandlerc.com/D1637
llvm-svn: 190497
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary: This is a Clang part of http://llvm-reviews.chandlerc.com/D1534
Reviewers: jordan_rose, klimek, rsmith
Reviewed By: rsmith
CC: cfe-commits
Differential Revision: http://llvm-reviews.chandlerc.com/D1535
llvm-svn: 189583
|
|
|
|
|
|
|
|
|
| |
Apparently, gcc's -traditional-cpp behaves slightly differently in C++ mode;
specifically, it discards "//" comments. Match gcc's behavior.
<rdar://problem/14808126>
llvm-svn: 189515
|
|
|
|
|
|
| |
No functionality change intended.
llvm-svn: 189112
|
|
|
|
|
|
|
|
|
|
|
| |
If the user has requested this warning, we should emit it, even if it's not
an extension in the current language mode. However, being an extension is
more important, so prefer the pedantic warning or the pedantic-compatibility
warning if those are enabled.
<rdar://problem/12922063>
llvm-svn: 189110
|
|
|
|
|
|
|
|
|
| |
Basically, isInMainFile considers line markers, and isWrittenInMainFile
doesn't. Distinguishing between the two is useful when dealing with
files which are preprocessed files or rewritten with -frewrite-includes
(so we don't, for example, print useless warnings).
llvm-svn: 188968
|
|
|
|
|
|
| |
literals.
llvm-svn: 188918
|
|
|
|
|
|
| |
escape code.
llvm-svn: 188863
|
|
|
|
|
|
| |
fix a typo in a comment.
llvm-svn: 188857
|
|
|
|
|
|
| |
insertion of ObjC audit pragmas.
llvm-svn: 188733
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
double-width characters in FixIt-hints.
Summary: This is a follow-up to r187837.
Reviewers: gribozavr, jordan_rose
Reviewed By: jordan_rose
CC: cfe-commits
Differential Revision: http://llvm-reviews.chandlerc.com/D1306
llvm-svn: 188056
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
DataFlowSanitizer is a generalised dynamic data flow analysis.
Unlike other Sanitizer tools, this tool is not designed to detect a
specific class of bugs on its own. Instead, it provides a generic
dynamic data flow analysis framework to be used by clients to help
detect application-specific issues within their own code.
Differential Revision: http://llvm-reviews.chandlerc.com/D966
llvm-svn: 187925
|
|
|
|
|
|
|
| |
This patch was created by Lawrence Crowl and reviewed in:
http://llvm-reviews.chandlerc.com/D963
llvm-svn: 187738
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This unifies the unix and windows versions of FileManager::UniqueDirContainer
and FileManager::UniqueFileContainer by using UniqueID.
We cannot just replace "struct stat" with llvm::sys::fs::file_status, since we
want to be able to construct fake ones, and file_status has different members
on unix and windows.
What the patch does is:
* Record only the information that clang is actually using.
* Use llvm::sys::fs::status instead of stat and fstat.
* Use llvm::sys::fs::UniqueID
* Delete the old windows versions of UniqueDirContainer and
UniqueFileContainer since the "unix" one now works on windows too.
llvm-svn: 187619
|
|
|
|
|
|
| |
Patch by Ethan Jackson.
llvm-svn: 187365
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Beginning with svn r186971, we noticed an internal test started to fail when
using clang built with LTO. After much investigation, it turns out that there
are no blatant bugs here, we are just running out of stack space and crashing.
Preprocessor::ReadFunctionLikeMacroArgs already has one vector of 64 Tokens,
and r186971 added another. When built with LTO, that function is inlined into
Preprocessor::HandleMacroExpandedIdentifier, which for our internal test is
invoked in a deep recursive cycle. I'm leaving the original 64 Token vector
alone on the assumption that it is important for performance, but the new
FixedArgTokens vector is only used on an error path, so it should be OK if it
requires additional heap storage. It would be even better if we could avoid
the deep recursion, but I think this change is a good thing to do regardless.
<rdar://problem/14540345>
llvm-svn: 187315
|
|
|
|
|
|
|
|
|
| |
This allows the ObjFW runtime to correctly implement message forwarding
for messages which return a struct.
Patch by Jonathan Schleifer.
llvm-svn: 187174
|
|
|
|
|
|
|
|
| |
It turns out that Plum Hall depends on us not emitting an error on
integer literals which fit into long long, but fit into
unsigned long long. So C99 conformance requires not conforming to C99. :)
llvm-svn: 187172
|
|
|
|
|
|
|
|
| |
cxx_init_capture. "generalized" is neither descriptive nor future-proof. No
compatibility problems expected, since we've never advertised having this
feature.
llvm-svn: 187058
|
|
|
|
| |
llvm-svn: 187055
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
function-like macro. Clang will attempt to correct the arguments by detecting
braced initializer lists:
1) If possible, suggest parentheses around arguments
containing braced lists which will give the proper number of arguments.
2) If a braced list is detected at the start of a macro argument, it cannot be
corrected by parentheses. Instead, just point out the location of these
braced lists.
llvm-svn: 186971
|
|
|
|
|
|
|
| |
* Allow ns, us, ms, s, min, h as numeric ud-suffixes
* Allow s as string ud-suffix
llvm-svn: 186933
|
|
|
|
|
|
|
|
| |
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: 186770
|
|
|
|
| |
llvm-svn: 186707
|
|
|
|
| |
llvm-svn: 186547
|
|
|
|
|
|
| |
Austin Seipp!
llvm-svn: 185896
|
|
|
|
|
|
|
| |
with identifier info. This covers most identifier-like entities (other than
the ISO646 keywords).
llvm-svn: 185895
|
|
|
|
| |
llvm-svn: 185715
|
|
|
|
| |
llvm-svn: 185280
|
|
|
|
| |
llvm-svn: 185164
|
|
|
|
|
|
|
|
|
|
|
|
| |
This allows clang to parse the type_traits header in Visual Studio 2012,
which is included widely in practice.
This is a rework of r163022 by João Matos. The original patch broke
preprocessing of gtest headers, which this patch addresses.
Patch by Will Wilson!
llvm-svn: 184968
|
|
|
|
|
|
|
|
|
| |
a system module.
This prevents -pedantic from causing warnings in the system headers
used to create modules. Fixes <rdar://problem/14201171>.
llvm-svn: 184560
|
|
|
|
|
|
|
| |
headers may be included from within the module, but not from outside
the module.
llvm-svn: 184471
|
|
|
|
|
|
| |
succession. Fixes PR16363.
llvm-svn: 184240
|
|
|
|
|
|
|
|
| |
and a '!defined(X)' if we find a broken header guard. This is suboptimal; we
should point the diagnostic at the 'X' token not the 'if' token, but it fixes
the crash.
llvm-svn: 184054
|
|
|
|
|
|
|
|
| |
properly. This warning checks that the #ifndef and #define directives at
the beginning of a header refer to the same macro name. Includes a fix-it
hint to correct the header guard.
llvm-svn: 183867
|
|
|
|
|
|
| |
I am about to move PathV2.h to Path.h.
llvm-svn: 183795
|
|
|
|
|
|
|
|
|
|
|
|
| |
When x is empty, x ## is suppressed, and when y gets expanded, the fact that it follows ## is not
available in the macro expansion result. The macro definition can be checked instead, the ## will
be available there regardless of what x expands to.
Fixes http://llvm.org/PR12767
Patch by Harald van Dijk!
llvm-svn: 182699
|
|
|
|
| |
llvm-svn: 182675
|
|
|
|
|
|
|
|
|
|
| |
instead of trying to continue in an invalid state.
Also don't let libclang create a PCH with such an error.
Fixes rdar://13953768
llvm-svn: 182629
|
|
|
|
|
|
| |
module but isn't itself part of a module.
llvm-svn: 182263
|
|
|
|
|
|
|
|
| |
function macro arguments.
This is a modified version of a patch by Manuel Klimek.
llvm-svn: 182055
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The most common (non-buggy) case are where such objects are used as
return expressions in bool-returning functions or as boolean function
arguments. In those cases I've used (& added if necessary) a named
function to provide the equivalent (or sometimes negative, depending on
convenient wording) test.
DiagnosticBuilder kept its implicit conversion operator owing to the
prevalent use of it in return statements.
One bug was found in ExprConstant.cpp involving a comparison of two
PointerUnions (PointerUnion did not previously have an operator==, so
instead both operands were converted to bool & then compared). A test
is included in test/SemaCXX/constant-expression-cxx1y.cpp for the fix
(adding operator== to PointerUnion in LLVM).
llvm-svn: 181869
|
|
|
|
|
|
| |
completes the implementation of N3638.
llvm-svn: 181669
|
|
|
|
|
|
| |
in system header directories.
llvm-svn: 181643
|
|
|
|
| |
llvm-svn: 181583
|
|
|
|
|
|
|
|
| |
This made sense in pre-module era, before merging of HeaderFileInfos was introduced.
Final part of rdar://13840148.
llvm-svn: 181490
|