summaryrefslogtreecommitdiffstats
path: root/clang/lib/Index/IndexingContext.cpp
Commit message (Collapse)AuthorAgeFilesLines
* [Index] Prevent canonical decl becoming nullptrKrasimir Georgiev2017-07-181-2/+4
| | | | | | | | | | | | | | | | | | Summary: This patch prevents getCanonicalDecl returning nullptr in case it finds a canonical TemplateDeclaration with no attached TemplatedDecl. Found by running the indexer over a version of the standard library deep inside a template metaprogramming mess. Reviewers: klimek, vsk Reviewed By: vsk Subscribers: vsk, arphaman, cfe-commits Differential Revision: https://reviews.llvm.org/D35212 llvm-svn: 308269
* [index] Don't add relation to a NamedDecl with no nameBen Langmuir2017-07-121-5/+9
| | | | | | | | | | | | Unless it's one of the special cases (tag, category) that we can handle. This syncs up the check between handling a decl and handling a relation. This would cause invalid nameless decls to end up in relations despite having no name or USR. rdar://problem/32474406 llvm-svn: 307855
* [index] The references to enum constants from member enums that areAlex Lorenz2017-05-231-1/+9
| | | | | | | | | from template instantiations should refer to the enum constant in the pattern enum in the base template rdar://32325459 llvm-svn: 303651
* [index] The references to member enums from template instantiations shouldAlex Lorenz2017-05-231-0/+5
| | | | | | | | refer to the pattern member enum in the base template rdar://32325459 llvm-svn: 303650
* [index] The references to type aliases and typedefs from templateAlex Lorenz2017-05-231-7/+8
| | | | | | | | | instantiations should refer to the pattern type aliases / typedefs in the base templates rdar://32325459 llvm-svn: 303648
* [index] The references to fields from nested records in template instantiationsAlex Lorenz2017-05-231-6/+14
| | | | | | | | should refer to the pattern fields in the nested records in the base templates rdar://32352429 llvm-svn: 303647
* [index] The references to records from template instantiations should referAlex Lorenz2017-05-231-0/+5
| | | | | | | | to the pattern records in the base templates rdar://32325459 llvm-svn: 303646
* [index] References to fields from template instantiations should refer toAlex Lorenz2017-05-151-0/+15
| | | | | | | | fields in base templates rdar://32197158 llvm-svn: 303068
* [index] The relation between the declarations in template specializationsAlex Lorenz2017-04-241-0/+4
| | | | | | | | | | | | that 'override' declarations in the base template should be recorded This can be used for improved "go to definition" feature in Xcode. rdar://31604739 Differential Revision: https://reviews.llvm.org/D32020 llvm-svn: 301180
* [index] Take advantage of 'external_source_symbol' attribute for indexing ↵Argyrios Kyrtzidis2017-04-211-0/+11
| | | | | | | | | purposes - Ignore decls marked as 'generated_declaration' - Include the 'defined_in' in the USR for additional namespacing llvm-svn: 300949
* [index] Record class template specializations using a new 'SpecializationOf'Alex Lorenz2017-04-201-0/+1
| | | | | | | | | | relationship rdar://31603531 Differential Revision: https://reviews.llvm.org/D32010 llvm-svn: 300832
* Fix MSVC 'not all control paths return a value' warning.Simon Pilgrim2017-03-241-0/+1
| | | | llvm-svn: 298712
* [index] When indexing system headers make sure to report important reference ↵Argyrios Kyrtzidis2017-03-231-1/+44
| | | | | | | | | | relations Even if we exclude plain reference occurrences, we should include relation-based references, like the 'base' one. rdar://31010737 llvm-svn: 298622
* [index] Add 'Parameter' symbol kind and 'Local' symbol property to ↵Argyrios Kyrtzidis2017-02-261-31/+3
| | | | | | | | | | | | distinguish function-local symbols Parameters have a 'child' relation to their function/method. Also add an option '-include-locals' to 'c-index-test core' to enable indexing of function-local symbols. Original patch from Nathan Hawes with some changes by me. https://reviews.llvm.org/D30304 llvm-svn: 296282
* [index] Improvde how we handle synthesized ObjC properties and the ↵Argyrios Kyrtzidis2017-02-171-5/+8
| | | | | | | | | | | | associated ivars. Related synthesized properties with the ivar they use with the 'accessor' relation, and make sure we mark them 'implicit' when appropriate. Patch by Nathan Hawes! https://reviews.llvm.org/D30012 llvm-svn: 295416
* [index] Add 'IBTypeOf' relation for ObjC methods marked with IBAction and ↵Argyrios Kyrtzidis2017-01-111-2/+8
| | | | | | properties with IBOutletCollection. llvm-svn: 291703
* [index] Add 'contained-by' relation between references and their lexical ↵Argyrios Kyrtzidis2017-01-111-2/+7
| | | | | | container. llvm-svn: 291700
* [index] Handle properly C++14's template variables.Argyrios Kyrtzidis2016-11-071-4/+6
| | | | | | | | | - Infer the right symbol kind. - Provide a templated USR, similar to how we handle class templates. rdar://28980398 llvm-svn: 286154
* [index] Fix assertion hit when handling a declaration of C++'s 'operator ↵Argyrios Kyrtzidis2016-11-021-10/+0
| | | | | | | | | | | new' function. Part of this is to allow creating a USR for the canonical decl of that which is implicit and does not have a source location. rdar://28978992 llvm-svn: 285868
* [index] Index system ImportDecls even when there is a DeclarationsOnly filterBen Langmuir2016-07-141-2/+2
| | | | | | | | | | | | Whether we call an ImportDecl a decl or a reference symbol role is somewhat academic, but in practice it's more like a declaration because it is interesting even to consumers who wouldn't care about references. Most importantly, we want to report the module dependencies of system modules even when we have declaration-only filtering. rdar://problem/27134855 llvm-svn: 275454
* [index] Fix regression where ObjC method declarations may mistakenly get ↵Argyrios Kyrtzidis2016-03-311-3/+3
| | | | | | | | indexed as definition. rdar://25372906 llvm-svn: 265042
* [index] Make sure that declarations of builtin functions are indexed.Argyrios Kyrtzidis2016-03-171-2/+5
| | | | | | rdar://25154630 llvm-svn: 263689
* Pacify gcc's parenthesis warning, which doesn't realize that parens don't ↵Manuel Klimek2016-03-091-3/+2
| | | | | | matter here. llvm-svn: 263004
* [index] Add a message for the assertion, NFC.Argyrios Kyrtzidis2016-03-091-1/+2
| | | | llvm-svn: 262991
* [index] Fix assertion hit when indexing re-declarations of built-in functions.Argyrios Kyrtzidis2016-03-091-0/+1
| | | | llvm-svn: 262984
* [index] Distinguish USRs of anonymous enums by using their first enumerator.Argyrios Kyrtzidis2016-03-041-4/+0
| | | | | | rdar://24609949. llvm-svn: 262695
* [index] Ignore ObjCTypeParamDecls during indexing.Argyrios Kyrtzidis2016-03-041-0/+3
| | | | llvm-svn: 262686
* [index] Print and test module import references.Argyrios Kyrtzidis2016-02-291-2/+7
| | | | llvm-svn: 262208
* silence -Wreturn-type warningsSaleem Abdulrasool2016-02-151-0/+1
| | | | | | | | These codepaths would generate warnings with GCC on linux even though the switch was covered. Add llvm_unreachable markers to indicate that the switch should be covered. NFC. llvm-svn: 260865
* [libclang] Separate the underlying indexing functionality of libclang and ↵Argyrios Kyrtzidis2016-02-121-0/+325
introduce it into the clangIndex library. It is a general goodness for libclang itself to mostly be a wrapper of functionality provided by the libraries. llvm-svn: 260760
OpenPOWER on IntegriCloud