| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
|
|
|
|
|
|
|
|
| |
This reverts commit r213307.
Reverting to have some on-list discussion/confirmation about the ongoing
direction of smart pointer usage in the LLVM project.
llvm-svn: 213325
|
|
|
|
|
|
|
|
|
| |
(after fixing a bug in MultiplexConsumer I noticed the ownership of the
nested consumers was implemented with raw pointers - so this fixes
that... and follows the source back to its origin pushing unique_ptr
ownership up through there too)
llvm-svn: 213307
|
|
|
|
|
|
|
|
| |
r212427 formalized the message-passing pattern by making these argument
structures const. This commit changes output arguments to get passed by
reference so we can eliminate mutable fields.
llvm-svn: 212497
|
|
|
|
|
|
|
| |
Consolidate CXUnsavedFile argument handling in API functions to support a wider
cleanup of various file remapping schemes in the frontend.
llvm-svn: 212427
|
|
|
|
| |
llvm-svn: 212369
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This removes a const_cast added in r211884 that occurred due to an
inconsistency in how MemoryBuffers are handled between some parts of
clang and LLVM.
MemoryBuffers are immutable and the general convention in the LLVM
project is to omit const from immutable types as it's simply
redundant/verbose (see llvm::Type, for example). While this change
doesn't remove "const" from /every/ MemoryBuffer, it at least makes this
chain of ownership/usage consistent.
llvm-svn: 211915
|
|
|
|
| |
llvm-svn: 210422
|
|
|
|
|
|
|
| |
This allows code indexing, etc. to use the VFS in the same way as the
compiler.
llvm-svn: 206309
|
|
|
|
|
|
| |
class.
llvm-svn: 204002
|
|
|
|
|
|
| |
This compiles cleanly with lldb/lld/clang-tools-extra/llvm.
llvm-svn: 203279
|
|
|
|
| |
llvm-svn: 202639
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This commit improves libclang to report the error condition when
CXTranslationUnit can not be created because of a stale PCH file. This allows
the caller, for example, to rebuild the PCH file and retry the request.
There two are APIs in libclang that return a CXTranslationUnit and don't
support reporting detailed errors (the only error condition is a NULL result).
For these APIs, a second, superior, version is introduced --
clang_createTranslationUnit2 and clang_parseTranslationUnit2. These functions
return a CXTranslationUnit indirectly and also return an error code. Old
functions are still supported and are nothing more than convenience wrappers
that ignore extended error codes.
As a cleanup, this commit also categorizes some libclang errors in the
functions I had to modify anyway.
llvm-svn: 201249
|
|
|
|
| |
llvm-svn: 201156
|
|
|
|
|
|
|
| |
checks for invalid translation unit are in place. Also, while there, add log
output for this case.
llvm-svn: 201155
|
|
|
|
| |
llvm-svn: 188678
|
|
|
|
| |
llvm-svn: 188625
|
|
|
|
|
|
| |
reported by MSan
llvm-svn: 187647
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This unifies the unix and windows versions of FileManager::UniqueDirContainer
and FileManager::UniqueFileContainer by using UniqueID.
We cannot just replace "struct stat" with llvm::sys::fs::file_status, since we
want to be able to construct fake ones, and file_status has different members
on unix and windows.
What the patch does is:
* Record only the information that clang is actually using.
* Use llvm::sys::fs::status instead of stat and fstat.
* Use llvm::sys::fs::UniqueID
* Delete the old windows versions of UniqueDirContainer and
UniqueFileContainer since the "unix" one now works on windows too.
llvm-svn: 187619
|
|
|
|
| |
llvm-svn: 181070
|
|
|
|
|
|
|
|
| |
MacroArgs object that provides information about
the argument tokens for a function macro.
llvm-svn: 181065
|
|
|
|
|
|
| |
stderr instead of capturing them.
llvm-svn: 178373
|
|
|
|
|
|
|
|
| |
available the
full information about the macro (e.g if it was imported and where).
llvm-svn: 175978
|
|
|
|
| |
llvm-svn: 174285
|
|
|
|
| |
llvm-svn: 174060
|
|
|
|
| |
llvm-svn: 173590
|
|
|
|
|
|
| |
into a getter cxtu::getASTUnit(TU)
llvm-svn: 173585
|
|
|
|
|
|
|
| |
Also, it was the only reason that `argc` and `argv` were being passed
into createDiagnostics, so remove those parameters and clean up callers.
llvm-svn: 172945
|
|
|
|
|
|
|
|
|
|
| |
Manually fix the order of UnwrappedLineParser.cpp as that one didn't
have its associated header as the first header.
This also uncovered a subtle inclusion order dependency as CLog.h didn't
include LLVM.h to pick up using declarations it relied upon.
llvm-svn: 172892
|
|
|
|
|
|
|
|
|
| |
-provide a "raw_ostream'ish" class to make it convenient to output logging info.
-use macros to automate a bit the logging functionality inside libclang functions
-when logging, print a stack trace if "LIBCLANG_LOGGING=2" environment is set.
-add logging to more functions.
llvm-svn: 172089
|
|
|
|
|
|
|
| |
Removes a duplicate #include as well as cleaning up some sort order
regressions since I last ran the script over Clang.
llvm-svn: 171364
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
that were already parsed in the same "indexing session".
An indexing session is defined as using the same CXIndexAction object
for multiple clang_indexSourceFile calls.
Passing CXIndexOpt_SkipParsedBodiesInSession as an indexing option will
enable the mode where we try to skip bodies that were already parsed in
another translation unit.
If a function's body was skipped, the "flags" field in the CXIdxDeclInfo
structure will have "CXIdxDeclFlag_Skipped" bit was set.
llvm-svn: 169539
|
|
|
|
|
|
| |
Completely automated with sort_includes.py
llvm-svn: 169240
|
|
|
|
|
|
|
| |
the various stakeholders bump up the reference count. In particular,
the diagnostics engine now keeps the DiagnosticOptions object alive.
llvm-svn: 166508
|
|
|
|
|
|
| |
imports.
llvm-svn: 166161
|
|
|
|
|
|
| |
and modules are not enabled.
llvm-svn: 165593
|
|
|
|
|
|
|
| |
an invalid location if the location points to the synthetic buffer
for the module input.
llvm-svn: 165592
|
|
|
|
|
|
|
|
|
|
|
|
| |
to not mess up with module building.
It was not worth trying to combine indexing without preprocessing record
and building modules with one because:
-just importing a module/PCH that was built with a pp record, enables it anyway
-the performance gain of indexing without the preprocessing record is insignificant.
llvm-svn: 165352
|
|
|
|
| |
llvm-svn: 165161
|
|
|
|
|
|
| |
imports via ImportDecls.
llvm-svn: 165160
|
|
|
|
| |
llvm-svn: 165083
|
|
|
|
|
|
| |
declarations of the current primary module.
llvm-svn: 165046
|
|
|
|
|
|
| |
entities of the current primary module.
llvm-svn: 165023
|
|
|
|
|
|
| |
resulted in an automatic module import.
llvm-svn: 165022
|
|
|
|
|
|
| |
make sure that it gets enabled for when a module needs to be created.
llvm-svn: 165021
|
|
|
|
|
|
| |
info about imported modules.
llvm-svn: 165020
|
|
|
|
|
|
|
| |
an inclusion directive was automatically turned into a module import, and
PPCallbacks::moduleImport() for an explicit module import.
llvm-svn: 164874
|
|
|
|
|
|
|
|
|
|
| |
http://lists.cs.uiuc.edu/pipermail/cfe-commits/Week-of-Mon-20120917/064551.html
have PPCallbacks::InclusionDirective pass the character range for the filename quotes or brackets.
rdar://11113134 & http://llvm.org/PR13880
llvm-svn: 164743
|
|
|
|
| |
llvm-svn: 164626
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
as "volatile", meaning there's a high enough chance that they may
change while we are trying to use them.
This flag is only enabled by libclang.
Currently "volatile" source files will be stat'ed immediately
before opening them, because the file size stat info
may not be accurate since when we got it (e.g. from the PCH).
This avoids crashes when trying to reference mmap'ed memory
from a file whose size is not what we expect.
Note that there's still a window for a racing issue to occur
but the window for it should be way smaller than before.
We can consider later on to avoid mmap completely on such files.
rdar://11612916
llvm-svn: 160074
|
|
|
|
|
|
|
|
| |
It may end up pointing at garbage.
Fixes the MSVC debug build. rdar://11703319
llvm-svn: 159377
|