summaryrefslogtreecommitdiffstats
path: root/clang/lib/Index
Commit message (Collapse)AuthorAgeFilesLines
* Comment parsing: remove HTML attribute validationDmitri Gribenko2014-04-301-4/+4
| | | | | | | | | | | | Since the community says that a blacklist is not good enough, and I don't have enough time now to implement a proper whitelist, let's just remove the attribute validation. But, nevertheless, we can still communicate in the generated XML if our parser found an issue with the HTML. But this bit is best-effort and is specifically called out in the schema as such. llvm-svn: 207712
* CommentToXMLConverter: Don't use "default" to method(s). It is unavailable ↵NAKAMURA Takumi2014-04-241-1/+1
| | | | | | in msc17. llvm-svn: 207107
* Comment to XML conversion: use unique_ptr for SimpleFormatContextDmitri Gribenko2014-04-241-10/+6
| | | | llvm-svn: 207087
* Fix two leaks found by LSan (one is test-only).Nico Weber2014-04-241-1/+1
| | | | | | | The result of llvm::MemoryBuffer::getMemBuffer() needs to be freed. Don't pass "don't free" flag to overrideFileContents() to fix. llvm-svn: 207075
* Fix leak introduced in r194610, found by LSan.Nico Weber2014-04-231-0/+4
| | | | | | | | | | LSan folks: LSan pointed to #0 0x4953e0 in operator new[](unsigned long) llvm/projects/compiler-rt/lib/asan/asan_new_delete.cc:64 #1 0x7fb82af5372f in clang::RewriteRope::MakeRopeString(char const*, char const*) llvm/tools/clang/lib/Rewrite/Core/RewriteRope.cpp:796 instead of to the actual leak, which made tracking this down slower than it could have been. llvm-svn: 207031
* Comment parsing: close a hole in CDATA escaping in XML outputDmitri Gribenko2014-04-221-3/+33
| | | | llvm-svn: 206886
* Comment parsing: in the generated XML file, mark HTML that is safe to passDmitri Gribenko2014-04-221-2/+8
| | | | | | | | | | | through to the output even if the input comment comes from an untrusted source Attribute filtering is currently based on a blacklist, which right now includes all event handler attributes (they contain JavaScipt code). It should be switched to a whitelist, but going over all of the HTML5 spec requires a significant amount of time. llvm-svn: 206882
* libclang/libIndex: USR generation: mangle source location into USRs for macros,Dmitri Gribenko2014-03-281-24/+53
| | | | | | unless the macro comes from a system header llvm-svn: 205064
* remove a bunch of unused private methodsNuno Lopes2014-03-231-10/+0
| | | | | | | | | | | | | | | | | | found with a smarter version of -Wunused-member-function that I'm playwing with. Appologies in advance if I removed someone's WIP code. ARCMigrate/TransProperties.cpp | 8 ----- AST/MicrosoftMangle.cpp | 1 Analysis/AnalysisDeclContext.cpp | 5 --- Analysis/LiveVariables.cpp | 14 ---------- Index/USRGeneration.cpp | 10 ------- Sema/Sema.cpp | 33 +++++++++++++++++++++--- Sema/SemaChecking.cpp | 3 -- Sema/SemaDecl.cpp | 20 ++------------ StaticAnalyzer/Checkers/GenericTaintChecker.cpp | 1 9 files changed, 34 insertions(+), 61 deletions(-) llvm-svn: 204561
* [C++11] Replacing FunctionProtoType iterators param_type_begin() and ↵Aaron Ballman2014-03-171-5/+2
| | | | | | param_type_end() with iterator_range param_types(). Updating all of the usages of the iterators with range-based for loops. llvm-svn: 204045
* [C++11] Replacing FunctionDecl iterators param_begin() and param_end() with ↵Aaron Ballman2014-03-071-5/+2
| | | | | | iterator_range params(). Updating all of the usages of the iterators with range-based for loops. llvm-svn: 203248
* [CMake] Use LINK_LIBS instead of target_link_libraries().NAKAMURA Takumi2014-02-261-2/+1
| | | | llvm-svn: 202238
* [Index] Make the USRs more stable.Argyrios Kyrtzidis2014-02-231-17/+30
| | | | | | | | | - Only include offsets with local (in function scope) symbols, where we don't encode scoping - Only include the filename with non-system symbols. Presumably the system headers will not provide conflicting definitions. rdar://15976823 llvm-svn: 201990
* Rename getResultType() on function and method declarations to getReturnType()Alp Toker2014-01-251-1/+1
| | | | | | | | | | | | | | | A return type is the declared or deduced part of the function type specified in the declaration. A result type is the (potentially adjusted) type of the value of an expression that calls the function. Rule of thumb: * Declarations have return types and parameters. * Expressions have result types and arguments. llvm-svn: 200082
* Rename FunctionProtoType accessors from 'arguments' to 'parameters'Alp Toker2014-01-201-2/+3
| | | | | | | | | | | | | | | | | Fix a perennial source of confusion in the clang type system: Declarations and function prototypes have parameters to which arguments are supplied, so calling these 'arguments' was a stretch even in C mode, let alone C++ where default arguments, templates and overloading make the distinction important to get right. Readability win across the board, especially in the casting, ADL and overloading implementations which make a lot more sense at a glance now. Will keep an eye on the builders and update dependent projects shortly. No functional change. llvm-svn: 199686
* [CMake] Apply ADDITIONAL_HEADERS introduced in r199639.NAKAMURA Takumi2014-01-201-1/+3
| | | | llvm-svn: 199640
* Sort all the #include lines with LLVM's utils/sort_includes.py whichChandler Carruth2014-01-071-1/+1
| | | | | | | encodes the canonical rules for LLVM's style. I noticed this had drifted quite a bit when cleaning up LLVM, so wanted to clean up Clang as well. llvm-svn: 198686
* [CMake] clang/lib: Satisfy dependencies to add *actually used* libraries on ↵NAKAMURA Takumi2013-12-091-1/+8
| | | | | | | | target_link_libraries() and LLVM_LINK_COMPONENTS. I will prune redundant dependencies later. llvm-svn: 196800
* libclang does not depend directly on clangFormat; but clangIndex doesDmitri Gribenko2013-11-131-0/+1
| | | | llvm-svn: 194611
* Documentation parsing: move comment-to-XML conversion routines to libIndexDmitri Gribenko2013-11-133-0/+1215
| | | | llvm-svn: 194610
* Avoid using the 'index' namespace as scope.Argyrios Kyrtzidis2013-08-211-16/+19
| | | | | | This should fix the bogus ambiguous reference errors reported by gcc 4.2.1 that the FreeBSD bot is using. llvm-svn: 188850
* Rename libIDE to libIndex.Argyrios Kyrtzidis2013-08-173-0/+821
| | | | | | | Per feedback from Chandler, it's better to have libraries with more specific functionality. LibIndex will contain the indexing functionality of libclang, which includes USR generation. llvm-svn: 188601
* Remove the unused, unmaintained, incomplete 'Index' library.Douglas Gregor2012-04-1316-1770/+0
| | | | llvm-svn: 154672
* Unify naming of LangOptions variable/get function across the Clang stack ↵David Blaikie2012-03-111-1/+1
| | | | | | | | | | (Lex to AST). The member variable is always "LangOpts" and the member function is always "getLangOpts". Reviewed by Chris Lattner llvm-svn: 152536
* Unbreak the CMake builds following the CallGraph change.Anna Zaks2012-03-021-1/+1
| | | | llvm-svn: 151952
* [analyzer] Rename clang::CallGraph into clang::idx::CallGraph + renameAnna Zaks2012-03-021-4/+6
| | | | | | | | | | | | | 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.) llvm-svn: 151950
* More dead code removal (using -Wunreachable-code)David Blaikie2012-01-201-4/+4
| | | | llvm-svn: 148577
* Remove unnecessary default cases in switches over enums.David Blaikie2012-01-171-2/+0
| | | | | | This allows -Wswitch-enum to find switches that need updating when these enums are modified. llvm-svn: 148281
* Replace all comparisons between ObjCInterfaceDecl pointers with callsDouglas Gregor2011-12-151-2/+2
| | | | | | | | to declaresSameEntity(), as a baby step toward tracking forward declarations of Objective-C classes precisely. Part of <rdar://problem/10583531>. llvm-svn: 146618
* Change operator<< for raw_ostream and NamedDecl to take a reference instead ↵Benjamin Kramer2011-10-141-2/+2
| | | | | | | | of a pointer. Passing a pointer was a bad idea as it collides with the overload for void*. llvm-svn: 141971
* Removing a bunch of dead returns/breaks after llvm_unreachables.David Blaikie2011-09-231-1/+0
| | | | llvm-svn: 140407
* Switch assert(0/false) llvm_unreachable.David Blaikie2011-09-231-2/+2
| | | | llvm-svn: 140367
* remove unneeded llvm:: namespace qualifiers on some core types now that ↵Chris Lattner2011-07-234-8/+8
| | | | | | | | LLVM.h imports them into the clang namespace. llvm-svn: 135852
* now that we have a centralized place to do so, add some using declarations forChris Lattner2011-07-201-1/+1
| | | | | | | some common llvm types: stringref and smallvector. This cleans up the codebase quite a bit. llvm-svn: 135576
* Modify some deleted function methods to better reflect reality:Alexis Hunt2011-05-062-2/+2
| | | | | | | | | | | | | | | | | | | | - New isDefined() function checks for deletedness - isThisDeclarationADefinition checks for deletedness - New doesThisDeclarationHaveABody() does what isThisDeclarationADefinition() used to do - The IsDeleted bit is not propagated across redeclarations - isDeleted() now checks the canoncial declaration - New isDeletedAsWritten() does what it says on the tin. - isUserProvided() now correct (thanks Richard!) This fixes the bug that we weren't catching void foo() = delete; void foo() {} as being a redefinition. llvm-svn: 131013
* Support for C++11 (non-template) alias declarations.Richard Smith2011-04-151-1/+1
| | | | llvm-svn: 129567
* fix a bunch of comment typos found by codespell. Patch byChris Lattner2011-04-151-1/+1
| | | | | | Luis Felipe Strano Moraes! llvm-svn: 129559
* Give some convenient idiomatic accessors to Stmt::child_range andJohn McCall2011-02-132-3/+2
| | | | | | | Stmt::const_child_range, then make a bunch of places use them instead of the individual iterator accessors. llvm-svn: 125450
* CMake: LLVM_NO_RTTI must be obsolete now!NAKAMURA Takumi2011-02-101-2/+0
| | | | llvm-svn: 125275
* Fix CMake clangIndex library dependencies, from Logan ChienDouglas Gregor2010-09-201-15/+1
| | | | llvm-svn: 114336
* Revert "CMake: Update to use standard CMake dependency tracking facilities ↵Michael J. Spencer2010-09-131-19/+17
| | | | | | | | | | | | | instead" This reverts commit r113631 Conflicts: CMakeLists.txt lib/CodeGen/CMakeLists.txt llvm-svn: 113817
* CMake: Update to use standard CMake dependency tracking facilities insteadMichael J. Spencer2010-09-101-17/+19
| | | | | | of whatever we were using before... llvm-svn: 113631
* Clean up CMake dependenciesDouglas Gregor2010-09-091-0/+5
| | | | llvm-svn: 113489
* Clean up some of the CMake dependenciesDouglas Gregor2010-09-081-0/+14
| | | | llvm-svn: 113416
* De-memberify the VarDecl and FunctionDecl StorageClass enums.John McCall2010-08-261-2/+2
| | | | | | This lets us remove Sema.h's dependency on Expr.h and Decl.h. llvm-svn: 112156
* Remove unused location-to-AST-node resolver. libclang's implementation ↵Douglas Gregor2010-07-192-603/+0
| | | | | | supercedes it llvm-svn: 108708
* BUILD_ARCHIVE is the default for libraries, no need to set it.Chris Lattner2010-07-181-1/+0
| | | | llvm-svn: 108633
* Collect function definitions in the Indexer when indexing through the ASTs.Zhongxing Xu2010-07-063-17/+64
| | | | | | Add an API to get an Entity associated with a name in the global namespace. llvm-svn: 107642
* Local variables have no linkage, make invalid Entities.Zhongxing Xu2010-07-061-0/+4
| | | | llvm-svn: 107630
* Refrase comments.Zhongxing Xu2010-07-051-3/+3
| | | | llvm-svn: 107607
OpenPOWER on IntegriCloud