summaryrefslogtreecommitdiffstats
path: root/clang/test/Index/c-index-api-loadTU-test.m
Commit message (Collapse)AuthorAgeFilesLines
* Indexer: add CXObjCPropertyAttr_class for class properties.Manman Ren2016-05-311-1/+6
| | | | | | rdar://25963227 llvm-svn: 271351
* [test] Fix tests in non-darwin bots.Argyrios Kyrtzidis2015-08-051-1/+1
| | | | llvm-svn: 244176
* [test/Index] Update libclang tests to use libclang for creating PCH files.Argyrios Kyrtzidis2015-08-051-1/+1
| | | | | | | This is consistent and tests the primary configuration we want to test, libclang creating and consuming PCH files. llvm-svn: 244066
* Revert "Revert r241620 and follow-up commits" and move the initializationAdrian Prantl2015-07-081-1/+1
| | | | | | of the llvm targets from clang/CodeGen into ClangCheck.cpp and CIndex.cpp. llvm-svn: 241653
* Revert r241620 and follow-up commits while investigating linux buildbot ↵Adrian Prantl2015-07-071-1/+1
| | | | | | failures. llvm-svn: 241642
* Wrap clang modules and pch files in an object file container.Adrian Prantl2015-07-071-1/+1
| | | | | | | | | | | | | This patch adds ObjectFilePCHContainerOperations uses the LLVM backend to put the contents of a PCH into a __clangast section inside a COFF, ELF, or Mach-O object file container. This is done to facilitate module debugging by makeing it possible to store the debug info for the types defined by a module alongside the AST. rdar://problem/20091852 llvm-svn: 241620
* Revert "Wrap clang module files in a Mach-O, ELF, or COFF container."Adrian Prantl2015-02-251-1/+1
| | | | llvm-svn: 230454
* Wrap clang module files in a Mach-O, ELF, or COFF container.Adrian Prantl2015-02-251-1/+1
| | | | | | | | | | | | | | | | | This is a necessary prerequisite for debugging with modules. The .pcm files become containers that hold the serialized AST which allows us to store debug information in the module file that can be shared by all object files that were built importing the module. This reapplies r230044 with a fixed configure+make build and updated dependencies and testcase requirements. Over the last iteration this version adds - missing target requirements for testcases that specify an x86 triple, - a missing clangCodeGen.a dependency to libClang.a in the make build. rdar://problem/19104245 llvm-svn: 230423
* [libclang] Provide location for attributes and expose 'packed' attribute.Argyrios Kyrtzidis2013-09-251-7/+7
| | | | | | Patch by Loïc Jaquemet! llvm-svn: 191345
* [libclang] Introduce clang_Cursor_getObjCPropertyAttributes to query the ↵Argyrios Kyrtzidis2013-04-181-1/+1
| | | | | | | | written attributes in a property declaration. rdar://13684512 llvm-svn: 179803
* Have clang_getSpellingLocation() use the same logic as DiagnosticRenderer ↵Ted Kremenek2012-12-181-12/+26
| | | | | | | | | | | | for plowing through macros. This fixes a subtle bug reported in <rdar://problem/12584554> where a double-nested macro could lead to an incorrect fixit location with live issues. This fix also uncovers a bunch of subtle bugs in our indexer test cases which are now fixed (mostly around source ranges for attributes). llvm-svn: 170468
* Introduce a new libclang API to determine the platform availability ofDouglas Gregor2012-05-081-1/+1
| | | | | | | | a given entity, so that we can tell when the entity was introduced/deprecated/obsoleted on each platform for which we have an annotation. Addresses <rdar://problem/11365715>. llvm-svn: 156347
* [libclang] For a ↵Argyrios Kyrtzidis2012-03-231-15/+15
| | | | | | | | | | CXCursor_ObjCInstanceMethodDecl/CXCursor_ObjCClassMethodDecl cursor, return from clang_getCursorLocation the start location of the method name. rdar://11105223 llvm-svn: 153303
* Expose more statement, expression, and declaration kinds in libclang,Douglas Gregor2011-10-051-2/+2
| | | | | | from Manuel Holtgrewe! llvm-svn: 141200
* Improve location fidelity of objc decls.Argyrios Kyrtzidis2011-10-041-6/+6
| | | | | | | | -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
* Make -fobjc-nonfragile-abi the -cc1 default, since it's theJohn McCall2011-10-021-1/+1
| | | | | | | | | | | | | | | | | | | increasingly prevailing case to the point that new features like ARC don't even support the fragile ABI anymore. This required a little bit of reshuffling with exceptions because a check was assuming that ObjCNonFragileABI was only being set in ObjC mode, and that's actually a bit obnoxious to do. Most, though, it involved a perl script to translate a ton of test cases. Mostly no functionality change for driver users, although there are corner cases with disabling language-specific exceptions that we should handle more correctly now. llvm-svn: 140957
* Like IBOutletCollection, it only makes sense to apply the IBOutlet ↵Ted Kremenek2011-09-291-2/+2
| | | | | | annotation to Objective-C object types. Fixes <rdar://problem/10142685>. llvm-svn: 140778
* [libclang] Report implicit objc methods for properties when indexing.Argyrios Kyrtzidis2011-09-261-0/+4
| | | | | | Related to rdar://10087069. llvm-svn: 140551
* [libclang] For getDeclFromExpr in CIndex.cpp, associate the decl ofArgyrios Kyrtzidis2011-09-121-1/+1
| | | | | | | 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
* Mark objc methods that are implicitly declared for properties (not ↵Argyrios Kyrtzidis2011-08-171-4/+0
| | | | | | | | user-declared) as implicit. This results in libclang ignoring such methods. llvm-svn: 137852
* When creating a property in a class extension, make sure to check itsDouglas Gregor2011-07-151-0/+11
| | | | | | attributes. Fixes <rdar://problem/9561076>. llvm-svn: 135273
* Fixed source range for StaticAssertDecl and LinkageSpecDecl. Fixed source ↵Abramo Bagnara2011-03-081-1/+1
| | | | | | range for declarations using postfix types. llvm-svn: 127251
* Fixed source range for all DeclaratorDecl's.Abramo Bagnara2011-03-081-6/+6
| | | | llvm-svn: 127225
* Fixed TypedefDecl and TemplateTypeParameter source range.Abramo Bagnara2011-03-061-1/+1
| | | | llvm-svn: 127119
* Remove a rogue typoDouglas Gregor2010-10-051-1/+1
| | | | llvm-svn: 115618
* Register the __builtin_va_list_type node when we parse it, rather thanDouglas Gregor2010-10-051-1/+1
| | | | | | | | waiting until we think we need it: we didn't catch all of the places where we actually needed it, and we probably wouldn't ever. Fixes a C++ PCH crasher. llvm-svn: 115617
* Add libclang support for label statements, gotos, and taking theDouglas Gregor2010-09-101-5/+0
| | | | | | address of a label (GNU extension). llvm-svn: 113564
* Add libclang API hook "clang_getIBOutletCollectionType" to query the ↵Ted Kremenek2010-08-261-2/+7
| | | | | | collection type for iboutletcollection attributes. llvm-svn: 112139
* Introduce new libclang API functions that determine the availabilityDouglas Gregor2010-08-231-2/+2
| | | | | | | of a cursor or code-completion result, e.g., whether that result refers to an unavailable, deleted, or deprecated declaration. llvm-svn: 111858
* Add test case that was causing an infinite loop when reading PCH files. The ↵Douglas Gregor2010-07-141-0/+4
| | | | | | test works with ToT Clang already llvm-svn: 108318
* Add clang support for IBOutletCollection.Ted Kremenek2010-05-191-0/+22
| | | | llvm-svn: 104135
* Re-apply r103581 with updated tests. It turns out we were computing bogus ↵Ted Kremenek2010-05-121-7/+9
| | | | | | | | locations for many things. llvm-svn: 103583
* Allow GNU attributes to appear in an Objective-C method declarationTed Kremenek2010-02-181-1/+5
| | | | | | | before the selector name (but after the return type). Among other things, this allows IBAction to be implemented with an attribute. llvm-svn: 96623
* Change cursor behavior for attributes to have them visited as part of recursingTed Kremenek2010-02-181-1/+1
| | | | | | to the children of a Decl. llvm-svn: 96599
* Add basic cursor traversal for attributes. We currently don't have sourceTed Kremenek2010-02-181-74/+63
| | | | | | ranges for Attr objects, so lookup by cursor location currently doesn't work. llvm-svn: 96571
* c-index-test: Unify and always print half-open extents.Daniel Dunbar2010-02-141-60/+60
| | | | llvm-svn: 96160
* c-index-test: Unify syntax for printing extents. Yes, there were 4.Daniel Dunbar2010-02-141-60/+60
| | | | llvm-svn: 96158
* Loosen preconditions for clang_getCursorSpelling(), returning an emptyDouglas Gregor2010-01-251-5/+5
| | | | | | | string when given a cursor that does not have a name. Also, don't give silly names for statements and non-reference expressions. llvm-svn: 94426
* Move the type specifier location for elaborated-type-specifiers fromDouglas Gregor2010-01-251-1/+1
| | | | | | | the tag kind (union, struct, class, enum) over to the name of the tag, if there is a name, since most clients want to point at the name. llvm-svn: 94424
* Teach CIndex's cursor visitor to restrict its traversal to a specificDouglas Gregor2010-01-221-11/+28
| | | | | | | | | | | | | | region of interest (if provided). Implement clang_getCursor() in terms of this traversal rather than using the Index library; the unified cursor visitor is more complete, and will be The Way Forward. Minor other tweaks needed to make this work: - Extend Preprocessor::getLocForEndOfToken() to accept an offset from the end, making it easy to move to the last character in the token (rather than just past the end of the token). - In Lexer::MeasureTokenLength(), the length of whitespace is zero. llvm-svn: 94200
* Teach the cursor visitor to walk all of the C and Objective-CDouglas Gregor2010-01-221-0/+13
| | | | | | | | declarations that have enough source information to make such a walk useful. This includes walking into variable initializers and enum constants, the types behind typedefs, etc. llvm-svn: 94124
* Teach the cursor visitor to walk statements and expressions, includingDouglas Gregor2010-01-211-0/+12
| | | | | | a few important subkinds. Now we're cookin' with gas! llvm-svn: 94116
* Teach the cursor visitor to walk into a variety of different TypeLocDouglas Gregor2010-01-211-2/+5
| | | | | | kinds, so that we see referenced types, protocols, classes, etc. llvm-svn: 94085
* Introduce type references into the C API, capturing references toDouglas Gregor2010-01-211-0/+1
| | | | | | typedefs only (for now). llvm-svn: 94078
* Eliminate cursor kinds used to express definitions. Instead, provideDouglas Gregor2010-01-191-12/+12
| | | | | | | | | | | | CIndex functions that (1) map from a reference or declaration to the corresponding definition, if available, and (2) determine whether a given declaration cursor is also a definition. This eliminates a lot of duplication in the cursor kinds, and maps more closely to the Clang ASTs. This is another API + ABI breaker with no deprecation. Yay, progress. llvm-svn: 93893
* Introduce clang_getCursorReferenced, to get a cursor pointing at theDouglas Gregor2010-01-191-6/+6
| | | | | | entity that a particular cursor references. llvm-svn: 93830
* Implement clang_getCursorExtent, which provides a source range for theDouglas Gregor2010-01-191-5/+5
| | | | | | | | | | | | | cursor itself. In particular, for references this returns the source range of the reference rather than the source range of the thing it refers to. Switch c-index-test from clang_getDeclExtent (which will eventually be deprecated and removed) over to clang_getCursorExtent. The source ranges we print for references now make sense; fix up the tests appropriately. llvm-svn: 93823
* Replace clang_getDeclUSR() with clang_getCursorUSR(). Also remove printing ↵Ted Kremenek2010-01-181-28/+28
| | | | | | 'contexts' from c-index-test output; it wasn't helpful and was extremely brittle. llvm-svn: 93760
* Give ObjCClassRef cursors a sane representation, which is encapsulatedDouglas Gregor2010-01-161-3/+3
| | | | | | | | | in CXCursor.cpp. With this sane representation, fix the class reference that is part of Objective-C category declarations so that the cursor's location matches up with the reference, not the class being referred to. llvm-svn: 93640
* Improve location information for Objective-C category declarations. WeDouglas Gregor2010-01-161-1/+1
| | | | | | | | | | | | | previously only had a single location (the @ in @interface); now we know where the @ is (for the start of the declaration), where the class name is (that's the normal "location" now for diagnostics), and where the category name is. Also, eliminated the redundant "end" location, since ObjCContainerDecl already has better @end information. The only XFAIL'd test is temporary; will un-XFAIL-it once I've taught CIndex how to use the new locations. llvm-svn: 93639
OpenPOWER on IntegriCloud