summaryrefslogtreecommitdiffstats
path: root/clang/bindings
Commit message (Collapse)AuthorAgeFilesLines
...
* Python bindings: Add missing availability kind.Benjamin Kramer2012-10-072-9/+50
| | | | | | Patch by Leo Liu, test case by me. llvm-svn: 165374
* Comment to XML conversion: escape XML special chars correctly; use correctDmitri Gribenko2012-10-031-47/+53
| | | | | | regex for version tuples. llvm-svn: 165104
* [Doc parse]: SUpport for message in deprecated/unavailableFariborz Jahanian2012-10-021-2/+6
| | | | | | attribute going iinto XML document. llvm-svn: 165066
* [Doc parsing]: Add available and deprecated attribute infoFariborz Jahanian2012-10-021-3/+19
| | | | | | to XML output. // rdar://12378879 llvm-svn: 165039
* availability in structured documents. TakesFariborz Jahanian2012-10-011-2/+2
| | | | | | care of comments by Dimitri and Doug. llvm-svn: 164957
* Comment XML schema: correct indentation.Dmitri Gribenko2012-09-291-2/+2
| | | | llvm-svn: 164889
* [Doc parsing] Add availability information to generated Comment XML.Fariborz Jahanian2012-09-281-0/+36
| | | | | | | (I still need to add a test once I figure it out). Reviewed off-line by Doug. // rdar://12378879 llvm-svn: 164861
* Fix cindex.py compatibility with older libclang.soDmitri Gribenko2012-09-221-1/+10
| | | | | | | The issue is that we were calling clang_getCompletionBriefComment unconditionally. New we check if this function is available before calling it. llvm-svn: 164464
* Add bindings for clang_getCompletionBriefComment to cindex.py.Dmitri Gribenko2012-09-152-2/+63
| | | | llvm-svn: 163966
* Comment to XML conversion: we try not to emit empty <Discussion> elements, butDmitri Gribenko2012-09-131-2/+2
| | | | | | | it is not possible to guarantee that without duplicating logic or buffering <Discussion> element contents. So, allow empty <Discussion> elements in schema. llvm-svn: 163842
* [cindex.py] Make the use of a compatibilty check explicitTobias Grosser2012-09-051-4/+31
| | | | | | | | | | | | | | | | At the moment, we implictly check compatibility between the python bindings and libclang, as the python bindings will fail to load in case a method we use in libclang is not available. This patch makes the use of this compatibility check explicit and introduces a flag to optionally disable the check. This will allow us to further harden the compatibility check, but it also gives the user the possibility to disable the compatibility check to evaluate compatibility with older libclang versions. I added documentation that makes clear the python bindings are only tested with the libclang version they have been shipped with. llvm-svn: 163238
* [cindex.py] Allow to configure the path of libclangTobias Grosser2012-09-031-134/+189
| | | | | | | | | | | By calling cindex.Config.set_library_path(path) or cindex.Config.set_library_file(file) it is possible to specify from where we load libclang. This fixes an open FIXME. We also point the user to these functions, in case libclang can not be loaded sucessfully. llvm-svn: 163121
* [cindex.py] Add helper to initialize libclang functionsTobias Grosser2012-09-011-385/+533
| | | | | | | | | | | | | | | | The helper allows us to define how the initialization of functions should behave. We use this patch to provide an informative error message, in case a function is not available: "LibclangError: /home/grosser/Projekte/llvm/install/lib/libclang.so: undefined symbol: clang_method_added_in_2020. Please ensure that your python bindings are compatible with your libclang.so version." This patch also ensures that no spelling mistakes slip into the library initialization. At the moment, there are a couple of 'argtype' -> 'argtypes' mispellings that have been overlooked. llvm-svn: 163057
* [cindex.py] Cache the number of chunks in CompletionStringTobias Grosser2012-08-201-1/+5
| | | | | | | | Without this patch, lib.clang_getNumCompletionChunks is called at each _iteration_ of a 'for chunk in CompletionString' loop. Now we call it just once. llvm-svn: 162200
* [cindex.py] Add CachedProperty to CompletionChunkTobias Grosser2012-08-191-3/+3
| | | | | | Suggested by: Francisco Lopes <oblita@gmail.com> llvm-svn: 162191
* [clang.py] Add CachedProperty decoratorGregory Szorc2012-08-191-0/+25
| | | | | | It isn't used anywhere yet. llvm-svn: 162190
* [cindex.py] Use spaces, not tabs for indentationTobias Grosser2012-08-181-1/+1
| | | | | | Reported by: Francisco Lopes <oblita@gmail.com> llvm-svn: 162182
* [cindex.py] Dispose code completion results properlyTobias Grosser2012-08-181-1/+1
| | | | llvm-svn: 162181
* Comment XML: use xml:space="preserve" in Verbatim tags, so that XML tidy doesDmitri Gribenko2012-08-081-0/+3
| | | | | | not compress spaces in verbatim content. llvm-svn: 161531
* Comment AST: DeclInfo: add a special kind for enums.Dmitri Gribenko2012-08-071-0/+31
| | | | | | Comment XML: add a root node kind for enums. llvm-svn: 161442
* libclang API for comment-to-xml conversion.Dmitri Gribenko2012-08-071-0/+400
| | | | | | | | | | | | The implementation also includes a Relax NG schema and tests for the schema itself. The schema is used in c-index-test to verify that XML documents we produce are valid. In order to do the validation, we add an optional libxml2 dependency for c-index-test. Credits for CMake part go to Doug Gregor. Credits for Autoconf part go to Eric Christopher. Thanks! llvm-svn: 161431
* [clang.py] Implement Token APIGregory Szorc2012-07-126-16/+345
| | | | llvm-svn: 160111
* [clang.py] Add TranslationUnit.get_{file,source_location,source_range}Gregory Szorc2012-07-122-0/+127
| | | | llvm-svn: 160107
* [clang.py] Refactor how ctypes functions are registeredGregory Szorc2012-07-121-589/+569
| | | | llvm-svn: 160106
* [cindex.py] Make CompileCommand.arguments usage consistent with ↵Arnaud A. de Grandmaison2012-07-102-3/+5
| | | | | | | | CompileCommand.directory and the rest of the python binding Patch by David Röthlisberger llvm-svn: 159970
* [cindex.py] fix infinite iteration of compilation database CompileCommandsArnaud A. de Grandmaison2012-07-092-1/+9
| | | | | | Patch by David Röthlisberger llvm-svn: 159926
* [cindex.py] Fix erroneous comment for CompileCommandsArnaud A. de Grandmaison2012-07-061-3/+1
| | | | llvm-svn: 159810
* [libclang] CompilationDatabase naming and comment fixesArnaud A. de Grandmaison2012-07-031-9/+9
| | | | llvm-svn: 159682
* [cindex.py] Fix commentsArnaud A. de Grandmaison2012-06-302-2/+2
| | | | llvm-svn: 159492
* [cindex.py] add CompilationDatabase supportArnaud A. de Grandmaison2012-06-303-0/+251
| | | | llvm-svn: 159485
* [clang.py] Implement SourceLocation.from_offsetGregory Szorc2012-06-112-0/+23
| | | | llvm-svn: 158307
* [clang.py] Implement Cursor.is_static_methodGregory Szorc2012-06-092-0/+26
| | | | llvm-svn: 158277
* Fix typo "CursorKind.CONDITONAL_OPERATOR" in Python bindings, fromDouglas Gregor2012-06-081-1/+1
| | | | | | Manish Verma! llvm-svn: 158182
* [clang.py] Store reference to TranslationUnit in Cursor and TypeGregory Szorc2012-05-153-1/+96
| | | | llvm-svn: 156846
* [clang.py] Implement Cursor.canonicalGregory Szorc2012-05-142-0/+31
| | | | llvm-svn: 156753
* [clang.py] Implement Cursor.result_typeGregory Szorc2012-05-142-0/+16
| | | | llvm-svn: 156752
* [clang.py] Followup to TranslationUnit refactorGregory Szorc2012-05-121-2/+5
| | | | | | | | | * Document index argument in TranslationUnit.from_source * Add numeric error code to TranslationUnitSaveError string representation * Use None instead of [] for default argument value in TranslationUnit.codeComplete llvm-svn: 156722
* [clang.py] Remove trailing whitespace from recent commitsGregory Szorc2012-05-082-6/+6
| | | | llvm-svn: 156373
* [clang.py] TranslationUnit API improvementsGregory Szorc2012-05-083-63/+325
| | | | | | | | | | | | | | | | | * TranslationUnit reading and parsing now implemented as TranslationUnit.from_ast() and TranslationUnit.from_source(). * Index.parse() and Index.read() implemented through above. * Index.parse() and Index.read() now raise a TanslationUnitLoadException instead of returning None if a TranslationUnit could not be instantiated. This is backwards incompatible. * Ability to save TranslationUnits via TranslationUnit.save(). * TranslationUnit now holds onto Index instance that created. This means the Index can't be GC'd until the TranslationUnit is itself GC'd, making memory management thoughtless. * Don't use [] as a default argument value, as the initial value used is reused for the duration of the program. llvm-svn: 156372
* - Adding lexical_parent and semantic_parent properties to clang.cindex.CursorManuel Klimek2012-05-073-0/+80
| | | | | | | | | - Two new tests (one for each property), require libclang built from r155858 or later to pass - New test utility function (get_cursors) that gets all the nodes with a specific spelling. Patch by Evan Pipho. llvm-svn: 156286
* [python] Add testcase for annotation cursorAnders Waldenborg2012-05-021-0/+12
| | | | llvm-svn: 156022
* [python] Add Cursor.enum_value wrapping clang_getEnumConstantDeclValueAnders Waldenborg2012-05-022-0/+69
| | | | llvm-svn: 156017
* [python] Add testcase for enum with specified underlaying typeAnders Waldenborg2012-05-021-0/+8
| | | | llvm-svn: 156009
* [python] Run tests for c++ with std=c++11Anders Waldenborg2012-05-021-2/+3
| | | | llvm-svn: 156008
* [python] Fix warning in c-code inside testcaseAnders Waldenborg2012-05-021-1/+1
| | | | llvm-svn: 156007
* [clang.py] Implement TypeKind.spellingGregory Szorc2012-04-152-1/+17
| | | | llvm-svn: 154769
* [clang.py] Implement Cursor.objc_type_encodingGregory Szorc2012-03-102-0/+20
| | | | llvm-svn: 152513
* [clang.py] Refactor get_tu and get_cursor test helper functions into util.pyGregory Szorc2012-03-105-112/+130
| | | | llvm-svn: 152510
* [clang.py] Return bool from Cursor.__eq__Gregory Szorc2012-03-051-2/+2
| | | | llvm-svn: 152011
* [clang.py] Test Cursor.__ne__Gregory Szorc2012-02-261-0/+1
| | | | llvm-svn: 151504
OpenPOWER on IntegriCloud