Argyrios Kyrtzidis
ffd530f2c0
[libclang] Do ConcurrencyCheck for clang_getLocation as well.
...
llvm-svn: 141583
2011-10-10 21:57:15 +00:00
John McCall
f937c023bf
Rename TagDecl::isDefinition -> isCompleteDefinition
...
for better self-documenting code, since the semantics
are subtly different from getDefinition().
llvm-svn: 141355
2011-10-07 06:10:15 +00:00
Eli Friedman
0dfb889575
Support for C1x _Atomic specifier (see testcase). This is primarily being committed at the moment to help support C++0x <atomic>, but it should be a solid base for implementing the full specification of C1x _Atomic.
...
Thanks to Jeffrey Yasskin for the thorough review!
llvm-svn: 141330
2011-10-06 23:00:33 +00:00
Erik Verbruggen
338b55cc73
Fixed GCC (C90) and Clang warnings.
...
llvm-svn: 141281
2011-10-06 11:38:08 +00:00
Erik Verbruggen
2e657ffd8e
Added CXAvailability_NotAccessible to indicate that a declaration is available, but not accessible from the current code completion context.
...
llvm-svn: 141278
2011-10-06 07:27:49 +00:00
Argyrios Kyrtzidis
cddafd3969
[libclang] Introduce clang_findReferencesInFile which accepts a cursor, a file,
...
and a callback and finds all identifier references of the cursor in the file.
rdar://7948304
llvm-svn: 141277
2011-10-06 07:00:54 +00:00
Argyrios Kyrtzidis
3b947f72da
[libclang] Move the bulk of clang_getOverriddenCursors into
...
a cxcursor::getOverriddenCursors C++ function, because SmallVectors
are groovier that malloc'ing buffers.
llvm-svn: 141276
2011-10-06 07:00:46 +00:00
Douglas Gregor
4c362d5310
Expose more statement, expression, and declaration kinds in libclang,
...
from Manuel Holtgrewe!
llvm-svn: 141200
2011-10-05 19:00:14 +00:00
Bob Wilson
05de0298d2
Rip out flags for controlling C++ "production mode" separately.
...
This is old leftover cruft from the days when C++ was not yet ready
for prime time.
llvm-svn: 141063
2011-10-04 05:34:14 +00:00
Argyrios Kyrtzidis
52f53fb303
Improve location fidelity of objc decls.
...
-Add the location of the class name to all objc container decls, not just ObjCInterfaceDecl.
-Make objc decls consistent with the rest of the NamedDecls and have getLocation() point to the
class name, not the location of '@'.
llvm-svn: 141061
2011-10-04 04:48:02 +00:00
Argyrios Kyrtzidis
12afd70370
[libclang] Introduce CXCursor_CXXAccessSpecifier for C++'s public:/private:/protected: specifiers.
...
Patch by Paolo Capriotti!
llvm-svn: 140864
2011-09-30 17:58:23 +00:00
Argyrios Kyrtzidis
e7e4291448
[libclang] Introduce clang_Range_isNull.
...
llvm-svn: 140706
2011-09-28 18:14:21 +00:00
NAKAMURA Takumi
37a4674fdc
Install c-index-test also on CMake build, following up r140681.
...
llvm-svn: 140694
2011-09-28 10:50:23 +00:00
Ted Kremenek
7f01c7b5f1
Install c-index-test as part of install-clang-c Makefile rule.
...
llvm-svn: 140681
2011-09-28 04:39:41 +00:00
Douglas Gregor
c0b07286cf
When 'bool' is not a built-in type but is defined as a macro, print
...
'bool' rather than '_Bool' within types, to make things a bit more
readable. Fixes <rdar://problem/10063263>.
llvm-svn: 140650
2011-09-27 22:38:19 +00:00
Argyrios Kyrtzidis
2b0cf60df3
[libclang] Expose array size and element type, patch by Vinay Sajip!
...
llvm-svn: 140614
2011-09-27 17:44:34 +00:00
Argyrios Kyrtzidis
a1bcb6adb5
MSVC is stuck in the 80s.
...
llvm-svn: 140597
2011-09-27 04:14:36 +00:00
Argyrios Kyrtzidis
fd51520d5f
[libclang] Refactor the important stuff in clang_getCursor into a cxcursor::getCursor(CXTranslationUnit, SourceLocation) function.
...
llvm-svn: 140588
2011-09-27 00:30:33 +00:00
Argyrios Kyrtzidis
d6e9fa55eb
[libclang] Introduce clang_Cursor_isNull and clang_Cursor_getTranslationUnit functions.
...
llvm-svn: 140587
2011-09-27 00:30:30 +00:00
Argyrios Kyrtzidis
a4fa0d8be7
[libclang] Report implicit objc methods for properties when indexing.
...
Related to rdar://10087069.
llvm-svn: 140551
2011-09-26 19:05:37 +00:00
Argyrios Kyrtzidis
4cdfcae75d
Don't map a file:line:col triplet that is inside the preamble range to
...
a "loaded" location of the precompiled preamble.
Instead, handle specially locations of preprocessed entities:
-When looking up for preprocessed entities, map main file locations inside the
preamble range to a preamble loaded location.
-When getting the source range of a preprocessing cursor, map preamble loaded
locations back to main file locations.
Fixes rdar://10175093 & http://llvm.org/PR10999
llvm-svn: 140519
2011-09-26 08:01:41 +00:00
David Blaikie
69609dcead
Rename VerifyDiagnosticsClient to VerifyDiagnosticConsumer as per issue 5397
...
llvm-svn: 140489
2011-09-26 00:38:03 +00:00
David Blaikie
e2eefaecc8
Rename DiagnosticClient to DiagnosticConsumer as per issue 5397
...
llvm-svn: 140479
2011-09-25 23:39:51 +00:00
David Blaikie
9c902b5502
Rename Diagnostic to DiagnosticsEngine as per issue 5397
...
llvm-svn: 140478
2011-09-25 23:23:43 +00:00
David Blaikie
aa347f9392
Removing a bunch of dead returns/breaks after llvm_unreachables.
...
llvm-svn: 140407
2011-09-23 20:26:49 +00:00
David Blaikie
83d382b1ca
Switch assert(0/false) llvm_unreachable.
...
llvm-svn: 140367
2011-09-23 05:06:16 +00:00
Argyrios Kyrtzidis
de6aa08013
Rename ExplicitTemplateArgumentList -> ASTTemplateArgumentListInfo, no functionality change.
...
llvm-svn: 140330
2011-09-22 20:07:03 +00:00
Argyrios Kyrtzidis
45e8cf5732
[libclang] When pointing at a macro expansion inside a macro argument,
...
return a cursor for the inner macro.
llvm-svn: 140207
2011-09-20 23:27:33 +00:00
Ted Kremenek
057b986d9d
Sort exports list.
...
llvm-svn: 140171
2011-09-20 19:02:45 +00:00
Argyrios Kyrtzidis
5733271925
In libclang, when visiting preprocessed entities in a source range, use
...
PreprocessingRecord's getPreprocessedEntitiesInRange.
Also remove all the stuff that were added in ASTUnit that are unnecessary now
that we do a binary search for preprocessed entities and deserialize only
what is necessary.
llvm-svn: 140063
2011-09-19 20:40:48 +00:00
Argyrios Kyrtzidis
7c06d8666b
[libclang] When getting a source location from a file:line:col triplet
...
check whether the requested location points inside the precompiled preamble,
in which case the returned source location will be a "loaded" one.
llvm-svn: 140060
2011-09-19 20:40:35 +00:00
Argyrios Kyrtzidis
e6e67deeed
Rename SourceLocation::getFileLocWithOffset -> getLocWithOffset.
...
It already works (and is useful with) macro locs as well.
llvm-svn: 140057
2011-09-19 20:40:19 +00:00
Erik Verbruggen
852725b615
First test commit.
...
llvm-svn: 140016
2011-09-19 15:03:11 +00:00
Argyrios Kyrtzidis
303e513544
[libclang] Remove libclang.darwin.exports, it's not used anymore.
...
llvm-svn: 139661
2011-09-13 23:12:36 +00:00
Argyrios Kyrtzidis
91672b3c03
[libclang] Introduce clang_getPresumedLocation which works like clang_getExpansionLocation
...
but takes into account #line directives coming from preprocessed files.
Patch by Vinay Sajip!
llvm-svn: 139647
2011-09-13 21:49:08 +00:00
Argyrios Kyrtzidis
4c2131a775
[libclang] Correct annotation and taking of cursor for objc class references
...
inside the IBOutletCollection attribute.
llvm-svn: 139621
2011-09-13 18:49:56 +00:00
Argyrios Kyrtzidis
c179111536
Rename InterFace -> Interface, no functionality change.
...
llvm-svn: 139620
2011-09-13 18:49:52 +00:00
Argyrios Kyrtzidis
2cb4e3c554
[libclang]
...
-Allow cursor visitation of an attribute using its source range
-Add C++ 'final' and 'override' attributes as cursor kinds
-Simplify the logic that marks 'final' and 'override' attributes as tokens.
llvm-svn: 139609
2011-09-13 17:39:31 +00:00
Douglas Gregor
2b9b464290
When compiling a module on-demand, re-use the diagnostics client
...
already provided. This required a little bit of clean-up in the way
that VerifyDiagnosticsClient managed ownership of its underlying
"primary" client, because now it will no longer always take ownership.
llvm-svn: 139570
2011-09-13 01:26:44 +00:00
Argyrios Kyrtzidis
01e3c590ae
[libclang] For getDeclFromExpr in CIndex.cpp, associate the decl of
...
a DeclRefExpr, MemberExpr, etc. with a CastExpr if it is ImplicitCast,
since the implicit cast is the one that is invisible in source code.
llvm-svn: 139547
2011-09-12 22:17:26 +00:00
Argyrios Kyrtzidis
3405baa3f0
[libclang] Make c-index-test check CINDEXTEST_REMAP_AFTER_TRIAL environment variable,
...
which when set it determines the trial number after which the remapping of files should
take effect.
llvm-svn: 139511
2011-09-12 18:09:31 +00:00
Douglas Gregor
98c05b286c
Kill of the Decl::PCHLevel field entirely. We now only need to know
...
whether a Decl was deserialized from an AST file (any AST file).
llvm-svn: 139438
2011-09-10 00:09:20 +00:00
Douglas Gregor
1bbf030b8e
The translation unit is never deserialized
...
llvm-svn: 139436
2011-09-09 23:34:14 +00:00
Anna Zaks
45ce1bf091
[analyzer] When running scan-build with -plist on ./configure, delete the plist files.
...
(scan-build does not set the $HtmlDir when running against configure. Previously, this implied that the plist files would appear in the current directory, with this patch they will get deleted.)
llvm-svn: 139382
2011-09-09 18:43:53 +00:00
James Molloy
98f3e18f25
Fix up MCInstPrinter creation to take the new SubtargetInfo parameter (see LLVM r139237)
...
llvm-svn: 139238
2011-09-07 17:25:30 +00:00
Anna Zaks
5efad63f57
[analyzer] Revert a regression introduced in r133104(The ARC Migration Tool..) due to a merge error.
...
llvm-svn: 138919
2011-08-31 23:53:24 +00:00
Chandler Carruth
4aa01ef19c
Update libclang to have APIs corresponding to the new 'expansion' naming
...
system for macro-backed source locations. The old APIs are preserved for
legacy users.
This was intended to land with the main work of instantiation ->
expansion, but despite running it by Doug over a month ago, I forgot to
commit it. Very sorry for that...
llvm-svn: 138860
2011-08-31 16:53:37 +00:00
Argyrios Kyrtzidis
6b0cf7e5fc
[libclang] Rename some functions and make sure we don't iterate past the tokens array.
...
llvm-svn: 138813
2011-08-30 19:43:19 +00:00
Matt Beaumont-Gay
d6238f4717
Fix type mismatch in initialization (caught by -Wliteral-conversion)
...
llvm-svn: 138736
2011-08-29 16:37:29 +00:00
Nico Weber
5d8f912f50
[analyzer] update bug report url
...
llvm-svn: 138721
2011-08-28 11:50:56 +00:00