summaryrefslogtreecommitdiffstats
path: root/bindings
Commit message (Collapse)AuthorAgeFilesLines
* [clang.py] Implement TypeKind.spellingGregory Szorc2012-04-152-1/+17
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@154769 91177308-0d34-0410-b5e6-96231b3b80d8
* [clang.py] Implement Cursor.objc_type_encodingGregory Szorc2012-03-102-0/+20
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@152513 91177308-0d34-0410-b5e6-96231b3b80d8
* [clang.py] Refactor get_tu and get_cursor test helper functions into util.pyGregory Szorc2012-03-105-112/+130
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@152510 91177308-0d34-0410-b5e6-96231b3b80d8
* [clang.py] Return bool from Cursor.__eq__Gregory Szorc2012-03-051-2/+2
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@152011 91177308-0d34-0410-b5e6-96231b3b80d8
* [clang.py] Test Cursor.__ne__Gregory Szorc2012-02-261-0/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@151504 91177308-0d34-0410-b5e6-96231b3b80d8
* [clang.py] Format and add documention for TypeGregory Szorc2012-02-202-11/+14
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@150972 91177308-0d34-0410-b5e6-96231b3b80d8
* [clang.py] Add tests for Type.is_volatile_qualified and ↵Gregory Szorc2012-02-201-2/+45
| | | | | | Type.is_restrict_qualified git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@150971 91177308-0d34-0410-b5e6-96231b3b80d8
* [clang.py] Implement Type.argument_types()Gregory Szorc2012-02-202-107/+183
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@150970 91177308-0d34-0410-b5e6-96231b3b80d8
* [clang.py] Implement Type.__eq__ and Type.__ne__Gregory Szorc2012-02-202-0/+38
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@150969 91177308-0d34-0410-b5e6-96231b3b80d8
* [clang.py] Implement Type.is_function_variadicGregory Szorc2012-02-192-18/+55
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@150936 91177308-0d34-0410-b5e6-96231b3b80d8
* [clang.py] Implement Type.element_countGregory Szorc2012-02-172-0/+40
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@150800 91177308-0d34-0410-b5e6-96231b3b80d8
* [clang.py] Implement Type.element_typeGregory Szorc2012-02-172-1/+51
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@150799 91177308-0d34-0410-b5e6-96231b3b80d8
* [clang.py] Implement Type.is_podGregory Szorc2012-02-052-0/+26
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@149842 91177308-0d34-0410-b5e6-96231b3b80d8
* [clang.py] Change type -> TypeTobias Grosser2012-02-051-4/+3
| | | | | | | Names that have corresponding classes in python are commonly started with an uppercase letter. Let's follow that convention. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@149831 91177308-0d34-0410-b5e6-96231b3b80d8
* [clang.py] Implement Cursor.enum_typeTobias Grosser2012-02-052-0/+33
| | | | | | Contributed by: Gregory Szorc <gregory.szorc@gmail.com> git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@149830 91177308-0d34-0410-b5e6-96231b3b80d8
* [clang.py] Implement Cursor.underlying_typedef_typeTobias Grosser2012-02-052-0/+33
| | | | | | Contributed by: Gregory Szorc <gregory.szorc@gmail.com> git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@149829 91177308-0d34-0410-b5e6-96231b3b80d8
* [clang.py] add TypeKind.VECTORTobias Grosser2012-02-051-0/+1
| | | | | | | | Added a missing enumeration. Contributed by: Gregory Szorc <gregory.szorc@gmail.com> git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@149828 91177308-0d34-0410-b5e6-96231b3b80d8
* [clang.py] Add CursorKind.{is_translation_unit, is_preprocessing, is_unexposed}Tobias Grosser2012-02-052-0/+33
| | | | | | Contributed by: Gregory Szorc <gregory.szorc@gmail.com> git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@149827 91177308-0d34-0410-b5e6-96231b3b80d8
* [clang.py] Implement Cursor.hashTobias Grosser2012-02-052-0/+13
| | | | | | Contributed by: Gregory Szorc <gregory.szorc@gmail.com> git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@149826 91177308-0d34-0410-b5e6-96231b3b80d8
* [clang.py] Expose diagnostic category and option info to Python bindingTobias Grosser2012-02-052-3/+68
| | | | | | Contributed by: Gregory Szorc <gregory.szorc@gmail.com> git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@149825 91177308-0d34-0410-b5e6-96231b3b80d8
* [clang.py] Implement __eq__ and __ne__ on SourceLocation and SourceRangeTobias Grosser2012-02-052-1/+39
| | | | | | | | | | There is no type checking in __eq__, so ctypes will throw if the wrong Python type is passed in to the C function. Personally, I feel garbage in means garbage out and it isn't worth testing for this explicitly. Contributed by: Gregory Szorc <gregory.szorc@gmail.com> git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@149824 91177308-0d34-0410-b5e6-96231b3b80d8
* Add CXX_FINAL_ATTR, CXX_OVERRIDE_ATTR, ANNOTATE_ATTR and ASM_LABEL_ATTR to theRafael Espindola2011-12-301-0/+5
| | | | | | | python bindinds. patch by Tom Schuster! git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@147378 91177308-0d34-0410-b5e6-96231b3b80d8
* Mass rename C1x references to C11. The name hasn't proliferated like "C++0x" ↵Benjamin Kramer2011-12-231-1/+1
| | | | | | | | so this patch is surprisingly small. Also drop -Wc1x-extensions in favor of -Wc11-extensions. I don't think we need to keep this around for compatibility. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@147221 91177308-0d34-0410-b5e6-96231b3b80d8
* cindex.py: Remove more ternary operator + whitespace fixesTobias Grosser2011-10-311-6/+11
| | | | | | | Another batch of ternary operators and some whitespace fixes (Getting in sync with the clang_complete version of this file) git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@143330 91177308-0d34-0410-b5e6-96231b3b80d8
* clang.py: Remove use of ternary operatorsTobias Grosser2011-10-311-2/+9
| | | | | | This change is necessary to make this file python 2.4 compatible. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@143324 91177308-0d34-0410-b5e6-96231b3b80d8
* cindex.py: Allow to create a cursor from file/row/columnTobias Grosser2011-10-312-1/+29
| | | | | | | We add a constructor to create a SourceLocation from a position in a file and we use this SourceLocation to retrieve a cursor. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@143322 91177308-0d34-0410-b5e6-96231b3b80d8
* cindex.py: Add File.create_from_name()Tobias Grosser2011-10-312-0/+24
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@143321 91177308-0d34-0410-b5e6-96231b3b80d8
* Add support for constant arrays, from Anders Waldenborg!.Douglas Gregor2011-10-192-0/+24
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@142477 91177308-0d34-0410-b5e6-96231b3b80d8
* Add TypeKind.CONSTANTARRAY, from Anders Waldenborg!Douglas Gregor2011-10-192-1/+20
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@142476 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix error message for unknown type kind, from Anders Waldenborg!Douglas Gregor2011-10-191-1/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@142475 91177308-0d34-0410-b5e6-96231b3b80d8
* This new field was introduced in clang-c in r141277Douglas Gregor2011-10-191-1/+1
| | | | | | | | Python needs this in its structure definition so it allocates enough memory. From Anders Waldenborg! git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@142474 91177308-0d34-0410-b5e6-96231b3b80d8
* Expose more statement, expression, and declaration kinds in libclang,Douglas Gregor2011-10-051-5/+262
| | | | | | | from Manuel Holtgrewe! git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@141200 91177308-0d34-0410-b5e6-96231b3b80d8
* Update python testcase for GNU old-style field designator warning,Douglas Gregor2011-08-301-1/+1
| | | | | | | from Anders Waldenborg! git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@138786 91177308-0d34-0410-b5e6-96231b3b80d8
* Add support for Cursor.displayname in python bindings, from Anders Waldenborg!Douglas Gregor2011-08-302-0/+13
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@138785 91177308-0d34-0410-b5e6-96231b3b80d8
* [python] Fix bug of the SourceLocation binding.Argyrios Kyrtzidis2011-08-172-1/+51
| | | | | | Patch by Anders Waldenborg! git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@137829 91177308-0d34-0410-b5e6-96231b3b80d8
* [python] Add test_type.py by Anders Waldenborg, which I forgot to commit in ↵Argyrios Kyrtzidis2011-08-171-0/+76
| | | | | | r137797. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@137828 91177308-0d34-0410-b5e6-96231b3b80d8
* [python] Add support for CXType to python bindings.Argyrios Kyrtzidis2011-08-172-2/+210
| | | | | | Patch by Anders Waldenborg! git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@137797 91177308-0d34-0410-b5e6-96231b3b80d8
* Improve the Python bindings for libclang in a few ways, from EliDouglas Gregor2011-07-063-12/+33
| | | | | | | | | | | | | | | | | | | Bendersky. Specifically: * Implemented a new function in libclang: clang_isAttribute * Fixing TranslationUnit.get_includes to only go through the argument * buffer when it contains something. This fixed a crash on Windows * clang_getFileName returns CXString, not char*. Made appropriate * fixes in cindex.py - now the relevant tests pass and we can see the * full locations correctly again (previously there was garbage in * place of the file name) * Exposed clang_getCursorDisplayName to the python bindings git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@134460 91177308-0d34-0410-b5e6-96231b3b80d8
* python bindings: Add support for different kind of completion chunksTobias Grosser2011-02-051-6/+81
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@124959 91177308-0d34-0410-b5e6-96231b3b80d8
* python bindings: Get the string representation of a CompletionChunkTobias Grosser2011-02-051-9/+84
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@124958 91177308-0d34-0410-b5e6-96231b3b80d8
* python bindings: Add CodeCompletionResultsTobias Grosser2011-02-051-1/+94
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@124957 91177308-0d34-0410-b5e6-96231b3b80d8
* python bindings: Add support for translationUnit.reparse().Tobias Grosser2011-02-052-6/+47
| | | | | | | | This is the first step to make the clang_complete vim plugin work with libclang. Reparsing improves parsing time from 0.8 to 0.25 secs for one of my LLVM .cpp files. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@124956 91177308-0d34-0410-b5e6-96231b3b80d8
* python bindings: Include local headers the right way.Tobias Grosser2011-02-051-4/+3
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@124955 91177308-0d34-0410-b5e6-96231b3b80d8
* python bindings: Remove unneeded instructionTobias Grosser2011-02-051-2/+0
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@124954 91177308-0d34-0410-b5e6-96231b3b80d8
* python bindings: fix Diagnostics.range iteratorTobias Grosser2011-02-052-0/+25
| | | | | | | The iterator did never throw an IndexError. It was therefore not possible to use it in a normal foreach loop as that loop would never stop. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@124953 91177308-0d34-0410-b5e6-96231b3b80d8
* python bindings: Use python Diagnostics as function argumentsTobias Grosser2011-02-051-14/+17
| | | | | | | | | | | | This improves the readability of the code and fixes one testsuite bug. The bug happend, because we only stored the pointer to the diagnostic in the FixIt iterator, but not the python Diagnostic object. So it could happen that the FixIt iterator still exists, but the python Diagnostic object is freed. However, as the python Diagnostic is freed the pointer to the diagnostic is also freed and the FixIt iterator is referencing a freed pointer. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@124952 91177308-0d34-0410-b5e6-96231b3b80d8
* python bindings: Synchronize cursor kindsTobias Grosser2011-02-051-0/+89
| | | | | | | | clang-c/Index.h contained cursor kinds not yet available in the python bindings. Contributed-By: jmuizelaar@mozilla.com git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@124951 91177308-0d34-0410-b5e6-96231b3b80d8
* Rename 'CIndex' to 'libclang', since it has basically become our stable publicDaniel Dunbar2010-04-302-6/+5
| | | | | | (C) API, and will likely grow further in this direction in the future. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@102779 91177308-0d34-0410-b5e6-96231b3b80d8
* Rename the new Iterator objects and raise an assertion instead of returning ↵Benjamin Kramer2010-03-061-10/+12
| | | | | | invalid objects when the key is out of range. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@97881 91177308-0d34-0410-b5e6-96231b3b80d8
* Update the python bindings for recent changes in the CIndex API.Benjamin Kramer2010-03-061-88/+88
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@97880 91177308-0d34-0410-b5e6-96231b3b80d8