summaryrefslogtreecommitdiffstats
path: root/clang/examples
Commit message (Collapse)AuthorAgeFilesLines
...
* [C++11] Replace OwningPtr include with <memory>.Ahmed Charles2014-03-091-1/+1
| | | | llvm-svn: 203389
* [C++11] Remove the remaining uses of OwningPtr.Ahmed Charles2014-03-092-6/+6
| | | | | | Replace OwningArrayPtr with std::unique_ptr<T[]>. llvm-svn: 203388
* [CMake] Get rid of explicit dependencies to include/clang/*.inc and ↵NAKAMURA Takumi2014-02-212-20/+0
| | | | | | | | | | | | | | | | | | | introduce CLANG_TABLEGEN_TARGETS. This does; - clang_tablegen() adds each tblgen'd target to global property CLANG_TABLEGEN_TARGETS as list. - List of targets is added to LLVM_COMMON_DEPENDS. - all clang libraries and targets depend on generated headers. You might wonder this would be regression, but in fact, this is little loss. - Almost all of clang libraries depend on tblgen'd files and clang-tblgen. - clang-tblgen may cause short stall-out but doesn't cause unconditional rebuild. - Each library's dependencies to tblgen'd files might vary along headers' structure. It made hard to track and update *really optimal* dependencies. Each dependency to intrinsics_gen and ClangSACheckers is left as DEPENDS. llvm-svn: 201842
* [CMake] Fix installation without CLANG_BUILD_EXAMPLESJordan Rose2014-02-201-0/+1
| | | | | | | | | | | | | | | | | | When CLANG_BUILD_EXAMPLES is not on we set the EXCLUDE_FROM_ALL directory property for the examples/ directory to tell CMake not to build them by default. The AddLLVM.cmake APIs are not aware of this and try to install targets that are not built. This does not cause an install-time error because CMake excludes the directory from the default installation. However, now that installation attaches targets to the LLVMExports export set CMake-based applications that find_package(LLVM) fail because the example plugin binary is not available. Tell the AddLLVM.cmake APIs to exclude the examples from installation by setting the EXCLUDE_FROM_ALL variable they check. Patch by Brad King! llvm-svn: 201799
* [examples] Add tablegen'd ClangCommentCommandList as a dependency for plugins.Jordan Rose2014-02-132-3/+2
| | | | | | | | Also, remove library dependencies for the sample analyzer-plugin. The only library changes that would require a rebuild should be in headers, which should already implicitly be marked as dependencies. llvm-svn: 201350
* [examples] Use loadable modules instead of shared libraries for Clang plugins.Jordan Rose2014-02-123-30/+3
| | | | | | This avoids linking in extra copies of, say, LLVMSupport. llvm-svn: 201256
* Expose the name of the checker producing each diagnostic message.Alexander Kornienko2014-02-111-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | Summary: In clang-tidy we'd like to know the name of the checker producing each diagnostic message. PathDiagnostic has BugType and Category fields, which are both arbitrary human-readable strings, but we need to know the exact name of the checker in the form that can be used in the CheckersControlList option to enable/disable the specific checker. This patch adds the CheckName field to the CheckerBase class, and sets it in the CheckerManager::registerChecker() method, which gets them from the CheckerRegistry. Checkers that implement multiple checks have to store the names of each check in the respective registerXXXChecker method. Reviewers: jordan_rose, krememek Reviewed By: jordan_rose CC: cfe-commits Differential Revision: http://llvm-reviews.chandlerc.com/D2557 llvm-svn: 201186
* [CMake] Suppress SampleAnalyzerPlugin w/o ENABLE_STATIC_ANALYZER.NAKAMURA Takumi2014-01-311-0/+2
| | | | llvm-svn: 200532
* [CMake] Parameterize MODULE and SHARED in add_clang_library().NAKAMURA Takumi2014-01-232-6/+2
| | | | llvm-svn: 199902
* Don't use PrintFunctionNames.exports on Windows.Nico Weber2013-12-301-3/+6
| | | | llvm-svn: 198187
* Fix typo in comment.Nico Weber2013-12-291-1/+1
| | | | llvm-svn: 198186
* [cmake] Set in LLVM_EXPORTED_SYMBOL_FILE PrintFunctionNames/CMakeLists.txt.Nico Weber2013-12-291-0/+8
| | | | | | | The corresponding Makefile sets it too. Also tweak add_clang_library to support LLVM_EXPORTED_SYMBOL_FILE for modules. llvm-svn: 198185
* Fix getCustomDiagID() usage in example codeAlp Toker2013-12-211-3/+3
| | | | | | | This was setting a bad example. DiagIDs are a limited resource and the message argument is evaluated as a format string. llvm-svn: 197855
* [CMake] Update target_link_libraries() and LLVM_LINK_COMPONENTS for each ↵NAKAMURA Takumi2013-12-103-27/+17
| | | | | | CMakeLists.txt. llvm-svn: 196916
* Add ObjCARCOpts to LINK_COMPONENTS.NAKAMURA Takumi2013-12-101-1/+1
| | | | llvm-svn: 196915
* Add irreader to the component list, because ParseIR is called.Bill Wendling2013-10-191-2/+2
| | | | llvm-svn: 193032
* Move Compilation::PrintJob and PrintDiagnosticJob into Job::Print.Hans Wennborg2013-09-121-2/+2
| | | | | | | | | | | | | | | | | This moves the code to Job.cpp, which seems like a more natural fit, and replaces the "is this a JobList? is this a Command?" logic with a virtual function call. It also removes the code duplication between PrintJob and PrintDiagnosticJob and simplifies the code a little. There's no functionality change here, except that the Executable is now always printed within quotes, whereas it would previously not be quoted in crash reports, which I think was a bug. Differential Revision: http://llvm-reviews.chandlerc.com/D1653 llvm-svn: 190620
* Remove unused header.Rafael Espindola2013-06-261-1/+0
| | | | llvm-svn: 184945
* Use llvm::sys::fs::getMainExecutable.Rafael Espindola2013-06-261-4/+5
| | | | llvm-svn: 184915
* Include PathV1.h only where it is used.Rafael Espindola2013-06-171-0/+1
| | | | llvm-svn: 184090
* [Driver] Refactor clang driver to use LLVM's Option libraryReid Kleckner2013-06-141-1/+1
| | | | | | | | | | | | | | | | | | The big changes are: - Deleting Driver/(Arg|Opt)* - Rewriting includes to llvm/Option/ and re-sorting - 'using namespace llvm::opt' in clang::driver - Fixing the autoconf build by adding option everywhere As discussed in the review, this change includes using directives in header files. I'll make follow up changes to remove those in favor of name specifiers. Reviewers: espindola Differential Revision: http://llvm-reviews.chandlerc.com/D975 llvm-svn: 183989
* The IRReader header is now part of its own library. Update the includeChandler Carruth2013-03-261-0/+1
| | | | | | line and the library dependencies to reflect this. llvm-svn: 177972
* Nuke SetUpBuildDumpLog.Sean Silva2013-01-201-1/+1
| | | | | | | 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
* Use getProcessTriple in clang-interpreter.Peter Collingbourne2013-01-161-2/+1
| | | | llvm-svn: 172664
* Remove useless 'llvm::' qualifier from names like StringRef and others that areDmitri Gribenko2013-01-121-1/+1
| | | | | | brought into 'clang' namespace by clang/Basic/LLVM.h llvm-svn: 172323
* Rewrite #includes for llvm/Foo.h to llvm/IR/Foo.h as appropriate toChandler Carruth2013-01-021-1/+1
| | | | | | | | reflect the migration in r171366. Re-sort the #include lines to reflect the new paths. llvm-svn: 171369
* Revert r170801, which breaks the mingw build.Douglas Gregor2012-12-201-0/+1
| | | | llvm-svn: 170804
* Eliminate errors when running the 'PrintFunctionNames' plugin, from Li Qun!Douglas Gregor2012-12-201-1/+0
| | | | llvm-svn: 170801
* Sort the #include lines for examples/...Chandler Carruth2012-12-043-10/+9
| | | | llvm-svn: 169241
* Fix examples.Rafael Espindola2012-11-271-1/+1
| | | | llvm-svn: 168705
* analyzer-plugin/MainCallChecker.cpp: Fixup corresponding to r167275.NAKAMURA Takumi2012-11-021-1/+1
| | | | llvm-svn: 167278
* Update clang-interpreter exampleDouglas Gregor2012-10-231-3/+4
| | | | llvm-svn: 166510
* Split library clangRewrite into clangRewriteCore and clangRewriteFrontend.Ted Kremenek2012-09-012-2/+3
| | | | | | | This is similar to how we divide up the StaticAnalyzer libraries to separate core functionality to what is clearly associated with Frontend actions. llvm-svn: 163050
* libclang, examples: [CMake] Add dependencies to tblgen'd headers.NAKAMURA Takumi2012-07-272-0/+18
| | | | llvm-svn: 160849
* Remove a goofy CMake hack and use the standard CMake facilities toChandler Carruth2012-06-213-37/+40
| | | | | | | | | express library-level dependencies within Clang. This is no more verbose really, and plays nicer with the rest of the CMake facilities. It should also have no change in functionality. llvm-svn: 158888
* Honour CLANG_BUILD_EXAMPLES correctly, by setting the directory'sPeter Collingbourne2012-05-031-1/+1
| | | | | | EXCLUDE_FROM_ALL property. llvm-svn: 156090
* Reverted unintentional commit.Manuel Klimek2012-04-261-2/+1
| | | | llvm-svn: 155629
* Adds a small tutorial on how to write RAV based ASTFrontendActions.Manuel Klimek2012-04-261-1/+2
| | | | llvm-svn: 155627
* Remove clangIndex reference from clang-interpreter CMake buildDouglas Gregor2012-04-131-1/+0
| | | | llvm-svn: 154674
* clang-interpreter/Makefile: [PR12313] Update USEDLIBS to add clangEdit.NAKAMURA Takumi2012-03-211-1/+2
| | | | llvm-svn: 153167
* Remove clang-wpa example, which has been unmaintained for quite a while.Douglas Gregor2012-03-143-233/+0
| | | | llvm-svn: 152729
* Unify naming of LangOptions variable/get function across the Clang stack ↵David Blaikie2012-03-111-4/+4
| | | | | | | | | | (Lex to AST). The member variable is always "LangOpts" and the member function is always "getLangOpts". Reviewed by Chris Lattner llvm-svn: 152536
* [analyzer] Rename clang::CallGraph into clang::idx::CallGraph + renameAnna Zaks2012-03-021-3/+3
| | | | | | | | | | | | | the corresponding files to avoid confusion. This is a preparation to adding an AST-based call graph to Analysis. The existing call graph works with indexer entries. We might be able to refactor it to use the AST based graph in the future. (Minimal testing here as the only example that uses the API has been completely broken, does not compile.) llvm-svn: 151950
* Basic: import IntrusiveRefCntPtr<> into clang namespaceDylan Noblesmith2012-02-202-2/+2
| | | | | | | The class name is long enough without the llvm:: added. Also bring in RefCountedBase and RefCountedBaseVPTR. llvm-svn: 150958
* drop more llvm:: prefixes on SmallString<>Dylan Noblesmith2012-02-131-1/+1
| | | | | | More cleanup after r149799. llvm-svn: 150380
* drop more llvm:: prefixes on OwningPtr<>Dylan Noblesmith2012-02-133-8/+8
| | | | | | More cleanup after r149798. llvm-svn: 150379
* examples/analyzer-plugin: hook up to buildDylan Noblesmith2012-02-134-3/+4
| | | | | | | | | | | This was never being compiled at all and was bitrotting as a result. Also compile SampleAnalyzerPlugin as a module, not a library, and fix a mistake with not passing the source files to add_clang_library(). llvm-svn: 150378
* examples/analyzer-plugin/: unbreak buildDylan Noblesmith2012-02-091-2/+3
| | | | | | | It was never updated for API changes in r149311/r149336/r149339 and r147688. llvm-svn: 150202
* Adjust CLANG_BUILD_EXAMPLES to mean whether the examples are builtPeter Collingbourne2012-01-261-0/+4
| | | | | | by default, rather than whether they may be built at all. llvm-svn: 149037
* remove unneeded config.h includesDylan Noblesmith2011-12-221-2/+0
| | | | llvm-svn: 147195
OpenPOWER on IntegriCloud