summaryrefslogtreecommitdiffstats
path: root/clang/tools/libclang
Commit message (Collapse)AuthorAgeFilesLines
...
* Parsing/Sema for OMPCollapseClause.Alexander Musman2014-05-271-0/+4
| | | | | | Actual usage in Sema for collapsing loops will in some future patch. llvm-svn: 209660
* RAV reunification: merge Lambda body visitation to DRAVAlp Toker2014-05-201-5/+5
| | | | llvm-svn: 209246
* VirtualFileSystem: Add YAMLVFSWriter to generate VFS mapping filesJustin Bogner2014-05-201-141/+9
| | | | | | | | | This moves the logic to write a JSON VFS mapping from the C api into VirtualFileSystem, so that we can use it internally. No functional change. llvm-svn: 209241
* Provide and use a safe Token::getRawIdentifier() accessorAlp Toker2014-05-171-6/+4
| | | | llvm-svn: 209061
* Switch another write_escaped to yaml::escapeBen Langmuir2014-05-161-2/+2
| | | | | | I missed one in r206443. llvm-svn: 208941
* [libclang] Introduce clang_Module_isSystem(), which returns non-zero if the ↵Argyrios Kyrtzidis2014-05-152-0/+8
| | | | | | given CXModule is a system one. llvm-svn: 208846
* [liblang] Introduce clang_getModuleForFile, which given a CXFile header ↵Argyrios Kyrtzidis2014-05-142-0/+21
| | | | | | file, returns the module that contains it, if one exists. llvm-svn: 208822
* Decouple ExprCXX.h and DeclCXX.h and clean up includes a bit.Benjamin Kramer2014-05-101-1/+1
| | | | | | | Required pulling LambdaExpr::Capture into its own header. No functionality change. llvm-svn: 208470
* Don't leak the CXStoredDiagnostics returned by clang_codeCompleteGetDiagnostic()Nico Weber2014-05-091-2/+12
| | | | | | | | | | | | | | | | | r144269 changed clang_disposeDiagnostic() to be a no-op, but didn't update code completion diagnostics. Let CXCodeCompleteResults store all diagnostics returned by clang_codeCompleteGetDiagnostic() and then free them up in clang_disposeCodeCompleteResults(). Code completion diagnostics referred to data stored in CXCodeCompleteResults before already, so it wasn't possible to refer to the results of clang_codeCompleteGetDiagnostic() after clang_disposeCodeCompleteResults() before this change already -- hence this should be a safe, backwards-compatible change. Leak found by LSan, fixes PR19690. llvm-svn: 208454
* [OPENMP] 'proc_bind' clause support - Parsing and sema analysis for OpenMP ↵Alexey Bataev2014-05-061-0/+2
| | | | | | clause 'proc_bind' llvm-svn: 208060
* [libclang] Add attribute support for 'pure', 'const' and 'noduplicate'.Joey Gouly2014-05-012-0/+9
| | | | | | This bumps CINDEX_VERSION_MINOR up (to 26). llvm-svn: 207767
* libclang: split out the documentation comment APIAlp Toker2014-04-283-12/+15
| | | | | | | | | | | | | | | | | It's possible that the "comment AST" may be replaced or split out in the midterm, any anyway this makes the headers easier to read. Developers don't currently need to include "clang-c/Documentation.h" explicitly and there's no macro to test for availability yet. The raw comment and brief comment accessors have been kept in Index.h though brief support may also move here as a separate proposal. This is not a deprecation, just a gentle separation of concerns as we look to simplify the built-in representation of comment nodes and support external comment processors. llvm-svn: 207392
* libclang: remove 'CXDiagnostic_Remark'Alp Toker2014-04-263-3/+4
| | | | | | | | | | | | | | | | The change was landed without review or test cases. It trivially broke almost any stable application checking for Severity >= CXDiagnostic_Error or indeed any other kind of severity comparison upon encountering a 'remark'. Mapped to CXDiagnostic_Warning until a workable solution is proposed to the list that preserves API stability. (It's also not clear why the rest of r202475 wasn't simply implemented as a modifier to the existing 'warning' level.) llvm-svn: 207319
* Simplify leak fix of r207076, by just disposing the previous CXString.Argyrios Kyrtzidis2014-04-241-9/+2
| | | | llvm-svn: 207081
* Fix two leaks found by LSan.Nico Weber2014-04-241-1/+11
| | | | | | | | A CursorPlatformAvailability can have several "unavailable" attributes, don't leak all but the first. I'm not sure if there can be several "deprecate"ds too, but add the same logic there to keep the two code paths looking the same. llvm-svn: 207076
* Attempt to fix null ASTContext in ASTUnit error pathBen Langmuir2014-04-221-1/+1
| | | | | | | | | We don't need the ASTContext for the diagnostics, only the language options, which we can get from the compiler invocation. It worries me how many categorically different states the ASTUnit class can be in depending on how it is being constructed/used. llvm-svn: 206909
* [OPENMP] parsing 'linear' clause (for directive 'omp simd')Alexander Musman2014-04-221-0/+4
| | | | | | Differential Revision: http://reviews.llvm.org/D3272 llvm-svn: 206891
* When writing YAML in libclang, use yaml::escape instead of write_escapedBen Langmuir2014-04-171-4/+4
| | | | | | | | The YAMLParser has its own escaped string representation, and does not handle octal escape sequences. When writing the virtual file system to a YAML file, use yaml::escape(). llvm-svn: 206443
* Honour -ivfsoverlay in ASTUnit to match clangBen Langmuir2014-04-152-19/+17
| | | | | | | This allows code indexing, etc. to use the VFS in the same way as the compiler. llvm-svn: 206309
* libclang: add clang_CXXMethod_isConst API that allows to determine if a C++Dmitri Gribenko2014-04-072-0/+11
| | | | | | | | member function or member function template is declared 'const' Patch by Kevin Funk with testcase updates by me. llvm-svn: 205714
* [OPENMP] Implemented 'copyin' clauseAlexey Bataev2014-03-311-0/+3
| | | | llvm-svn: 205164
* libclang/libIndex: USR generation: mangle source location into USRs for macros,Dmitri Gribenko2014-03-281-4/+12
| | | | | | unless the macro comes from a system header llvm-svn: 205064
* [cleanup] Stop specifying size overrides for BumpPtrAllocators.Chandler Carruth2014-03-271-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | These don't seem to have any real point. Let's start with IndexingContext. I can't come up with any conceivable reason to have many hundereds of thousands of these alive in an address space which would make the 4x difference in allocated (but unused) memory for the string scratch buffer a significant memory usage problem. The EditedSource one is somewhat more surprising. This is an 8x increase in the memory allocated (but not used) per editted source file. However, for this to realistically be a problem, you would need to have over half a million editted source files in a single address space, and even that would only really have problems on 32-bit Windows where you really only have 2gb of virtual address space. And what's more important, the fix to this if it is actually an issue shouldn't be to shrink the allocator's size, it is to pass a single allocator into *many* edited source file objects and let them share the memory. These were the only two uses of custom sized BumpPtrAllocators (excluding ones in the JIT using a custom allocation strategy) in all of LLVM, Clang, LLD, LLDB, or Polly. I don't think we actually need this complexity in the primary BumpPtrAllocator at all and am planning to remove it. llvm-svn: 204910
* [OPENMP] parsing of clause 'safelen' (for directive 'omp simd')Alexey Bataev2014-03-211-0/+4
| | | | llvm-svn: 204428
* Tooling: Move heavyweight vectors around instead of copying.Benjamin Kramer2014-03-201-8/+6
| | | | | | While there convert to range-based for loops. No functionality change. llvm-svn: 204338
* [libclang] Introduce clang_VirtualFileOverlay_setCaseSensitivity that ↵Argyrios Kyrtzidis2014-03-202-4/+27
| | | | | | | | | | exposes the VFS option to set the case-sensitivity for lookups. rdar://16374696 llvm-svn: 204303
* [C++11] Add 'override' keyword to virtual methods that override their base ↵Craig Topper2014-03-155-124/+119
| | | | | | class. llvm-svn: 204002
* [C++11] Replacing DeclStmt iterators decl_begin() and decl_end() with ↵Aaron Ballman2014-03-141-3/+2
| | | | | | iterator_range decls(). Updating all of the usages of the iterators with range-based for loops. llvm-svn: 203947
* [C++11] Replacing OMPThreadPrivateDecl and OMPClause iterators ↵Aaron Ballman2014-03-141-4/+2
| | | | | | varlist_begin() and varlist_end() with iterator_range varlists(). Updating all of the usages of the iterators with range-based for loops. llvm-svn: 203937
* [C++11] Replacing ObjCImplementationDecl iterators ivar_begin() and ↵Aaron Ballman2014-03-141-5/+2
| | | | | | ivar_end() with iterator_range ivars(). Updating all of the usages of the iterators with range-based for loops. llvm-svn: 203932
* [C++11] Replacing UsingDecl iterators shadow_begin() and shadow_end() with ↵Aaron Ballman2014-03-131-5/+3
| | | | | | iterator_range shadows(). Updating all of the usages of the iterators with range-based for loops. llvm-svn: 203825
* [C++11] Replacing CXXRecordDecl iterators init_begin() and init_end() with ↵Aaron Ballman2014-03-132-9/+4
| | | | | | iterator_range inits(). Updating all of the usages of the iterators with range-based for loops. llvm-svn: 203819
* [C++11] Replacing CXXRecordDecl iterators bases_begin() and bases_end() with ↵Aaron Ballman2014-03-132-6/+3
| | | | | | iterator_range bases(). Updating all of the usages of the iterators with range-based for loops. llvm-svn: 203803
* Use vector<T>::data() to simplify codeDmitri Gribenko2014-03-121-3/+1
| | | | llvm-svn: 203665
* [C++11] Replacing Decl iterators attr_begin() and attr_end() with ↵Aaron Ballman2014-03-082-11/+7
| | | | | | | | iterator_range attrs(). Updating all of the usages of the iterators with range-based for loops. This is a reapplication of r203236 with modifications to the definition of attrs() and following the new style guidelines on auto usage. llvm-svn: 203362
* [C++11] Replacing RecordDecl iterators field_begin() and field_end() with ↵Aaron Ballman2014-03-081-4/+3
| | | | | | iterator_range fields(). Updating all of the usages of the iterators with range-based for loops. llvm-svn: 203355
* [C++11] Revert uses of lambdas with array_pod_sort.Benjamin Kramer2014-03-071-6/+9
| | | | | | Looks like GCC implements the lambda->function pointer conversion differently. llvm-svn: 203293
* [C++11] Convert sort predicates into lambdas.Benjamin Kramer2014-03-071-9/+6
| | | | | | No functionality change. llvm-svn: 203289
* Replace OwningPtr with std::unique_ptr.Ahmed Charles2014-03-074-45/+38
| | | | | | This compiles cleanly with lldb/lld/clang-tools-extra/llvm. llvm-svn: 203279
* [C++11] Replacing DeclBase iterators decls_begin() and decls_end() with ↵Aaron Ballman2014-03-072-14/+9
| | | | | | iterator_range decls(). The same is true for the noload versions of these APIs. Updating all of the usages of the iterators with range-based for loops. llvm-svn: 203278
* Change OwningPtr::take() to OwningPtr::release().Ahmed Charles2014-03-073-8/+8
| | | | | | This is a precursor to moving to std::unique_ptr. llvm-svn: 203275
* [C++11] Replacing ObjCMethodDecl iterators param_begin() and param_end() ↵Aaron Ballman2014-03-072-12/+6
| | | | | | with iterator_range params(). Updating all of the usages of the iterators with range-based for loops. llvm-svn: 203255
* [C++11] Replacing FunctionDecl iterators param_begin() and param_end() with ↵Aaron Ballman2014-03-071-4/+2
| | | | | | iterator_range params(). Updating all of the usages of the iterators with range-based for loops. llvm-svn: 203248
* Fully reverting r203236 -- it seems the only bots that are happy are the ↵Aaron Ballman2014-03-072-7/+11
| | | | | | MSVC bots. llvm-svn: 203237
* [C++11] Replacing iterators attr_begin() and attr_end() with iterator_range ↵Aaron Ballman2014-03-072-11/+7
| | | | | | attrs(). Updating all of the usages of the iterators with range-based for loops. llvm-svn: 203236
* [OPENMP] Clause 'num_threads'Alexey Bataev2014-03-061-0/+4
| | | | llvm-svn: 203087
* Fix -Wsign-compare warning.Jordan Rose2014-03-041-2/+3
| | | | | | No functionality change. llvm-svn: 202864
* [cleanup] Re-sort includes with llvm/utils/sort_includes.py and fixChandler Carruth2014-03-043-2/+3
| | | | | | | | | | | | a missing include from CLog.h. CLog.h referenced most of the core libclang types but never directly included Index.h that provides them. Previously it got lucky and other headers were always included first but with the sorting it ended up first in one case and stopped compiling. Adding the Index.h include fixes it right up. llvm-svn: 202810
* [libclang] Have clang_getCursorSpelling() return the string for a ↵Argyrios Kyrtzidis2014-03-031-0/+16
| | | | | | | | CXCursor_ObjCStringLiteral or CXCursor_StringLiteral cursor. rdar://16206459 llvm-svn: 202745
* Serialized diagnostic severity levels should be stable.Jordan Rose2014-03-031-8/+14
| | | | | | | | | Serialized diagnostics were accidentally using the AST diagnostic level values rather than a dedicated stable enum, so the addition of "remark" broke the reading of existing serialized diagnostics files. I've added a .dia file generated from Xcode 5's Clang to make sure we don't break this in the future. llvm-svn: 202733
OpenPOWER on IntegriCloud