| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
|
|
|
|
|
|
| |
Another follow-up to r319840. I'd done a test configure with
LLVM_BUILD_STATIC, so I'm not sure why this didn't show up in that.
llvm-svn: 319983
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
We currently use target_link_libraries without an explicit scope
specifier (INTERFACE, PRIVATE or PUBLIC) when linking executables.
Dependencies added in this way apply to both the target and its
dependencies, i.e. they become part of the executable's link interface
and are transitive.
Transitive dependencies generally don't make sense for executables,
since you wouldn't normally be linking against an executable. This also
causes issues for generating install export files when using
LLVM_DISTRIBUTION_COMPONENTS. For example, clang has a lot of LLVM
library dependencies, which are currently added as interface
dependencies. If clang is in the distribution components but the LLVM
libraries it depends on aren't (which is a perfectly legitimate use case
if the LLVM libraries are being built static and there are therefore no
run-time dependencies on them), CMake will complain about the LLVM
libraries not being in export set when attempting to generate the
install export file for clang. This is reasonable behavior on CMake's
part, and the right thing is for LLVM's build system to explicitly use
PRIVATE dependencies for executables.
Unfortunately, CMake doesn't allow you to mix and match the keyword and
non-keyword target_link_libraries signatures for a single target; i.e.,
if a single call to target_link_libraries for a particular target uses
one of the INTERFACE, PRIVATE, or PUBLIC keywords, all other calls must
also be updated to use those keywords. This means we must do this change
in a single shot. I also fully expect to have missed some instances; I
tested by enabling all the projects in the monorepo (except dragonegg),
and configuring both with and without shared libraries, on both Darwin
and Linux, but I'm planning to rely on the buildbots for other
configurations (since it should be pretty easy to fix those).
Even after this change, we still have a lot of target_link_libraries
calls that don't specify a scope keyword, mostly for shared libraries.
I'm thinking about addressing those in a follow-up, but that's a
separate change IMO.
Differential Revision: https://reviews.llvm.org/D40823
llvm-svn: 319840
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
by client
This patch extends libclang by allowing it to record parsing operations to a
temporary JSON file. The file is deleted after parsing succeeds. When a crash
happens during parsing, the file is preserved and the client will be able to use
it to generate a reproducer for the crash.
These files are not emitted by default, and the client has to specify the
invocation emission path first.
rdar://35322543
Differential Revision: https://reviews.llvm.org/D40527
llvm-svn: 319702
|
|
|
|
|
|
|
|
|
|
| |
Use this function to create the install targets rather than doing so
manually, which gains us the `-stripped` install targets to perform
stripped installations.
Differential Revision: https://reviews.llvm.org/D40675
llvm-svn: 319489
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary:
ObjC classes have two associated symbols, one for the class and one for the
metaclass.
This change overloads `CodegenNameGenerator::getAllManglings` to produce both
class and metaclass symbols.
While this function is called by `clang_Cursor_getCXXManglings`, it's only
called for CXXRecordDecl and CXXMethodDecl, and so libclang's behavior is
unchanged.
Reviewers: arphaman, abdulras, alexshap, compnerd
Reviewed By: compnerd
Subscribers: compnerd
Differential Revision: https://reviews.llvm.org/D37671
llvm-svn: 313997
|
|
|
|
|
|
|
|
|
|
|
| |
This commit allows checking whether an enum declaration is scoped
through libclang and clang.cindex (Python).
Patch by Johann Klähn!
Differential Revision: https://reviews.llvm.org/D35187
llvm-svn: 307771
|
|
|
|
| |
llvm-svn: 307770
|
|
|
|
|
|
|
|
|
| |
This commit allows checking whether an enum declaration is scoped
through libclang and clang.cindex (Python).
Differential Revision: https://reviews.llvm.org/D35187
llvm-svn: 307769
|
|
|
|
|
|
|
|
|
| |
not the ASTContext state.
We use this when running a preprocessor-only action on an AST file in order to
avoid paying the runtime cost of loading the extra information.
llvm-svn: 306760
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
libclang
Summary: This patch exposes the exception specification type (noexcept,
etc.) of a C++ function through libclang and Python clang.cindex.
Reviewers: rsmith, aaron.ballman
Reviewed By: aaron.ballman
Subscribers: jbcoe, cfe-commits
Differential Revision: https://reviews.llvm.org/D34091
Patch by Andrew Bennieston
llvm-svn: 306483
|
|
|
|
|
|
|
|
| |
'CXTranslationUnit_SingleFileParse' that puts preprocessor in a mode for parsing a single file only.
This is useful for parsing a single file, as a fast/inaccurate 'mode' that can still provide declarations from the file, like the classes and their methods.
llvm-svn: 305044
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
A suspended translation unit uses significantly less memory but on the
other side does not support any other calls than
clang_reparseTranslationUnit to resume it or
clang_disposeTranslationUnit to dispose it completely.
This helps IDEs to reduce the memory footprint. The data that is freed
by a call to clang_suspendTranslationUnit will be re-generated on the
next (re)parse anyway. Used with a preamble, this allows pretty fast
resumption of the translation unit for further use (compared to disposal
of the translation unit and a parse from scratch).
Patch by Nikolai Kosjar!
llvm-svn: 304212
|
|
|
|
|
|
| |
decls marked with external_source_symbol attribute
llvm-svn: 302677
|
|
|
|
|
|
|
|
|
|
|
| |
This allows users to query the target triple and target pointer width, which
would make me able to fix https://github.com/servo/rust-bindgen/issues/593 and
other related bugs in an elegant way (without having to manually parse the
target triple in the command line arguments).
Differential Revision: https://reviews.llvm.org/D32389
llvm-svn: 301648
|
|
|
|
|
|
|
|
| |
clang_Cursor_getReceiverType to handle ObjC property references
Also enhance clang_Cursor_getReceiverType to handle C++ method calls.
llvm-svn: 301568
|
|
|
|
|
|
| |
language then report it accordingly
llvm-svn: 301183
|
|
|
|
| |
llvm-svn: 298441
|
|
|
|
|
|
|
|
|
|
| |
its underlying tag type
In such a case, as when using the NS_ENUM macro, for indexing purposes treat the typedef as 'transparent',
meaning we treat its references as symbols of the underlying tag symbol.
Also provide a libclang API to check for such typedefs.
llvm-svn: 298392
|
|
|
|
|
|
|
|
|
|
|
|
| |
distinguish function-local symbols
Parameters have a 'child' relation to their function/method.
Also add an option '-include-locals' to 'c-index-test core' to enable indexing of function-local symbols.
Original patch from Nathan Hawes with some changes by me.
https://reviews.llvm.org/D30304
llvm-svn: 296282
|
|
|
|
|
|
| |
It's unnecessary.
llvm-svn: 295934
|
|
|
|
| |
llvm-svn: 295245
|
|
|
|
| |
llvm-svn: 293466
|
|
|
|
|
|
|
|
| |
their input files.
This ensures the capability to index a module file using an existing ASTReader from a compiler instance or ASTUnit.
llvm-svn: 293461
|
|
|
|
|
|
| |
information from a PCH/module file.
llvm-svn: 293416
|
|
|
|
|
|
| |
Initially reports if a constructor symbol is a copy or move constructor.
llvm-svn: 291409
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
and CodeCompleteConsumer"
Aleksey Shlypanikov pointed out my mistake in migrating an explicit
unique_ptr to auto - I was expecting the function returned a unique_ptr,
but instead it returned a raw pointer - introducing a leak.
Thanks Aleksey!
This reapplies r291184, reverted in r291249.
llvm-svn: 291270
|
|
|
|
|
|
|
|
|
|
| |
CodeCompleteConsumer"
Caused a memory leak reported by asan. Reverting while I investigate.
This reverts commit r291184.
llvm-svn: 291249
|
|
|
|
|
|
| |
CodeCompleteConsumer
llvm-svn: 291184
|
|
|
|
|
|
|
|
|
| |
clang_Type_getNumTemplateArguments and clang_Type_getTemplateArgumentAsType
Patch by Emilio Cobos Álvarez!
See https://reviews.llvm.org/D26907
llvm-svn: 289995
|
|
|
|
|
|
|
|
|
| |
CXEvalResult without overflow
Patch by Emilio Cobos Álvarez!
See https://reviews.llvm.org/D26788
llvm-svn: 288438
|
|
|
|
|
|
| |
This better reflects what it represents.
llvm-svn: 286680
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
template
The core of the change is supposed to be NFC, however it also fixes
what I believe was an undefined behavior when calling:
va_start(ValueArgs, Desc);
with Desc being a StringRef.
Differential Revision: https://reviews.llvm.org/D25342
llvm-svn: 283671
|
|
|
|
|
|
| |
did not return -1.
llvm-svn: 277261
|
|
|
|
| |
llvm-svn: 272233
|
|
|
|
|
|
| |
rdar://25963227
llvm-svn: 271351
|
|
|
|
|
|
|
|
|
| |
This patch adds an API for querying the visibility of the entity
referred to by a cursor.
Patch by Michael Wu <mwu@mozilla.com>.
llvm-svn: 271292
|
|
|
|
| |
llvm-svn: 271291
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This fixes dead store warnings of the type "dead assignment" reported
by CLang Static Analyzer on the following file:
- tools/c-index-test/c-index-test.c.
Patch by Apelete Seketeli <apelete@seketeli.net>!
Differential Revision: http://reviews.llvm.org/D19831
llvm-svn: 268453
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
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
|
|
|
|
| |
llvm-svn: 267117
|
|
|
|
|
|
| |
This provides a more general and flexible way to annotate special symbols.
llvm-svn: 267116
|
|
|
|
| |
llvm-svn: 265252
|
|
|
|
| |
llvm-svn: 264874
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This behavior is enabled when the new CXTranslationUnit_KeepGoing
option is passed to clang_parseTranslationUnit{,2}. It is geared
towards use by IDEs and similar consumers of the clang-c API where
fatal errors may arise when parsing incomplete code mid-edit, or
when include paths are not properly configured yet. In such situations
one still wants to get as much information as possible about a TU.
Previously, the semantic analysis would not instantiate templates
or report additional fatal errors after the first fatal error was
encountered.
Fixes PR24268.
Patch by Milian Wolff.
llvm-svn: 262318
|
|
|
|
| |
llvm-svn: 262208
|
|
|
|
|
|
|
|
| |
directory, add an rpath so that
it can find libclang.
llvm-svn: 261445
|
|
|
|
|
|
|
|
|
|
| |
printing policy.
Enable it for USRs and names when indexing.
Forward references can have different template argument names; including them
makes USRs and names unstable, since the name depends on whether we saw a forward reference or not.
llvm-svn: 260866
|
|
|
|
|
|
| |
symbols into the clangIndex library.
llvm-svn: 260858
|
|
|
|
|
|
| |
Found by lsan.
llvm-svn: 260850
|
|
|
|
| |
llvm-svn: 260847
|