summaryrefslogtreecommitdiffstats
path: root/examples
Commit message (Collapse)AuthorAgeFilesLines
* Remove clangIndex reference from clang-interpreter CMake buildDouglas Gregor2012-04-131-1/+0
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@154674 91177308-0d34-0410-b5e6-96231b3b80d8
* clang-interpreter/Makefile: [PR12313] Update USEDLIBS to add clangEdit.NAKAMURA Takumi2012-03-211-1/+2
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@153167 91177308-0d34-0410-b5e6-96231b3b80d8
* Remove clang-wpa example, which has been unmaintained for quite a while.Douglas Gregor2012-03-143-233/+0
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@152729 91177308-0d34-0410-b5e6-96231b3b80d8
* 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 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@152536 91177308-0d34-0410-b5e6-96231b3b80d8
* [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.) git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@151950 91177308-0d34-0410-b5e6-96231b3b80d8
* 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. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@150958 91177308-0d34-0410-b5e6-96231b3b80d8
* drop more llvm:: prefixes on SmallString<>Dylan Noblesmith2012-02-131-1/+1
| | | | | | More cleanup after r149799. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@150380 91177308-0d34-0410-b5e6-96231b3b80d8
* drop more llvm:: prefixes on OwningPtr<>Dylan Noblesmith2012-02-133-8/+8
| | | | | | More cleanup after r149798. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@150379 91177308-0d34-0410-b5e6-96231b3b80d8
* 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(). git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@150378 91177308-0d34-0410-b5e6-96231b3b80d8
* examples/analyzer-plugin/: unbreak buildDylan Noblesmith2012-02-091-2/+3
| | | | | | | It was never updated for API changes in r149311/r149336/r149339 and r147688. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@150202 91177308-0d34-0410-b5e6-96231b3b80d8
* 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. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@149037 91177308-0d34-0410-b5e6-96231b3b80d8
* remove unneeded config.h includesDylan Noblesmith2011-12-221-2/+0
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@147195 91177308-0d34-0410-b5e6-96231b3b80d8
* examples: flesh out PFN readmeDylan Noblesmith2011-12-181-0/+4
| | | | | | | Show how to actually use the arguments it has. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@146845 91177308-0d34-0410-b5e6-96231b3b80d8
* Update signature of HandleTopLevelDecl.Douglas Gregor2011-11-191-1/+3
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145001 91177308-0d34-0410-b5e6-96231b3b80d8
* rename getHostTriple into getDefaultTargetTriple in clangSebastian Pop2011-11-011-1/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@143503 91177308-0d34-0410-b5e6-96231b3b80d8
* Add support for lazily linking bitcode files (using a newPeter Collingbourne2011-10-302-1/+2
| | | | | | | -mlink-bitcode-file flag), and more generally llvm::Modules, before running optimisations. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@143314 91177308-0d34-0410-b5e6-96231b3b80d8
* Add missing include to clang-interpreter example, to make it work on ↵Eli Friedman2011-10-061-0/+1
| | | | | | Windows. Patch by Dean Pavlekovic. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@141324 91177308-0d34-0410-b5e6-96231b3b80d8
* Rip out flags for controlling C++ "production mode" separately.Bob Wilson2011-10-041-2/+1
| | | | | | | This is old leftover cruft from the days when C++ was not yet ready for prime time. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@141063 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix examples for r140478. PR11021.Eli Friedman2011-09-272-3/+3
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@140618 91177308-0d34-0410-b5e6-96231b3b80d8
* Match LLVM change: TargetRegistry and TargetSelect have been moved to Support.Evan Cheng2011-08-241-1/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@138451 91177308-0d34-0410-b5e6-96231b3b80d8
* Remove EnhancedBugReport and RangedBugReport - pull all the extra ↵Anna Zaks2011-08-171-1/+1
| | | | | | functionality they provided into their parent BugReport. The only functional changes are: made getRanges() non const - it adds default range to Ranges if none are supplied, made getStmt() private, which was another FIXME. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@137894 91177308-0d34-0410-b5e6-96231b3b80d8
* Don't use BuiltinBug in analyzer plugin example.Jordy Rose2011-08-171-1/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@137811 91177308-0d34-0410-b5e6-96231b3b80d8
* [analyzer] Add basic support for pluggable checkers.Jordy Rose2011-08-173-0/+86
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@137802 91177308-0d34-0410-b5e6-96231b3b80d8
* Reverts the Tooling changes as requested by Chris.Manuel Klimek2011-06-029-389/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@132462 91177308-0d34-0410-b5e6-96231b3b80d8
* Fixes Makefile based build for examples/Tooling.Manuel Klimek2011-06-013-3/+28
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@132380 91177308-0d34-0410-b5e6-96231b3b80d8
* Put Parse before Sema on the link line since parse depends on sema.Nick Lewycky2011-06-011-2/+3
| | | | | | | Also reflow these lines to fit in 80-col. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@132379 91177308-0d34-0410-b5e6-96231b3b80d8
* This patch implements an AST matching framework that allows to writeManuel Klimek2011-05-314-0/+285
| | | | | | | | | | | tools that match on the C++ ASTs. The main interface is in ASTMatchers.h, an example implementation of a tool that removes redundant .c_str() calls is in the example RemoveCStrCalls.cpp. Various contributions: Zhanyong Wan, Chandler Carruth, Marcin Kowalczyk, Wei Xu, James Dennett. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@132374 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix linking of clang-wpa.Zhongxing Xu2011-05-311-3/+6
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@132329 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix examples compile break due to rewrite of isa.Manuel Klimek2011-05-231-1/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@131912 91177308-0d34-0410-b5e6-96231b3b80d8
* Pulls the common part of the clang-check example into Tooling, to allow new ↵Manuel Klimek2011-05-161-73/+6
| | | | | | tools to be implemented without duplicating the boilerplate. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@131425 91177308-0d34-0410-b5e6-96231b3b80d8
* Let clang-check actually use the Directory entry in the json file.Nico Weber2011-05-141-0/+6
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@131367 91177308-0d34-0410-b5e6-96231b3b80d8
* Fixes compilation with Visual Studio by replacing the non-standard ↵Manuel Klimek2011-05-101-2/+2
| | | | | | vector::data() access. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@131116 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix gcc 'warning: multi-line comment'.Nico Weber2011-04-301-2/+2
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@130583 91177308-0d34-0410-b5e6-96231b3b80d8
* Add a Makefile to examples/Tooling for people who do not use cmake.Nico Weber2011-04-301-0/+24
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@130577 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix Makefile build of examples/clang-interpreter.Nico Weber2011-04-301-1/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@130576 91177308-0d34-0410-b5e6-96231b3b80d8
* This is the next step in building the standalone tools infrastructure:Manuel Klimek2011-04-273-1/+115
| | | | | | | | | | | | | | | This patch simplifies writing of standalone Clang tools. As an example, we add clang-check, a tool that runs a syntax only frontend action over a .cc file. When you integrate this into your favorite editor, you get much faster feedback on your compilation errors, thus reducing your feedback cycle especially when writing new code. The tool depends on integration of an outstanding patch to CMake to work which allows you to always have a current compile command database in your cmake output directory when you set CMAKE_EXPORT_COMPILE_COMMANDS. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@130306 91177308-0d34-0410-b5e6-96231b3b80d8
* Fixed build error.John Thompson2011-03-291-2/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@128470 91177308-0d34-0410-b5e6-96231b3b80d8
* [analyzer] Add LangOptions in CheckerManager.Argyrios Kyrtzidis2011-02-231-1/+2
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@126306 91177308-0d34-0410-b5e6-96231b3b80d8
* Re-instate r125819 and r125820 with no functionality changePeter Collingbourne2011-02-192-26/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@126060 91177308-0d34-0410-b5e6-96231b3b80d8
* Revert 125820 and 125819 to fix PR9266.Rafael Espindola2011-02-192-1/+26
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@126050 91177308-0d34-0410-b5e6-96231b3b80d8
* Move CompilerInstance::LLVMContext and LLVMContext ownership to CodeGenActionPeter Collingbourne2011-02-182-26/+1
| | | | | | | | | This removes the final dependency edge from any lib outside of CodeGen to core. As a result we can, and do, trim the dependency on core from libclang, PrintFunctionNames, the unit tests and c-index-test. While at it, review and trim other unneeded dependencies. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@125820 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix the clang-wpa example.Argyrios Kyrtzidis2011-02-151-10/+34
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@125565 91177308-0d34-0410-b5e6-96231b3b80d8
* [analyzer] Introduce libclangStaticAnalyzerFrontend and move ↵Argyrios Kyrtzidis2011-02-145-2/+5
| | | | | | Checkers/AnalysisConsumer.cpp into Frontend lib. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@125499 91177308-0d34-0410-b5e6-96231b3b80d8
* CMake: LLVM_NO_RTTI must be obsolete now!NAKAMURA Takumi2011-02-103-6/+0
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@125275 91177308-0d34-0410-b5e6-96231b3b80d8
* Split 'include/clang/StaticAnalyzer' into ↵Ted Kremenek2011-02-101-3/+3
| | | | | | | | 'include/clang/StaticAnalyzer/Core' and 'include/clang/StaticAnalyzer/Checkers'. This layout matches lib/StaticAnalyzer, which corresponds to two StaticAnalyzer libraries. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@125251 91177308-0d34-0410-b5e6-96231b3b80d8
* Update clang-wpa to pass extra argument to AnalysisManager constructor.Ted Kremenek2011-02-091-1/+2
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@125235 91177308-0d34-0410-b5e6-96231b3b80d8
* make `make` work in examples/PrintFucntionNames on Mac. I checked that it ↵Nico Weber2011-01-262-5/+11
| | | | | | still works on Linux. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@124325 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix name to match reality.Nick Lewycky2011-01-191-1/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@123813 91177308-0d34-0410-b5e6-96231b3b80d8
* Get clang-wpa to build in TOT (reflecting updatesTed Kremenek2011-01-181-6/+11
| | | | | | to the static analyzer). git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@123727 91177308-0d34-0410-b5e6-96231b3b80d8
* Chris Lattner has strong opinions about directoryTed Kremenek2010-12-235-8/+8
| | | | | | | | | | | | layout. :) Rename the 'EntoSA' directories to 'StaticAnalyzer'. Internally we will still use the 'ento' namespace for the analyzer engine (unless there are further sabre rattlings...). git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@122514 91177308-0d34-0410-b5e6-96231b3b80d8