| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
|
|
|
|
|
|
|
|
|
|
|
| |
Expose the following functions:
- clang_getTypedefName
- clang_getAddressSpace
Patch by Simon Perretta.
Differential Revision: https://reviews.llvm.org/D33598
llvm-svn: 304978
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary:
Introduce an interop string to convert from unicode to c-strings where needed.
Add missing conversions from _CXString to strings in function registrations.
Explicitly evaluate lists where Python 3's lazy iterators would not otherwise do so.
This is an improvement upon the reverted change proposed in https://reviews.llvm.org/D26082
Reviewers: compnerd, skalinichev, modocache, MathieuDuponchelle
Reviewed By: compnerd
Subscribers: cfe-commits
Tags: #clang-c
Differential Revision: https://reviews.llvm.org/D31568
llvm-svn: 300829
|
|
|
|
|
|
|
|
|
| |
This reverts commit 4464581bb63e9789e9ee231a8c8800be5f614743.
Memory access issues on Linux were reported by Mathieu Duponchelle and
discussed here: https://reviews.llvm.org/D26082.
llvm-svn: 291907
|
|
|
|
|
|
| |
It was broken in r286421
llvm-svn: 288582
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary:
Python bindings tests now pass in Python 3.
`map` in Python 3 is lazily evaluated so the method by which functions are registered needed updating.
Strings are unicode in Python 3 not UTF-8, I've tried to create an new c_types-like class (c_string_p) to automate the conversion.
String conversions made explicit where required.
Reviewers: eliben, nemanjai, skalinichev, compnerd
Subscribers: mgorny, cfe-commits
Differential Revision: https://reviews.llvm.org/D26082
llvm-svn: 285909
|
|
|
|
|
|
|
|
|
|
| |
CursorKind.OVERLOAD_CANDIDATE.
The test fails because the value does not lay in any existing group.
Differential Revision: https://reviews.llvm.org/D25470
llvm-svn: 284463
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This exposes the Clang API bindings clang_getChildDiagnostics (which returns a
CXDiagnosticSet) and clang_getNumDiagnosticsInSet / clang_getDiagnosticInSet (to
traverse the CXDiagnosticSet), and adds a helper children property in the Python
Diagnostic wrapper.
Also, this adds the missing OVERLOAD_CANDIDATE (700) cursor type.
Patch by Hanson Wang!
llvm-svn: 268167
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
bindings.
Summary:
I have exposed the following function through libclang and the clang.cindex python bindings:
clang_CXXConstructor_isConvertingConstructor,
clang_CXXConstructor_isCopyConstructor,
clang_CXXConstructor_isDefaultConstructor,
clang_CXXConstructor_isMoveConstructor,
clang_CXXMethod_isDefaulted
I need (some of) these methods for a C++ code model I am building in Python to drive a code generator.
Reviewers: compnerd, skalinichev
Subscribers: cfe-commits
Differential Revision: http://reviews.llvm.org/D15469
llvm-svn: 267706
|
|
|
|
|
|
|
|
| |
Reviewers: compnerd, skalinichev
Differential Revision: http://reviews.llvm.org/D17278
llvm-svn: 262845
|
|
|
|
|
|
|
|
| |
This makes TypeAliasTemplateDecl accessible via LibClang and python bindings
Differential Revision: http://reviews.llvm.org/D13844
llvm-svn: 253166
|
|
|
|
|
|
|
|
| |
Expose isMutable via libClang and python bindings.
Patch by Jonathan B Coe!
llvm-svn: 251410
|
|
|
|
|
|
|
|
|
| |
Add methods to index Cursor to see if a cxx method is pure_virtual,
virtual or const methods.
Patch by Jonathan B Coe!
llvm-svn: 250008
|
|
|
|
|
|
|
|
|
|
|
|
| |
It used to work, but was accidentally broken by r179769.
The issue with decayed types was fixed by r190796.
So this patch partially reverts r179769, and adds more tests.
This also fixes PR 18669.
Patch by Sergey Kalinichev.
llvm-svn: 246778
|
|
|
|
|
|
| |
Patch by Loïc Jaquemet!
llvm-svn: 234762
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
It should bring the bots back.
Original messagses:
r227448:
Remove unnecessary default.
r227438:
Fix Index/print-type.cpp test following r227432.
r227432:
libclang: Add three functions useful for dealing with anonymous fields:
clang_Cursor_getOffsetOfField
clang_Cursor_isAnonymous
clang_Type_visitFields
Python: Add corresponding methods for dealing with anonymous fields.
Patch by Loïc Jaquemet
llvm-svn: 227472
|
|
|
|
|
|
|
|
|
|
|
| |
clang_Cursor_getOffsetOfField
clang_Cursor_isAnonymous
clang_Type_visitFields
Python: Add corresponding methods for dealing with anonymous fields.
Patch by Loïc Jaquemet
llvm-svn: 227432
|
|
|
|
|
|
|
|
|
| |
Includes Python bindings.
Reviewed in http://reviews.llvm.org/D5621
Patch by Rob Springer
llvm-svn: 219529
|
|
|
|
| |
llvm-svn: 214930
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Before r160106 there was a way to recursively visit all descendants of a cursor
via Cursor_visit, but it was removed. Since then, every user needs to
reimplement the recursive descent into get_children.
Adding a walk_preorder() method to Cursor that conveniently implements recursive
walking in a Pythonic way. This also greatly simplifies get_cursor and
get_cursors in tests/cindex/util.py (walk_preorder is now tested through these
utility functions, since they are used in many tests).
llvm-svn: 209793
|
|
|
|
|
|
|
|
|
| |
clang was fixed some time ago to always skip "builtins and other cruft" so
tools no longer need hacks like this.
Passes nosetests.
llvm-svn: 209316
|
|
|
|
|
|
|
|
|
|
| |
Expose the enum CX_CXXAccessSpecifier in the python bindings as a property of
the cursor. If access specifier is not applicable to the node, return the
INVALID specifier rather than raising an exception.
Patch by Tamás Szeli!
llvm-svn: 207173
|
|
|
|
|
|
|
|
| |
file.
Patch by Brian Gesiak!
llvm-svn: 201762
|
|
|
|
|
|
|
|
| |
python bindings.
Patch by Laszlo Nagy!
llvm-svn: 197765
|
|
|
|
| |
llvm-svn: 192108
|
|
|
|
| |
llvm-svn: 191907
|
|
|
|
|
|
|
|
| |
original (as written) type.
Patch by Anders Waldenborg!
llvm-svn: 190796
|
|
|
|
|
|
| |
Patch by Che-Liang Chiou!
llvm-svn: 186967
|
|
|
|
|
|
|
|
| |
binding for libclang.
Patch by Mathieu Baudet!
llvm-svn: 183760
|
|
|
|
|
|
|
|
|
|
|
| |
clang_Type_getAlignOf
clang_Type_getSizeOf
clang_Type_getOffsetOf
clang_Cursor_isBitField
Patch by Loïc Jaquemet!
llvm-svn: 179251
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The code inside cindex.py was comparing NULL pointer returned by
clang_parseTranslationUnit and clang_createTranslationUnit with None.
However, as illustrated by the two tests I've added, those conditions
were ineffective which resulted in assert triggering later on.
Instead, a pointer is now treated as a boolean value, a NULL pointer being
False.
Contributed-by: Xavier Deguillard <deguilx@gmail.com>
llvm-svn: 177408
|
|
|
|
|
|
| |
Patch by Matthew King!
llvm-svn: 171423
|
|
|
|
|
|
| |
Patch provided by Matthias Kleine <matthias_kleine@gmx.de>
llvm-svn: 167216
|
|
|
|
|
|
| |
Patch by Leo Liu, test case by me.
llvm-svn: 165374
|
|
|
|
| |
llvm-svn: 163966
|
|
|
|
| |
llvm-svn: 160111
|
|
|
|
| |
llvm-svn: 160107
|
|
|
|
|
|
|
|
| |
CompileCommand.directory and the rest of the python binding
Patch by David Röthlisberger
llvm-svn: 159970
|
|
|
|
|
|
| |
Patch by David Röthlisberger
llvm-svn: 159926
|
|
|
|
| |
llvm-svn: 159492
|
|
|
|
| |
llvm-svn: 159485
|
|
|
|
| |
llvm-svn: 158307
|
|
|
|
| |
llvm-svn: 158277
|
|
|
|
| |
llvm-svn: 156846
|
|
|
|
| |
llvm-svn: 156753
|
|
|
|
| |
llvm-svn: 156752
|
|
|
|
| |
llvm-svn: 156373
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* 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
|
|
|
|
|
|
|
|
|
| |
- 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
|
|
|
|
| |
llvm-svn: 156022
|
|
|
|
| |
llvm-svn: 156017
|