Migrate two other places where the same logic is used to use the helper function that already exists.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@152022 91177308-0d34-0410-b5e6-96231b3b80d8
-Make sure we don't change to '__weak' a __block variable used as output.
-Make sure we don't apply __weak twice.
Fixes rdar://10520757&10521362
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@152020 91177308-0d34-0410-b5e6-96231b3b80d8
Introduce PreprocessingRecord::rangeIntersectsConditionalDirective() which returns
true if a given range intersects with a conditional directive block.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@152018 91177308-0d34-0410-b5e6-96231b3b80d8
-Add location parameter for the directives callbacks
-Skip callbacks if the directive is inside a skipped range.
-Make sure the directive callbacks are invoked in source order.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@152017 91177308-0d34-0410-b5e6-96231b3b80d8
kinds as the underlying string literals, and we silently drop the ud-suffix;
those issues will be fixed by subsequent patches.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@152012 91177308-0d34-0410-b5e6-96231b3b80d8
we're making. We only ignore implicit casts. Add a testcase showing that
we get the right behavior with explicit casts.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@151994 91177308-0d34-0410-b5e6-96231b3b80d8
- This is a more reliable default, as it behaves better on failure and also
ensures that we create *new* files (instead of reusing existing inodes). This
is useful for other applications (like lldb) which want to cache inode's to
know when a file has been rewritten.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@151961 91177308-0d34-0410-b5e6-96231b3b80d8
- This would otherwise happen as a side effect of llvm::sys::fs::unique_file creating parent directories.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@151960 91177308-0d34-0410-b5e6-96231b3b80d8
scalar emission of DeclRefExprs to const bools: emit scalar bools as i1,
not as i8.
In addition to the extra unit testing, this has successfully bootstrapped.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@151955 91177308-0d34-0410-b5e6-96231b3b80d8
the corresponding files to avoid confusion.
This is a preparation to adding an AST-based call graph to Analysis. The
existing call graph works with indexer entries. We might be able to
refactor it to use the AST based graph in the future.
(Minimal testing here as the only example that uses the API has been
completely broken, does not compile.)
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@151950 91177308-0d34-0410-b5e6-96231b3b80d8
issue the note if it is because message is sent to a forward class
declaration in delayed diagnostic. // rdar://10290322
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@151942 91177308-0d34-0410-b5e6-96231b3b80d8
ptrdiff_t on PPC32 on Linux, etc. should be int not long.
This does not matter for C, but it does matter for C++ because of
name mangling.
The preprocessor test has been changed accordingly.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@151935 91177308-0d34-0410-b5e6-96231b3b80d8
command line options for inlining tuning.
This adds the option for stack depth bound as well as function size
bound.
+ minor doxygenification
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@151930 91177308-0d34-0410-b5e6-96231b3b80d8
Unconditionally define __C99FEATURES__ when using C++ on Solaris. This is a
(hopefully temporary) work around for libc++ exposing C99-but-not-C++98
features in C++98 mode.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@151889 91177308-0d34-0410-b5e6-96231b3b80d8
early, since their values can be used in constant expressions in C++11. For
odr-use checking, the opposite change is required, since references are
odr-used whether or not they satisfy the requirements for appearing in a
constant expression.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@151881 91177308-0d34-0410-b5e6-96231b3b80d8
is no odr-use of the variable. Go slightly beyond what the standard requires
for variables of reference type.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@151879 91177308-0d34-0410-b5e6-96231b3b80d8
Also fix handling of macros within calls in the HTMLDiagnostics.
This also adds a test case for r151774.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@151872 91177308-0d34-0410-b5e6-96231b3b80d8
But it is in the underlying c part of clang. clang crashes
in IRGen when passing an incomplete type argument to
variadic function (instead of diagnosing the bug).
// rdar://10961370
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@151862 91177308-0d34-0410-b5e6-96231b3b80d8