svn commit: r202879 - in vendor/clang/dist: clang.xcodeproj
include/clang-c include/clang/AST include/clang/Analysis
include/clang/Analysis/PathSensitive include/clang/Basic
include/clang/Driver in...
Roman Divacky
rdivacky at FreeBSD.org
Sat Jan 23 11:10:27 UTC 2010
Author: rdivacky
Date: Sat Jan 23 11:10:26 2010
New Revision: 202879
URL: http://svn.freebsd.org/changeset/base/202879
Log:
Update clang to r94309.
Added:
vendor/clang/dist/include/clang/AST/UnresolvedSet.h
vendor/clang/dist/include/clang/Basic/MacroBuilder.h
vendor/clang/dist/include/clang/Basic/Specifiers.h
vendor/clang/dist/lib/CodeGen/CGVTT.cpp
vendor/clang/dist/test/CXX/class.access/class.access.base/p1.cpp
vendor/clang/dist/test/CodeCompletion/call.c
vendor/clang/dist/test/CodeGenCXX/vtt-layout.cpp
vendor/clang/dist/test/Index/Inputs/remap-load-to.c
vendor/clang/dist/test/Index/load-exprs.c
vendor/clang/dist/test/Index/remap-cursor-at.c
vendor/clang/dist/test/Index/remap-load.c
vendor/clang/dist/test/PCH/cxx_exprs.cpp
vendor/clang/dist/test/PCH/cxx_exprs.h
vendor/clang/dist/test/Rewriter/rewrite-extern-c.mm
vendor/clang/dist/test/Rewriter/rewrite-typeof.mm
vendor/clang/dist/test/SemaCXX/warn-unreachable.cpp
vendor/clang/dist/test/SemaObjC/method-unused-attribute.m
vendor/clang/dist/test/SemaObjC/property-category-impl.m
vendor/clang/dist/test/SemaObjC/unimplemented-protocol-prop.m
vendor/clang/dist/test/SemaObjCXX/cstyle-block-pointer-cast.mm
vendor/clang/dist/test/SemaObjCXX/pointer-to-objc-pointer-conv.mm
vendor/clang/dist/test/SemaTemplate/instantiate-local-class.cpp
vendor/clang/dist/tools/CIndex/CXCursor.cpp
vendor/clang/dist/tools/CIndex/CXCursor.h
vendor/clang/dist/utils/OptionalTests/
vendor/clang/dist/utils/OptionalTests/Extra/
vendor/clang/dist/utils/OptionalTests/Extra/README.txt
vendor/clang/dist/utils/OptionalTests/Extra/Runtime/
vendor/clang/dist/utils/OptionalTests/Extra/Runtime/darwin-clang_rt.c
vendor/clang/dist/utils/OptionalTests/README.txt
vendor/clang/dist/utils/OptionalTests/lit.cfg
Deleted:
vendor/clang/dist/include/clang/Parse/AccessSpecifier.h
vendor/clang/dist/lib/CodeGen/TargetABIInfo.cpp
vendor/clang/dist/test/Analysis/NSString-failed-cases.m
vendor/clang/dist/test/Driver/darwin-arm.c
vendor/clang/dist/test/Index/c-index-api-fn-scan.m
vendor/clang/dist/test/Index/comments.c
vendor/clang/dist/test/Index/find-decls.c
vendor/clang/dist/test/Index/find-defs.c
vendor/clang/dist/test/Index/find-refs.c
vendor/clang/dist/test/Index/multiple-redecls.c
vendor/clang/dist/test/Index/objc-decls.m
vendor/clang/dist/test/Index/objc-message.m
vendor/clang/dist/test/Index/resolve-loc.c
vendor/clang/dist/test/Preprocessor/foo.framework/
vendor/clang/dist/test/Preprocessor/framework-include.m
Modified:
vendor/clang/dist/clang.xcodeproj/project.pbxproj
vendor/clang/dist/include/clang-c/Index.h
vendor/clang/dist/include/clang/AST/ASTContext.h
vendor/clang/dist/include/clang/AST/CXXInheritance.h
vendor/clang/dist/include/clang/AST/Decl.h
vendor/clang/dist/include/clang/AST/DeclBase.h
vendor/clang/dist/include/clang/AST/DeclCXX.h
vendor/clang/dist/include/clang/AST/DeclObjC.h
vendor/clang/dist/include/clang/AST/Expr.h
vendor/clang/dist/include/clang/AST/ExprCXX.h
vendor/clang/dist/include/clang/AST/Type.h
vendor/clang/dist/include/clang/AST/TypeLoc.h
vendor/clang/dist/include/clang/AST/TypeLocVisitor.h
vendor/clang/dist/include/clang/Analysis/CFG.h
vendor/clang/dist/include/clang/Analysis/PathSensitive/AnalysisContext.h
vendor/clang/dist/include/clang/Analysis/PathSensitive/CheckerVisitor.h
vendor/clang/dist/include/clang/Analysis/PathSensitive/GRExprEngine.h
vendor/clang/dist/include/clang/Analysis/PathSensitive/Store.h
vendor/clang/dist/include/clang/Basic/Builtins.def
vendor/clang/dist/include/clang/Basic/BuiltinsX86.def
vendor/clang/dist/include/clang/Basic/DiagnosticDriverKinds.td
vendor/clang/dist/include/clang/Basic/DiagnosticLexKinds.td
vendor/clang/dist/include/clang/Basic/DiagnosticSemaKinds.td
vendor/clang/dist/include/clang/Basic/Makefile
vendor/clang/dist/include/clang/Basic/Version.h
vendor/clang/dist/include/clang/Driver/Driver.h
vendor/clang/dist/include/clang/Frontend/ASTUnit.h
vendor/clang/dist/include/clang/Frontend/PCHBitCodes.h
vendor/clang/dist/include/clang/Frontend/PreprocessorOptions.h
vendor/clang/dist/include/clang/Frontend/Utils.h
vendor/clang/dist/include/clang/Lex/Preprocessor.h
vendor/clang/dist/include/clang/Parse/Action.h
vendor/clang/dist/include/clang/Parse/DeclSpec.h
vendor/clang/dist/include/clang/Parse/Parser.h
vendor/clang/dist/include/clang/Rewrite/DeltaTree.h
vendor/clang/dist/lib/AST/ASTContext.cpp
vendor/clang/dist/lib/AST/CXXInheritance.cpp
vendor/clang/dist/lib/AST/Decl.cpp
vendor/clang/dist/lib/AST/DeclBase.cpp
vendor/clang/dist/lib/AST/DeclCXX.cpp
vendor/clang/dist/lib/AST/DeclObjC.cpp
vendor/clang/dist/lib/AST/Expr.cpp
vendor/clang/dist/lib/AST/ExprCXX.cpp
vendor/clang/dist/lib/AST/ExprConstant.cpp
vendor/clang/dist/lib/AST/RecordLayoutBuilder.cpp
vendor/clang/dist/lib/AST/Type.cpp
vendor/clang/dist/lib/AST/TypeLoc.cpp
vendor/clang/dist/lib/Analysis/AnalysisContext.cpp
vendor/clang/dist/lib/Analysis/ArrayBoundChecker.cpp
vendor/clang/dist/lib/Analysis/CFG.cpp
vendor/clang/dist/lib/Analysis/CastToStructChecker.cpp
vendor/clang/dist/lib/Analysis/GRExprEngine.cpp
vendor/clang/dist/lib/Analysis/MallocChecker.cpp
vendor/clang/dist/lib/Analysis/RegionStore.cpp
vendor/clang/dist/lib/Analysis/ReturnPointerRangeChecker.cpp
vendor/clang/dist/lib/Basic/Makefile
vendor/clang/dist/lib/Basic/Targets.cpp
vendor/clang/dist/lib/Basic/Version.cpp
vendor/clang/dist/lib/CodeGen/CGBlocks.cpp
vendor/clang/dist/lib/CodeGen/CGBuiltin.cpp
vendor/clang/dist/lib/CodeGen/CGClass.cpp
vendor/clang/dist/lib/CodeGen/CGDebugInfo.cpp
vendor/clang/dist/lib/CodeGen/CGDebugInfo.h
vendor/clang/dist/lib/CodeGen/CGExprConstant.cpp
vendor/clang/dist/lib/CodeGen/CGObjC.cpp
vendor/clang/dist/lib/CodeGen/CGObjCGNU.cpp
vendor/clang/dist/lib/CodeGen/CGObjCMac.cpp
vendor/clang/dist/lib/CodeGen/CGObjCRuntime.h
vendor/clang/dist/lib/CodeGen/CGVtable.cpp
vendor/clang/dist/lib/CodeGen/CMakeLists.txt
vendor/clang/dist/lib/CodeGen/CodeGenModule.cpp
vendor/clang/dist/lib/CodeGen/CodeGenModule.h
vendor/clang/dist/lib/CodeGen/TargetInfo.cpp
vendor/clang/dist/lib/CodeGen/TargetInfo.h
vendor/clang/dist/lib/Driver/Driver.cpp
vendor/clang/dist/lib/Driver/Makefile
vendor/clang/dist/lib/Driver/ToolChains.cpp
vendor/clang/dist/lib/Driver/ToolChains.h
vendor/clang/dist/lib/Driver/Tools.cpp
vendor/clang/dist/lib/Driver/Tools.h
vendor/clang/dist/lib/Frontend/ASTConsumers.cpp
vendor/clang/dist/lib/Frontend/ASTUnit.cpp
vendor/clang/dist/lib/Frontend/AnalysisConsumer.cpp
vendor/clang/dist/lib/Frontend/CacheTokens.cpp
vendor/clang/dist/lib/Frontend/DeclXML.cpp
vendor/clang/dist/lib/Frontend/HTMLDiagnostics.cpp
vendor/clang/dist/lib/Frontend/InitHeaderSearch.cpp
vendor/clang/dist/lib/Frontend/InitPreprocessor.cpp
vendor/clang/dist/lib/Frontend/PCHReader.cpp
vendor/clang/dist/lib/Frontend/PCHReaderDecl.cpp
vendor/clang/dist/lib/Frontend/PCHReaderStmt.cpp
vendor/clang/dist/lib/Frontend/PCHWriter.cpp
vendor/clang/dist/lib/Frontend/PCHWriterDecl.cpp
vendor/clang/dist/lib/Frontend/PCHWriterStmt.cpp
vendor/clang/dist/lib/Frontend/PlistDiagnostics.cpp
vendor/clang/dist/lib/Frontend/PrintParserCallbacks.cpp
vendor/clang/dist/lib/Frontend/PrintPreprocessedOutput.cpp
vendor/clang/dist/lib/Frontend/RewriteObjC.cpp
vendor/clang/dist/lib/Frontend/StmtXML.cpp
vendor/clang/dist/lib/Frontend/TextDiagnosticPrinter.cpp
vendor/clang/dist/lib/Frontend/TypeXML.cpp
vendor/clang/dist/lib/Index/ResolveLocation.cpp
vendor/clang/dist/lib/Lex/Lexer.cpp
vendor/clang/dist/lib/Lex/LiteralSupport.cpp
vendor/clang/dist/lib/Lex/PPDirectives.cpp
vendor/clang/dist/lib/Lex/PPMacroExpansion.cpp
vendor/clang/dist/lib/Lex/Pragma.cpp
vendor/clang/dist/lib/Lex/Preprocessor.cpp
vendor/clang/dist/lib/Makefile
vendor/clang/dist/lib/Parse/DeclSpec.cpp
vendor/clang/dist/lib/Parse/MinimalAction.cpp
vendor/clang/dist/lib/Parse/ParseDeclCXX.cpp
vendor/clang/dist/lib/Parse/ParseObjc.cpp
vendor/clang/dist/lib/Parse/Parser.cpp
vendor/clang/dist/lib/Rewrite/DeltaTree.cpp
vendor/clang/dist/lib/Sema/CodeCompleteConsumer.cpp
vendor/clang/dist/lib/Sema/Lookup.h
vendor/clang/dist/lib/Sema/Sema.h
vendor/clang/dist/lib/Sema/SemaAccess.cpp
vendor/clang/dist/lib/Sema/SemaCXXCast.cpp
vendor/clang/dist/lib/Sema/SemaCXXScopeSpec.cpp
vendor/clang/dist/lib/Sema/SemaChecking.cpp
vendor/clang/dist/lib/Sema/SemaCodeComplete.cpp
vendor/clang/dist/lib/Sema/SemaDecl.cpp
vendor/clang/dist/lib/Sema/SemaDeclCXX.cpp
vendor/clang/dist/lib/Sema/SemaDeclObjC.cpp
vendor/clang/dist/lib/Sema/SemaExpr.cpp
vendor/clang/dist/lib/Sema/SemaExprCXX.cpp
vendor/clang/dist/lib/Sema/SemaExprObjC.cpp
vendor/clang/dist/lib/Sema/SemaInit.cpp
vendor/clang/dist/lib/Sema/SemaInit.h
vendor/clang/dist/lib/Sema/SemaLookup.cpp
vendor/clang/dist/lib/Sema/SemaOverload.cpp
vendor/clang/dist/lib/Sema/SemaOverload.h
vendor/clang/dist/lib/Sema/SemaStmt.cpp
vendor/clang/dist/lib/Sema/SemaTemplate.cpp
vendor/clang/dist/lib/Sema/SemaTemplateInstantiateDecl.cpp
vendor/clang/dist/lib/Sema/SemaType.cpp
vendor/clang/dist/lib/Sema/TreeTransform.h
vendor/clang/dist/test/Analysis/malloc.c
vendor/clang/dist/test/Analysis/misc-ps.m
vendor/clang/dist/test/Analysis/outofbound.c
vendor/clang/dist/test/CodeGen/2009-10-20-GlobalDebug.c
vendor/clang/dist/test/CodeGenCXX/copy-assign-synthesis-3.cpp
vendor/clang/dist/test/CodeGenCXX/debug-info.cpp
vendor/clang/dist/test/CodeGenCXX/member-function-pointers.cpp
vendor/clang/dist/test/CodeGenCXX/temp-order.cpp
vendor/clang/dist/test/CodeGenCXX/virt.cpp
vendor/clang/dist/test/FixIt/typo.m
vendor/clang/dist/test/Index/TestClassDecl.m
vendor/clang/dist/test/Index/TestClassForwardDecl.m
vendor/clang/dist/test/Index/c-index-api-loadTU-test.m
vendor/clang/dist/test/Index/c-index-getCursor-test.m
vendor/clang/dist/test/Index/cindex-from-source.m
vendor/clang/dist/test/Lexer/constants-ms.c
vendor/clang/dist/test/Misc/tabstop.c
vendor/clang/dist/test/Rewriter/rewrite-byref-vars.mm
vendor/clang/dist/test/Rewriter/rewrite-protocol-type-1.m
vendor/clang/dist/test/Sema/block-literal.c
vendor/clang/dist/test/Sema/block-misc.c
vendor/clang/dist/test/Sema/compound-literal.c
vendor/clang/dist/test/Sema/scope-check.c
vendor/clang/dist/test/Sema/warn-unreachable.c
vendor/clang/dist/test/SemaCXX/access-control-check.cpp
vendor/clang/dist/test/SemaCXX/anonymous-union.cpp
vendor/clang/dist/test/SemaCXX/enum.cpp
vendor/clang/dist/test/SemaCXX/new-delete.cpp
vendor/clang/dist/test/SemaCXX/overload-call.cpp
vendor/clang/dist/test/SemaCXX/unused.cpp
vendor/clang/dist/test/SemaCXX/virtual-override.cpp
vendor/clang/dist/test/SemaObjC/property-category-2.m
vendor/clang/dist/test/SemaObjC/property-user-setter.m
vendor/clang/dist/test/SemaObjC/property.m
vendor/clang/dist/test/SemaObjC/super.m
vendor/clang/dist/test/SemaTemplate/dependent-base-classes.cpp
vendor/clang/dist/test/SemaTemplate/dependent-base-member-init.cpp
vendor/clang/dist/test/SemaTemplate/dependent-expr.cpp
vendor/clang/dist/test/SemaTemplate/friend-template.cpp
vendor/clang/dist/test/SemaTemplate/member-template-access-expr.cpp
vendor/clang/dist/tools/CIndex/CIndex.cpp
vendor/clang/dist/tools/CIndex/CIndex.exports
vendor/clang/dist/tools/CIndex/CIndexCodeCompletion.cpp
vendor/clang/dist/tools/CIndex/CIndexUSRs.cpp
vendor/clang/dist/tools/CIndex/CIndexer.cpp
vendor/clang/dist/tools/CIndex/CIndexer.h
vendor/clang/dist/tools/CIndex/CMakeLists.txt
vendor/clang/dist/tools/CIndex/Makefile
vendor/clang/dist/tools/CMakeLists.txt
vendor/clang/dist/tools/Makefile
vendor/clang/dist/tools/c-index-test/c-index-test.c
vendor/clang/dist/tools/driver/CMakeLists.txt
vendor/clang/dist/tools/driver/Makefile
vendor/clang/dist/www/analyzer/scan-build.html
vendor/clang/dist/www/hacking.html
Modified: vendor/clang/dist/clang.xcodeproj/project.pbxproj
==============================================================================
--- vendor/clang/dist/clang.xcodeproj/project.pbxproj Sat Jan 23 11:09:33 2010 (r202878)
+++ vendor/clang/dist/clang.xcodeproj/project.pbxproj Sat Jan 23 11:10:26 2010 (r202879)
@@ -21,7 +21,6 @@
1A2A54BD0FD1DD1C00F4CE45 /* HTMLPrint.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A2A54AC0FD1DD1C00F4CE45 /* HTMLPrint.cpp */; };
1A2A54BE0FD1DD1C00F4CE45 /* PrintParserCallbacks.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A2A54AD0FD1DD1C00F4CE45 /* PrintParserCallbacks.cpp */; };
1A2A54BF0FD1DD1C00F4CE45 /* PrintPreprocessedOutput.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A2A54AE0FD1DD1C00F4CE45 /* PrintPreprocessedOutput.cpp */; };
- 1A2A54C00FD1DD1C00F4CE45 /* RewriteBlocks.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A2A54AF0FD1DD1C00F4CE45 /* RewriteBlocks.cpp */; };
1A2A54C10FD1DD1C00F4CE45 /* RewriteMacros.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A2A54B00FD1DD1C00F4CE45 /* RewriteMacros.cpp */; };
1A2A54C20FD1DD1C00F4CE45 /* RewriteObjC.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A2A54B10FD1DD1C00F4CE45 /* RewriteObjC.cpp */; };
1A2A54C30FD1DD1C00F4CE45 /* RewriteTest.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A2A54B20FD1DD1C00F4CE45 /* RewriteTest.cpp */; };
@@ -44,10 +43,20 @@
1A81AA19108144F40094E50B /* CGVtable.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A81AA18108144F40094E50B /* CGVtable.cpp */; };
1A869A700BA2164C008DA07A /* LiteralSupport.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = 1A869A6E0BA2164C008DA07A /* LiteralSupport.h */; };
1A869AA80BA21ABA008DA07A /* LiteralSupport.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A869AA70BA21ABA008DA07A /* LiteralSupport.cpp */; };
+ 1A97825B1108BA18002B98FC /* CGVTT.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A97825A1108BA18002B98FC /* CGVTT.cpp */; };
1A986AB710D0746D00A8EA9E /* CGDeclCXX.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A986AB610D0746D00A8EA9E /* CGDeclCXX.cpp */; };
1AA1D91810125DE30078DEBC /* RecordLayoutBuilder.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1AA1D91610125DE30078DEBC /* RecordLayoutBuilder.cpp */; };
1AA963C410D85A7300786C86 /* FullExpr.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1AA963C310D85A7300786C86 /* FullExpr.cpp */; };
1ABC36940C7A4BDC006DB0AB /* CGBuiltin.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1ABC36930C7A4BDC006DB0AB /* CGBuiltin.cpp */; };
+ 1ACB57E41105820D0047B991 /* CompilerInstance.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1ACB57DB1105820D0047B991 /* CompilerInstance.cpp */; };
+ 1ACB57E51105820D0047B991 /* CompilerInvocation.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1ACB57DC1105820D0047B991 /* CompilerInvocation.cpp */; };
+ 1ACB57E61105820D0047B991 /* DeclXML.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1ACB57DD1105820D0047B991 /* DeclXML.cpp */; };
+ 1ACB57E71105820D0047B991 /* FrontendAction.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1ACB57DE1105820D0047B991 /* FrontendAction.cpp */; };
+ 1ACB57E81105820D0047B991 /* FrontendActions.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1ACB57DF1105820D0047B991 /* FrontendActions.cpp */; };
+ 1ACB57E91105820D0047B991 /* FrontendOptions.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1ACB57E01105820D0047B991 /* FrontendOptions.cpp */; };
+ 1ACB57EA1105820D0047B991 /* LangStandards.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1ACB57E11105820D0047B991 /* LangStandards.cpp */; };
+ 1ACB57EB1105820D0047B991 /* TypeXML.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1ACB57E21105820D0047B991 /* TypeXML.cpp */; };
+ 1ACB57EC1105820D0047B991 /* VerifyDiagnosticsClient.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1ACB57E31105820D0047B991 /* VerifyDiagnosticsClient.cpp */; };
1ADD795410A90C6100741BBA /* TypePrinter.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1ADD795110A90C6100741BBA /* TypePrinter.cpp */; };
1ADD795510A90C6100741BBA /* TypeLoc.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1ADD795210A90C6100741BBA /* TypeLoc.cpp */; };
1ADD795610A90C6100741BBA /* TemplateBase.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1ADD795310A90C6100741BBA /* TemplateBase.cpp */; };
@@ -59,7 +68,6 @@
3507E4C20E27FE2D00FB7B57 /* CheckObjCInstMethSignature.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 3507E4C10E27FE2D00FB7B57 /* CheckObjCInstMethSignature.cpp */; };
352246E70F5C6BE000D0D279 /* HTMLDiagnostics.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 352246E10F5C6BE000D0D279 /* HTMLDiagnostics.cpp */; };
352246E80F5C6BE000D0D279 /* InitHeaderSearch.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 352246E20F5C6BE000D0D279 /* InitHeaderSearch.cpp */; };
- 352246E90F5C6BE000D0D279 /* ManagerRegistry.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 352246E30F5C6BE000D0D279 /* ManagerRegistry.cpp */; };
352246EA0F5C6BE000D0D279 /* PlistDiagnostics.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 352246E40F5C6BE000D0D279 /* PlistDiagnostics.cpp */; };
352246EB0F5C6BE000D0D279 /* TextDiagnosticBuffer.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 352246E50F5C6BE000D0D279 /* TextDiagnosticBuffer.cpp */; };
352246EC0F5C6BE000D0D279 /* TextDiagnosticPrinter.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 352246E60F5C6BE000D0D279 /* TextDiagnosticPrinter.cpp */; };
@@ -360,7 +368,6 @@
1A2A54AC0FD1DD1C00F4CE45 /* HTMLPrint.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = HTMLPrint.cpp; path = lib/Frontend/HTMLPrint.cpp; sourceTree = "<group>"; };
1A2A54AD0FD1DD1C00F4CE45 /* PrintParserCallbacks.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = PrintParserCallbacks.cpp; path = lib/Frontend/PrintParserCallbacks.cpp; sourceTree = "<group>"; };
1A2A54AE0FD1DD1C00F4CE45 /* PrintPreprocessedOutput.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = PrintPreprocessedOutput.cpp; path = lib/Frontend/PrintPreprocessedOutput.cpp; sourceTree = "<group>"; };
- 1A2A54AF0FD1DD1C00F4CE45 /* RewriteBlocks.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = RewriteBlocks.cpp; path = lib/Frontend/RewriteBlocks.cpp; sourceTree = "<group>"; };
1A2A54B00FD1DD1C00F4CE45 /* RewriteMacros.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = RewriteMacros.cpp; path = lib/Frontend/RewriteMacros.cpp; sourceTree = "<group>"; };
1A2A54B10FD1DD1C00F4CE45 /* RewriteObjC.cpp */ = {isa = PBXFileReference; fileEncoding = 4; indentWidth = 2; lastKnownFileType = sourcecode.cpp.cpp; name = RewriteObjC.cpp; path = lib/Frontend/RewriteObjC.cpp; sourceTree = "<group>"; tabWidth = 2; };
1A2A54B20FD1DD1C00F4CE45 /* RewriteTest.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = RewriteTest.cpp; path = lib/Frontend/RewriteTest.cpp; sourceTree = "<group>"; };
@@ -398,6 +405,7 @@
1A81AA5D108278A20094E50B /* CGVtable.h */ = {isa = PBXFileReference; fileEncoding = 4; indentWidth = 2; lastKnownFileType = sourcecode.c.h; name = CGVtable.h; path = lib/CodeGen/CGVtable.h; sourceTree = "<group>"; tabWidth = 2; };
1A869A6E0BA2164C008DA07A /* LiteralSupport.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = LiteralSupport.h; sourceTree = "<group>"; };
1A869AA70BA21ABA008DA07A /* LiteralSupport.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = LiteralSupport.cpp; sourceTree = "<group>"; };
+ 1A97825A1108BA18002B98FC /* CGVTT.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = CGVTT.cpp; path = lib/CodeGen/CGVTT.cpp; sourceTree = "<group>"; };
1A986AB610D0746D00A8EA9E /* CGDeclCXX.cpp */ = {isa = PBXFileReference; fileEncoding = 4; indentWidth = 2; lastKnownFileType = sourcecode.cpp.cpp; name = CGDeclCXX.cpp; path = lib/CodeGen/CGDeclCXX.cpp; sourceTree = "<group>"; tabWidth = 2; };
1AA1D91610125DE30078DEBC /* RecordLayoutBuilder.cpp */ = {isa = PBXFileReference; fileEncoding = 4; indentWidth = 2; lastKnownFileType = sourcecode.cpp.cpp; name = RecordLayoutBuilder.cpp; path = lib/AST/RecordLayoutBuilder.cpp; sourceTree = "<group>"; tabWidth = 2; };
1AA1D91710125DE30078DEBC /* RecordLayoutBuilder.h */ = {isa = PBXFileReference; fileEncoding = 4; indentWidth = 2; lastKnownFileType = sourcecode.c.h; name = RecordLayoutBuilder.h; path = lib/AST/RecordLayoutBuilder.h; sourceTree = "<group>"; tabWidth = 2; };
@@ -405,6 +413,15 @@
1AA963C310D85A7300786C86 /* FullExpr.cpp */ = {isa = PBXFileReference; fileEncoding = 4; indentWidth = 2; lastKnownFileType = sourcecode.cpp.cpp; name = FullExpr.cpp; path = lib/AST/FullExpr.cpp; sourceTree = "<group>"; tabWidth = 2; };
1AB290021045858B00FE33D8 /* PartialDiagnostic.h */ = {isa = PBXFileReference; fileEncoding = 4; indentWidth = 2; lastKnownFileType = sourcecode.c.h; path = PartialDiagnostic.h; sourceTree = "<group>"; tabWidth = 2; };
1ABC36930C7A4BDC006DB0AB /* CGBuiltin.cpp */ = {isa = PBXFileReference; fileEncoding = 4; indentWidth = 2; lastKnownFileType = sourcecode.cpp.cpp; name = CGBuiltin.cpp; path = lib/CodeGen/CGBuiltin.cpp; sourceTree = "<group>"; tabWidth = 2; };
+ 1ACB57DB1105820D0047B991 /* CompilerInstance.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = CompilerInstance.cpp; path = lib/Frontend/CompilerInstance.cpp; sourceTree = "<group>"; };
+ 1ACB57DC1105820D0047B991 /* CompilerInvocation.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = CompilerInvocation.cpp; path = lib/Frontend/CompilerInvocation.cpp; sourceTree = "<group>"; };
+ 1ACB57DD1105820D0047B991 /* DeclXML.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = DeclXML.cpp; path = lib/Frontend/DeclXML.cpp; sourceTree = "<group>"; };
+ 1ACB57DE1105820D0047B991 /* FrontendAction.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = FrontendAction.cpp; path = lib/Frontend/FrontendAction.cpp; sourceTree = "<group>"; };
+ 1ACB57DF1105820D0047B991 /* FrontendActions.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = FrontendActions.cpp; path = lib/Frontend/FrontendActions.cpp; sourceTree = "<group>"; };
+ 1ACB57E01105820D0047B991 /* FrontendOptions.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = FrontendOptions.cpp; path = lib/Frontend/FrontendOptions.cpp; sourceTree = "<group>"; };
+ 1ACB57E11105820D0047B991 /* LangStandards.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = LangStandards.cpp; path = lib/Frontend/LangStandards.cpp; sourceTree = "<group>"; };
+ 1ACB57E21105820D0047B991 /* TypeXML.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = TypeXML.cpp; path = lib/Frontend/TypeXML.cpp; sourceTree = "<group>"; };
+ 1ACB57E31105820D0047B991 /* VerifyDiagnosticsClient.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = VerifyDiagnosticsClient.cpp; path = lib/Frontend/VerifyDiagnosticsClient.cpp; sourceTree = "<group>"; };
1ADD795110A90C6100741BBA /* TypePrinter.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = TypePrinter.cpp; path = lib/AST/TypePrinter.cpp; sourceTree = "<group>"; };
1ADD795210A90C6100741BBA /* TypeLoc.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = TypeLoc.cpp; path = lib/AST/TypeLoc.cpp; sourceTree = "<group>"; };
1ADD795310A90C6100741BBA /* TemplateBase.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = TemplateBase.cpp; path = lib/AST/TemplateBase.cpp; sourceTree = "<group>"; };
@@ -418,7 +435,6 @@
3507E4C10E27FE2D00FB7B57 /* CheckObjCInstMethSignature.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = CheckObjCInstMethSignature.cpp; path = lib/Analysis/CheckObjCInstMethSignature.cpp; sourceTree = "<group>"; };
352246E10F5C6BE000D0D279 /* HTMLDiagnostics.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = HTMLDiagnostics.cpp; path = lib/Frontend/HTMLDiagnostics.cpp; sourceTree = "<group>"; };
352246E20F5C6BE000D0D279 /* InitHeaderSearch.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = InitHeaderSearch.cpp; path = lib/Frontend/InitHeaderSearch.cpp; sourceTree = "<group>"; };
- 352246E30F5C6BE000D0D279 /* ManagerRegistry.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = ManagerRegistry.cpp; path = lib/Frontend/ManagerRegistry.cpp; sourceTree = "<group>"; };
352246E40F5C6BE000D0D279 /* PlistDiagnostics.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = PlistDiagnostics.cpp; path = lib/Frontend/PlistDiagnostics.cpp; sourceTree = "<group>"; };
352246E50F5C6BE000D0D279 /* TextDiagnosticBuffer.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = TextDiagnosticBuffer.cpp; path = lib/Frontend/TextDiagnosticBuffer.cpp; sourceTree = "<group>"; };
352246E60F5C6BE000D0D279 /* TextDiagnosticPrinter.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = TextDiagnosticPrinter.cpp; path = lib/Frontend/TextDiagnosticPrinter.cpp; sourceTree = "<group>"; };
@@ -922,16 +938,22 @@
1A2A54A50FD1DD1C00F4CE45 /* ASTConsumers.cpp */,
1A2A54A60FD1DD1C00F4CE45 /* Backend.cpp */,
1A2A54A70FD1DD1C00F4CE45 /* CacheTokens.cpp */,
+ 1ACB57DB1105820D0047B991 /* CompilerInstance.cpp */,
+ 1ACB57DC1105820D0047B991 /* CompilerInvocation.cpp */,
+ 1ACB57DD1105820D0047B991 /* DeclXML.cpp */,
1A2A54A80FD1DD1C00F4CE45 /* DependencyFile.cpp */,
1A2A54A90FD1DD1C00F4CE45 /* DiagChecker.cpp */,
1A2A54AA0FD1DD1C00F4CE45 /* DocumentXML.cpp */,
DEF1683F0F9548DC0098507F /* FixItRewriter.cpp */,
+ 1ACB57DE1105820D0047B991 /* FrontendAction.cpp */,
+ 1ACB57DF1105820D0047B991 /* FrontendActions.cpp */,
+ 1ACB57E01105820D0047B991 /* FrontendOptions.cpp */,
1A2A54AB0FD1DD1C00F4CE45 /* GeneratePCH.cpp */,
352246E10F5C6BE000D0D279 /* HTMLDiagnostics.cpp */,
1A2A54AC0FD1DD1C00F4CE45 /* HTMLPrint.cpp */,
352246E20F5C6BE000D0D279 /* InitHeaderSearch.cpp */,
DECB6F060F9D93A800F5FBC7 /* InitPreprocessor.cpp */,
- 352246E30F5C6BE000D0D279 /* ManagerRegistry.cpp */,
+ 1ACB57E11105820D0047B991 /* LangStandards.cpp */,
DEF165740F8FB3510098507F /* PCHReader.cpp */,
DECB77780FA579B000F5FBC7 /* PCHReaderDecl.cpp */,
DECB77120FA5752300F5FBC7 /* PCHReaderStmt.cpp */,
@@ -943,11 +965,12 @@
1A2A54AE0FD1DD1C00F4CE45 /* PrintPreprocessedOutput.cpp */,
352246E50F5C6BE000D0D279 /* TextDiagnosticBuffer.cpp */,
352246E60F5C6BE000D0D279 /* TextDiagnosticPrinter.cpp */,
- 1A2A54AF0FD1DD1C00F4CE45 /* RewriteBlocks.cpp */,
+ 1ACB57E21105820D0047B991 /* TypeXML.cpp */,
1A2A54B00FD1DD1C00F4CE45 /* RewriteMacros.cpp */,
1A2A54B10FD1DD1C00F4CE45 /* RewriteObjC.cpp */,
1A2A54B20FD1DD1C00F4CE45 /* RewriteTest.cpp */,
1A2A54B30FD1DD1C00F4CE45 /* StmtXML.cpp */,
+ 1ACB57E31105820D0047B991 /* VerifyDiagnosticsClient.cpp */,
1A2A54B40FD1DD1C00F4CE45 /* Warnings.cpp */,
);
name = Frontend;
@@ -1296,6 +1319,7 @@
35475B230E7997680000BFE4 /* CGValue.h */,
1A81AA18108144F40094E50B /* CGVtable.cpp */,
1A81AA5D108278A20094E50B /* CGVtable.h */,
+ 1A97825A1108BA18002B98FC /* CGVTT.cpp */,
DE928B800C0A615B00231DA4 /* CodeGenFunction.h */,
DE928B820C0A616000231DA4 /* CodeGenFunction.cpp */,
DE928B7C0C0A615100231DA4 /* CodeGenModule.h */,
@@ -1844,7 +1868,6 @@
DEB07AC80F4A427E00F5A2BE /* SemaAttr.cpp in Sources */,
352246E70F5C6BE000D0D279 /* HTMLDiagnostics.cpp in Sources */,
352246E80F5C6BE000D0D279 /* InitHeaderSearch.cpp in Sources */,
- 352246E90F5C6BE000D0D279 /* ManagerRegistry.cpp in Sources */,
352246EA0F5C6BE000D0D279 /* PlistDiagnostics.cpp in Sources */,
352246EB0F5C6BE000D0D279 /* TextDiagnosticBuffer.cpp in Sources */,
352246EC0F5C6BE000D0D279 /* TextDiagnosticPrinter.cpp in Sources */,
@@ -1892,7 +1915,6 @@
1A2A54BD0FD1DD1C00F4CE45 /* HTMLPrint.cpp in Sources */,
1A2A54BE0FD1DD1C00F4CE45 /* PrintParserCallbacks.cpp in Sources */,
1A2A54BF0FD1DD1C00F4CE45 /* PrintPreprocessedOutput.cpp in Sources */,
- 1A2A54C00FD1DD1C00F4CE45 /* RewriteBlocks.cpp in Sources */,
1A2A54C10FD1DD1C00F4CE45 /* RewriteMacros.cpp in Sources */,
1A2A54C20FD1DD1C00F4CE45 /* RewriteObjC.cpp in Sources */,
1A2A54C30FD1DD1C00F4CE45 /* RewriteTest.cpp in Sources */,
@@ -1935,6 +1957,16 @@
1A986AB710D0746D00A8EA9E /* CGDeclCXX.cpp in Sources */,
E16B523510D30B2400430AC9 /* cc1_main.cpp in Sources */,
1AA963C410D85A7300786C86 /* FullExpr.cpp in Sources */,
+ 1ACB57E41105820D0047B991 /* CompilerInstance.cpp in Sources */,
+ 1ACB57E51105820D0047B991 /* CompilerInvocation.cpp in Sources */,
+ 1ACB57E61105820D0047B991 /* DeclXML.cpp in Sources */,
+ 1ACB57E71105820D0047B991 /* FrontendAction.cpp in Sources */,
+ 1ACB57E81105820D0047B991 /* FrontendActions.cpp in Sources */,
+ 1ACB57E91105820D0047B991 /* FrontendOptions.cpp in Sources */,
+ 1ACB57EA1105820D0047B991 /* LangStandards.cpp in Sources */,
+ 1ACB57EB1105820D0047B991 /* TypeXML.cpp in Sources */,
+ 1ACB57EC1105820D0047B991 /* VerifyDiagnosticsClient.cpp in Sources */,
+ 1A97825B1108BA18002B98FC /* CGVTT.cpp in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
Modified: vendor/clang/dist/include/clang-c/Index.h
==============================================================================
--- vendor/clang/dist/include/clang-c/Index.h Sat Jan 23 11:09:33 2010 (r202878)
+++ vendor/clang/dist/include/clang-c/Index.h Sat Jan 23 11:10:26 2010 (r202879)
@@ -34,77 +34,42 @@ extern "C" {
#define CINDEX_LINKAGE
#endif
-/*
- Clang indeX abstractions. The backing store for the following API's will be
- clangs AST file (currently based on PCH). AST files are created as follows:
-
- "clang -emit-ast <sourcefile.langsuffix> -o <sourcefile.ast>".
-
- Naming Conventions: To avoid namespace pollution, data types are prefixed
- with "CX" and functions are prefixed with "clang_".
-*/
-typedef void *CXIndex; /* An indexing instance. */
+/** \defgroup CINDEX C Interface to Clang
+ *
+ * The C Interface to Clang provides a relatively small API that exposes
+ * facilities for parsing source code into an abstract syntax tree (AST),
+ * loading already-parsed ASTs, traversing the AST, associating
+ * physical source locations with elements within the AST, and other
+ * facilities that support Clang-based development tools.
+ *
+ * This C interface to Clang will never provide all of the information
+ * representation stored in Clang's C++ AST, nor should it: the intent is to
+ * maintain an API that is relatively stable from one release to the next,
+ * providing only the basic functionality needed to support development tools.
+ *
+ * To avoid namespace pollution, data types are prefixed with "CX" and
+ * functions are prefixed with "clang_".
+ *
+ * @{
+ */
+
+/**
+ * \brief An "index" that consists of a set of translation units that would
+ * typically be linked together into an executable or library.
+ */
+typedef void *CXIndex;
+/**
+ * \brief A single translation unit, which resides in an index.
+ */
typedef void *CXTranslationUnit; /* A translation unit instance. */
-typedef void *CXFile; /* A source file */
-typedef void *CXDecl; /* A specific declaration within a translation unit. */
-typedef void *CXStmt; /* A specific statement within a function/method */
-
-/* Cursors represent declarations, definitions, and references. */
-enum CXCursorKind {
- /* Declarations */
- CXCursor_FirstDecl = 1,
- CXCursor_TypedefDecl = 2,
- CXCursor_StructDecl = 3,
- CXCursor_UnionDecl = 4,
- CXCursor_ClassDecl = 5,
- CXCursor_EnumDecl = 6,
- CXCursor_FieldDecl = 7,
- CXCursor_EnumConstantDecl = 8,
- CXCursor_FunctionDecl = 9,
- CXCursor_VarDecl = 10,
- CXCursor_ParmDecl = 11,
- CXCursor_ObjCInterfaceDecl = 12,
- CXCursor_ObjCCategoryDecl = 13,
- CXCursor_ObjCProtocolDecl = 14,
- CXCursor_ObjCPropertyDecl = 15,
- CXCursor_ObjCIvarDecl = 16,
- CXCursor_ObjCInstanceMethodDecl = 17,
- CXCursor_ObjCClassMethodDecl = 18,
- CXCursor_LastDecl = 18,
-
- /* Definitions */
- CXCursor_FirstDefn = 32,
- CXCursor_FunctionDefn = 32,
- CXCursor_ObjCClassDefn = 33,
- CXCursor_ObjCCategoryDefn = 34,
- CXCursor_ObjCInstanceMethodDefn = 35,
- CXCursor_ObjCClassMethodDefn = 36,
- CXCursor_LastDefn = 36,
-
- /* References */
- CXCursor_FirstRef = 40, /* Decl references */
- CXCursor_ObjCSuperClassRef = 40,
- CXCursor_ObjCProtocolRef = 41,
- CXCursor_ObjCClassRef = 42,
-
- CXCursor_ObjCSelectorRef = 43, /* Expression references */
- CXCursor_ObjCIvarRef = 44,
- CXCursor_VarRef = 45,
- CXCursor_FunctionRef = 46,
- CXCursor_EnumConstantRef = 47,
- CXCursor_MemberRef = 48,
- CXCursor_LastRef = 48,
-
- /* Error conditions */
- CXCursor_FirstInvalid = 70,
- CXCursor_InvalidFile = 70,
- CXCursor_NoDeclFound = 71,
- CXCursor_NotImplemented = 72,
- CXCursor_LastInvalid = 72
-};
-
+/**
+ * \brief Opaque pointer representing client data that will be passed through
+ * to various callbacks and visitors.
+ */
+typedef void *CXClientData;
+
/**
* \brief Provides the contents of a file that has not yet been saved to disk.
*
@@ -133,27 +98,19 @@ struct CXUnsavedFile {
unsigned long Length;
};
-/* A cursor into the CXTranslationUnit. */
-
-typedef struct {
- enum CXCursorKind kind;
- CXDecl decl;
- CXStmt stmt; /* expression reference */
- CXDecl referringDecl;
-} CXCursor;
-
-/* A unique token for looking up "visible" CXDecls from a CXTranslationUnit. */
-typedef struct {
- CXIndex index;
- void *data;
-} CXEntity;
-
/**
- * For functions returning a string that might or might not need
- * to be internally allocated and freed.
- * Use clang_getCString to access the C string value.
- * Use clang_disposeString to free the value.
- * Treat it as an opaque type.
+ * \defgroup CINDEX_STRING String manipulation routines
+ *
+ * @{
+ */
+
+/**
+ * \brief A character string.
+ *
+ * The \c CXString type is used to return strings from the interface when
+ * the ownership of that string might different from one call to the next.
+ * Use \c clang_getCString() to retrieve the string data and, once finished
+ * with the string data, call \c clang_disposeString() to free the string.
*/
typedef struct {
const char *Spelling;
@@ -162,12 +119,20 @@ typedef struct {
int MustFreeString;
} CXString;
-/* Get C string pointer from a CXString. */
+/**
+ * \brief Retrieve the character data associated with the given string.
+ */
CINDEX_LINKAGE const char *clang_getCString(CXString string);
-/* Free CXString. */
+/**
+ * \brief Free the given string,
+ */
CINDEX_LINKAGE void clang_disposeString(CXString string);
+/**
+ * @}
+ */
+
/**
* \brief clang_createIndex() provides a shared context for creating
* translation units. It provides two options:
@@ -191,14 +156,16 @@ CINDEX_LINKAGE void clang_disposeString(
* TU = clang_createTranslationUnit(Idx, "IndexTest.pch");
*
* // This will load all the symbols from 'IndexTest.pch'
- * clang_loadTranslationUnit(TU, TranslationUnitVisitor, 0);
+ * clang_visitChildren(clang_getTranslationUnitCursor(TU),
+ * TranslationUnitVisitor, 0);
* clang_disposeTranslationUnit(TU);
*
* // This will load all the symbols from 'IndexTest.c', excluding symbols
* // from 'IndexTest.pch'.
* char *args[] = { "-Xclang", "-include-pch=IndexTest.pch", 0 };
* TU = clang_createTranslationUnitFromSourceFile(Idx, "IndexTest.c", 2, args);
- * clang_loadTranslationUnit(TU, TranslationUnitVisitor, 0);
+ * clang_visitChildren(clang_getTranslationUnitCursor(TU),
+ * TranslationUnitVisitor, 0);
* clang_disposeTranslationUnit(TU);
*
* This process of creating the 'pch', loading it separately, and using it (via
@@ -211,7 +178,7 @@ CINDEX_LINKAGE void clang_disposeIndex(C
CINDEX_LINKAGE CXString
clang_getTranslationUnitSpelling(CXTranslationUnit CTUnit);
-/*
+/**
* \brief Request that AST's be generated external for API calls which parse
* source code on the fly, e.g. \see createTranslationUnitFromSourceFile.
*
@@ -224,7 +191,7 @@ clang_getTranslationUnitSpelling(CXTrans
CINDEX_LINKAGE void clang_setUseExternalASTGeneration(CXIndex index,
int value);
-/*
+/**
* \brief Create a translation unit from an AST file (-emit-ast).
*/
CINDEX_LINKAGE CXTranslationUnit clang_createTranslationUnit(
@@ -255,137 +222,632 @@ CINDEX_LINKAGE void clang_disposeTransla
*
* \param source_filename - The name of the source file to load, or NULL if the
* source file is included in clang_command_line_args.
+ *
+ * \param num_unsaved_files the number of unsaved file entries in \p
+ * unsaved_files.
+ *
+ * \param unsaved_files the files that have not yet been saved to disk
+ * but may be required for code completion, including the contents of
+ * those files.
*/
CINDEX_LINKAGE CXTranslationUnit clang_createTranslationUnitFromSourceFile(
- CXIndex CIdx,
- const char *source_filename,
- int num_clang_command_line_args,
- const char **clang_command_line_args
-);
+ CXIndex CIdx,
+ const char *source_filename,
+ int num_clang_command_line_args,
+ const char **clang_command_line_args,
+ unsigned num_unsaved_files,
+ struct CXUnsavedFile *unsaved_files);
-/*
- Usage: clang_loadTranslationUnit(). Will load the toplevel declarations
- within a translation unit, issuing a 'callback' for each one.
-
- void printObjCInterfaceNames(CXTranslationUnit X, CXCursor C) {
- if (clang_getCursorKind(C) == Cursor_Declaration) {
- CXDecl D = clang_getCursorDecl(C);
- if (clang_getDeclKind(D) == CXDecl_ObjC_interface)
- printf("@interface %s in file %s on line %d column %d\n",
- clang_getDeclSpelling(D), clang_getCursorSource(C),
- clang_getCursorLine(C), clang_getCursorColumn(C));
- }
- }
- static void usage {
- clang_loadTranslationUnit(CXTranslationUnit, printObjCInterfaceNames);
- }
-*/
-typedef void *CXClientData;
-typedef void (*CXTranslationUnitIterator)(CXTranslationUnit, CXCursor,
- CXClientData);
-CINDEX_LINKAGE void clang_loadTranslationUnit(CXTranslationUnit,
- CXTranslationUnitIterator,
- CXClientData);
-
-/*
- Usage: clang_loadDeclaration(). Will load the declaration, issuing a
- 'callback' for each declaration/reference within the respective declaration.
-
- For interface declarations, this will index the super class, protocols,
- ivars, methods, etc. For structure declarations, this will index the fields.
- For functions, this will index the parameters (and body, for function
- definitions), local declarations/references.
-
- void getInterfaceDetails(CXDecl X, CXCursor C) {
- switch (clang_getCursorKind(C)) {
- case Cursor_ObjC_ClassRef:
- CXDecl SuperClass = clang_getCursorDecl(C);
- case Cursor_ObjC_ProtocolRef:
- CXDecl AdoptsProtocol = clang_getCursorDecl(C);
- case Cursor_Declaration:
- CXDecl AnIvarOrMethod = clang_getCursorDecl(C);
- }
- }
- static void usage() {
- if (clang_getDeclKind(D) == CXDecl_ObjC_interface) {
- clang_loadDeclaration(D, getInterfaceDetails);
- }
- }
-*/
-typedef void (*CXDeclIterator)(CXDecl, CXCursor, CXClientData);
-
-CINDEX_LINKAGE void clang_loadDeclaration(CXDecl, CXDeclIterator, CXClientData);
+/**
+ * \defgroup CINDEX_FILES File manipulation routines
+ *
+ * @{
+ */
+
+/**
+ * \brief A particular source file that is part of a translation unit.
+ */
+typedef void *CXFile;
+
-/*
- * CXFile Operations.
+/**
+ * \brief Retrieve the complete file and path name of the given file.
*/
CINDEX_LINKAGE const char *clang_getFileName(CXFile SFile);
+
+/**
+ * \brief Retrieve the last modification time of the given file.
+ */
CINDEX_LINKAGE time_t clang_getFileTime(CXFile SFile);
-/*
- * CXEntity Operations.
+/**
+ * \brief Retrieve a file handle within the given translation unit.
+ *
+ * \param tu the translation unit
+ *
+ * \param file_name the name of the file.
+ *
+ * \returns the file handle for the named file in the translation unit \p tu,
+ * or a NULL file handle if the file was not a part of this translation unit.
+ */
+CINDEX_LINKAGE CXFile clang_getFile(CXTranslationUnit tu,
+ const char *file_name);
+
+/**
+ * @}
+ */
+
+/**
+ * \defgroup CINDEX_LOCATIONS Physical source locations
+ *
+ * Clang represents physical source locations in its abstract syntax tree in
+ * great detail, with file, line, and column information for the majority of
+ * the tokens parsed in the source code. These data types and functions are
+ * used to represent source location information, either for a particular
+ * point in the program or for a range of points in the program, and extract
+ * specific location information from those data types.
+ *
+ * @{
+ */
+
+/**
+ * \brief Identifies a specific source location within a translation
+ * unit.
+ *
+ * Use clang_getInstantiationLocation() to map a source location to a
+ * particular file, line, and column.
+ */
+typedef struct {
+ void *ptr_data;
+ unsigned int_data;
+} CXSourceLocation;
+
+/**
+ * \brief Identifies a range of source locations in the source code.
+ *
+ * Use clang_getRangeStart() and clang_getRangeEnd() to retrieve the
+ * starting and end locations from a source range, respectively.
+ */
+typedef struct {
+ void *ptr_data;
+ unsigned begin_int_data;
+ unsigned end_int_data;
+} CXSourceRange;
+
+/**
+ * \brief Retrieve a NULL (invalid) source location.
+ */
+CINDEX_LINKAGE CXSourceLocation clang_getNullLocation();
+
+/**
+ * \determine Determine whether two source locations, which must refer into
+ * the same translation unit, refer to exactly the same point in the source
+ * code.
+ *
+ * \returns non-zero if the source locations refer to the same location, zero
+ * if they refer to different locations.
+ */
+CINDEX_LINKAGE unsigned clang_equalLocations(CXSourceLocation loc1,
+ CXSourceLocation loc2);
+
+/**
+ * \brief Retrieves the source location associated with a given
+ * file/line/column in a particular translation unit.
+ */
+CINDEX_LINKAGE CXSourceLocation clang_getLocation(CXTranslationUnit tu,
+ CXFile file,
+ unsigned line,
+ unsigned column);
+
+/**
+ * \brief Retrieve a source range given the beginning and ending source
+ * locations.
+ */
+CINDEX_LINKAGE CXSourceRange clang_getRange(CXSourceLocation begin,
+ CXSourceLocation end);
+
+/**
+ * \brief Retrieve the file, line, and column represented by the
+ * given source location.
+ *
+ * \param location the location within a source file that will be
+ * decomposed into its parts.
+ *
+ * \param file if non-NULL, will be set to the file to which the given
+ * source location points.
+ *
+ * \param line if non-NULL, will be set to the line to which the given
+ * source location points.
+ *
+ * \param column if non-NULL, will be set to the column to which the
+ * given source location points.
+ */
+CINDEX_LINKAGE void clang_getInstantiationLocation(CXSourceLocation location,
+ CXFile *file,
+ unsigned *line,
+ unsigned *column);
+
+/**
+ * \brief Retrieve a source location representing the first
+ * character within a source range.
+ */
+CINDEX_LINKAGE CXSourceLocation clang_getRangeStart(CXSourceRange range);
+
+/**
+ * \brief Retrieve a source location representing the last
+ * character within a source range.
+ */
+CINDEX_LINKAGE CXSourceLocation clang_getRangeEnd(CXSourceRange range);
+
+/**
+ * @}
+ */
+
+/**
+ * \brief Describes the kind of entity that a cursor refers to.
*/
+enum CXCursorKind {
+ /* Declarations */
+ CXCursor_FirstDecl = 1,
+ /**
+ * \brief A declaration whose specific kind is not exposed via this
+ * interface.
+ *
+ * Unexposed declarations have the same operations as any other kind
+ * of declaration; one can extract their location information,
+ * spelling, find their definitions, etc. However, the specific kind
+ * of the declaration is not reported.
+ */
+ CXCursor_UnexposedDecl = 1,
+ /** \brief A C or C++ struct. */
+ CXCursor_StructDecl = 2,
+ /** \brief A C or C++ union. */
+ CXCursor_UnionDecl = 3,
+ /** \brief A C++ class. */
+ CXCursor_ClassDecl = 4,
+ /** \brief An enumeration. */
+ CXCursor_EnumDecl = 5,
+ /**
+ * \brief A field (in C) or non-static data member (in C++) in a
+ * struct, union, or C++ class.
+ */
+ CXCursor_FieldDecl = 6,
+ /** \brief An enumerator constant. */
+ CXCursor_EnumConstantDecl = 7,
+ /** \brief A function. */
+ CXCursor_FunctionDecl = 8,
+ /** \brief A variable. */
+ CXCursor_VarDecl = 9,
+ /** \brief A function or method parameter. */
+ CXCursor_ParmDecl = 10,
+ /** \brief An Objective-C @interface. */
+ CXCursor_ObjCInterfaceDecl = 11,
+ /** \brief An Objective-C @interface for a category. */
+ CXCursor_ObjCCategoryDecl = 12,
+ /** \brief An Objective-C @protocol declaration. */
+ CXCursor_ObjCProtocolDecl = 13,
+ /** \brief An Objective-C @property declaration. */
+ CXCursor_ObjCPropertyDecl = 14,
+ /** \brief An Objective-C instance variable. */
+ CXCursor_ObjCIvarDecl = 15,
+ /** \brief An Objective-C instance method. */
+ CXCursor_ObjCInstanceMethodDecl = 16,
+ /** \brief An Objective-C class method. */
+ CXCursor_ObjCClassMethodDecl = 17,
+ /** \brief An Objective-C @implementation. */
+ CXCursor_ObjCImplementationDecl = 18,
+ /** \brief An Objective-C @implementation for a category. */
+ CXCursor_ObjCCategoryImplDecl = 19,
+ /** \brief A typedef */
+ CXCursor_TypedefDecl = 20,
+ CXCursor_LastDecl = 20,
+
+ /* References */
+ CXCursor_FirstRef = 40, /* Decl references */
+ CXCursor_ObjCSuperClassRef = 40,
+ CXCursor_ObjCProtocolRef = 41,
+ CXCursor_ObjCClassRef = 42,
+ /**
+ * \brief A reference to a type declaration.
+ *
+ * A type reference occurs anywhere where a type is named but not
+ * declared. For example, given:
+ *
+ * \code
+ * typedef unsigned size_type;
+ * size_type size;
+ * \endcode
+ *
+ * The typedef is a declaration of size_type (CXCursor_TypedefDecl),
+ * while the type of the variable "size" is referenced. The cursor
+ * referenced by the type of size is the typedef for size_type.
+ */
+ CXCursor_TypeRef = 43,
+ CXCursor_LastRef = 43,
+
+ /* Error conditions */
+ CXCursor_FirstInvalid = 70,
+ CXCursor_InvalidFile = 70,
+ CXCursor_NoDeclFound = 71,
+ CXCursor_NotImplemented = 72,
+ CXCursor_LastInvalid = 72,
+
+ /* Expressions */
+ CXCursor_FirstExpr = 100,
-/* clang_getDeclaration() maps from a CXEntity to the matching CXDecl (if any)
- * in a specified translation unit. */
-CINDEX_LINKAGE CXDecl clang_getDeclaration(CXEntity, CXTranslationUnit);
-
-/*
- * CXDecl Operations.
- */
-CINDEX_LINKAGE CXCursor clang_getCursorFromDecl(CXDecl);
-CINDEX_LINKAGE CXEntity clang_getEntityFromDecl(CXIndex, CXDecl);
-CINDEX_LINKAGE CXString clang_getDeclSpelling(CXDecl);
-CINDEX_LINKAGE unsigned clang_getDeclLine(CXDecl);
-CINDEX_LINKAGE unsigned clang_getDeclColumn(CXDecl);
-CINDEX_LINKAGE CXString clang_getDeclUSR(CXDecl);
-CINDEX_LINKAGE const char *clang_getDeclSource(CXDecl); /* deprecate */
-CINDEX_LINKAGE CXFile clang_getDeclSourceFile(CXDecl);
-
-typedef struct CXSourceLineColumn {
- unsigned line;
- unsigned column;
-} CXSourceLineColumn;
-
-typedef struct CXDeclExtent {
- CXSourceLineColumn begin;
- CXSourceLineColumn end;
-} CXSourceExtent;
-
-/* clang_getDeclExtent() returns the physical extent of a declaration. The
- * beginning line/column pair points to the start of the first token in the
- * declaration, and the ending line/column pair points to the last character in
- * the last token of the declaration.
- */
-CINDEX_LINKAGE CXSourceExtent clang_getDeclExtent(CXDecl);
-
-/*
- * CXCursor Operations.
- */
-/**
- Usage: clang_getCursor() will translate a source/line/column position
- into an AST cursor (to derive semantic information from the source code).
- */
-CINDEX_LINKAGE CXCursor clang_getCursor(CXTranslationUnit,
- const char *source_name,
- unsigned line, unsigned column);
-
+ /**
+ * \brief An expression whose specific kind is not exposed via this
+ * interface.
+ *
+ * Unexposed expressions have the same operations as any other kind
+ * of expression; one can extract their location information,
+ * spelling, children, etc. However, the specific kind of the
+ * expression is not reported.
+ */
+ CXCursor_UnexposedExpr = 100,
+
+ /**
+ * \brief An expression that refers to some value declaration, such
+ * as a function, varible, or enumerator.
+ */
+ CXCursor_DeclRefExpr = 101,
+
+ /**
+ * \brief An expression that refers to a member of a struct, union,
+ * class, Objective-C class, etc.
+ */
+ CXCursor_MemberRefExpr = 102,
+
+ /** \brief An expression that calls a function. */
+ CXCursor_CallExpr = 103,
+
+ /** \brief An expression that sends a message to an Objective-C
+ object or class. */
+ CXCursor_ObjCMessageExpr = 104,
+ CXCursor_LastExpr = 104,
+
+ /* Statements */
+ CXCursor_FirstStmt = 200,
+ /**
+ * \brief A statement whose specific kind is not exposed via this
+ * interface.
+ *
+ * Unexposed statements have the same operations as any other kind of
+ * statement; one can extract their location information, spelling,
+ * children, etc. However, the specific kind of the statement is not
+ * reported.
+ */
+ CXCursor_UnexposedStmt = 200,
+ CXCursor_LastStmt = 200,
+
+ /**
+ * \brief Cursor that represents the translation unit itself.
+ *
+ * The translation unit cursor exists primarily to act as the root
+ * cursor for traversing the contents of a translation unit.
+ */
+ CXCursor_TranslationUnit = 300
+};
+
+/**
+ * \brief A cursor representing some element in the abstract syntax tree for
+ * a translation unit.
+ *
+ * The cursor abstraction unifies the different kinds of entities in a
+ * program--declaration, statements, expressions, references to declarations,
+ * etc.--under a single "cursor" abstraction with a common set of operations.
+ * Common operation for a cursor include: getting the physical location in
+ * a source file where the cursor points, getting the name associated with a
+ * cursor, and retrieving cursors for any child nodes of a particular cursor.
+ *
+ * Cursors can be produced in two specific ways.
+ * clang_getTranslationUnitCursor() produces a cursor for a translation unit,
+ * from which one can use clang_visitChildren() to explore the rest of the
+ * translation unit. clang_getCursor() maps from a physical source location
+ * to the entity that resides at that location, allowing one to map from the
+ * source code into the AST.
+ */
+typedef struct {
+ enum CXCursorKind kind;
+ void *data[3];
+} CXCursor;
+
+/**
+ * \defgroup CINDEX_CURSOR_MANIP Cursor manipulations
+ *
+ * @{
+ */
+
+/**
+ * \brief Retrieve the NULL cursor, which represents no entity.
+ */
CINDEX_LINKAGE CXCursor clang_getNullCursor(void);
+
+/**
+ * \brief Retrieve the cursor that represents the given translation unit.
+ *
+ * The translation unit cursor can be used to start traversing the
+ * various declarations within the given translation unit.
+ */
+CINDEX_LINKAGE CXCursor clang_getTranslationUnitCursor(CXTranslationUnit);
+/**
+ * \brief Determine whether two cursors are equivalent.
+ */
+CINDEX_LINKAGE unsigned clang_equalCursors(CXCursor, CXCursor);
+
+/**
+ * \brief Retrieve the kind of the given cursor.
+ */
CINDEX_LINKAGE enum CXCursorKind clang_getCursorKind(CXCursor);
+
+/**
+ * \brief Determine whether the given cursor kind represents a declaration.
+ */
CINDEX_LINKAGE unsigned clang_isDeclaration(enum CXCursorKind);
+
+/**
+ * \brief Determine whether the given cursor kind represents a simple
+ * reference.
+ *
+ * Note that other kinds of cursors (such as expressions) can also refer to
+ * other cursors. Use clang_getCursorReferenced() to determine whether a
+ * particular cursor refers to another entity.
+ */
CINDEX_LINKAGE unsigned clang_isReference(enum CXCursorKind);
-CINDEX_LINKAGE unsigned clang_isDefinition(enum CXCursorKind);
+
+/**
+ * \brief Determine whether the given cursor kind represents an expression.
+ */
+CINDEX_LINKAGE unsigned clang_isExpression(enum CXCursorKind);
+
+/**
+ * \brief Determine whether the given cursor kind represents a statement.
+ */
+CINDEX_LINKAGE unsigned clang_isStatement(enum CXCursorKind);
+
+/**
+ * \brief Determine whether the given cursor kind represents an invalid
+ * cursor.
+ */
CINDEX_LINKAGE unsigned clang_isInvalid(enum CXCursorKind);
-CINDEX_LINKAGE unsigned clang_equalCursors(CXCursor, CXCursor);
+/**
+ * \brief Determine whether the given cursor kind represents a translation
+ * unit.
+ */
+CINDEX_LINKAGE unsigned clang_isTranslationUnit(enum CXCursorKind);
+
+/**
+ * @}
+ */
+
+/**
+ * \defgroup CINDEX_CURSOR_SOURCE Mapping between cursors and source code
+ *
+ * Cursors represent a location within the Abstract Syntax Tree (AST). These
+ * routines help map between cursors and the physical locations where the
+ * described entities occur in the source code. The mapping is provided in
+ * both directions, so one can map from source code to the AST and back.
+ *
+ * @{
+ */
+
+/**
+ * \brief Map a source location to the cursor that describes the entity at that
+ * location in the source code.
+ *
+ * clang_getCursor() maps an arbitrary source location within a translation
+ * unit down to the most specific cursor that describes the entity at that
+ * location. For example, given an expression \c x + y, invoking
+ * clang_getCursor() with a source location pointing to "x" will return the
+ * cursor for "x"; similarly for "y". If the cursor points anywhere between
+ * "x" or "y" (e.g., on the + or the whitespace around it), clang_getCursor()
+ * will return a cursor referring to the "+" expression.
+ *
+ * \returns a cursor representing the entity at the given source location, or
+ * a NULL cursor if no such entity can be found.
+ */
+CINDEX_LINKAGE CXCursor clang_getCursor(CXTranslationUnit, CXSourceLocation);
+
+/**
+ * \brief Retrieve the physical location of the source constructor referenced
+ * by the given cursor.
+ *
+ * The location of a declaration is typically the location of the name of that
+ * declaration, where the name of that declaration would occur if it is
+ * unnamed, or some keyword that introduces that particular declaration.
+ * The location of a reference is where that reference occurs within the
+ * source code.
+ */
+CINDEX_LINKAGE CXSourceLocation clang_getCursorLocation(CXCursor);
+
+/**
+ * \brief Retrieve the physical extent of the source construct referenced by
+ * the given cursor.
+ *
+ * The extent of a cursor starts with the file/line/column pointing at the
+ * first character within the source construct that the cursor refers to and
+ * ends with the last character withinin that source construct. For a
+ * declaration, the extent covers the declaration itself. For a reference,
+ * the extent covers the location of the reference (e.g., where the referenced
+ * entity was actually used).
+ */
+CINDEX_LINKAGE CXSourceRange clang_getCursorExtent(CXCursor);
-CINDEX_LINKAGE unsigned clang_getCursorLine(CXCursor);
-CINDEX_LINKAGE unsigned clang_getCursorColumn(CXCursor);
+/**
+ * @}
+ */
+
+/**
+ * \defgroup CINDEX_CURSOR_TRAVERSAL Traversing the AST with cursors
+ *
+ * These routines provide the ability to traverse the abstract syntax tree
+ * using cursors.
+ *
+ * @{
+ */
+
+/**
+ * \brief Describes how the traversal of the children of a particular
+ * cursor should proceed after visiting a particular child cursor.
+ *
+ * A value of this enumeration type should be returned by each
+ * \c CXCursorVisitor to indicate how clang_visitChildren() proceed.
+ */
+enum CXChildVisitResult {
+ /**
+ * \brief Terminates the cursor traversal.
+ */
+ CXChildVisit_Break,
+ /**
+ * \brief Continues the cursor traversal with the next sibling of
+ * the cursor just visited, without visiting its children.
+ */
+ CXChildVisit_Continue,
+ /**
+ * \brief Recursively traverse the children of this cursor, using
+ * the same visitor and client data.
+ */
+ CXChildVisit_Recurse
+};
+
+/**
+ * \brief Visitor invoked for each cursor found by a traversal.
+ *
+ * This visitor function will be invoked for each cursor found by
+ * clang_visitCursorChildren(). Its first argument is the cursor being
+ * visited, its second argument is the parent visitor for that cursor,
+ * and its third argument is the client data provided to
+ * clang_visitCursorChildren().
+ *
+ * The visitor should return one of the \c CXChildVisitResult values
+ * to direct clang_visitCursorChildren().
+ */
+typedef enum CXChildVisitResult (*CXCursorVisitor)(CXCursor cursor,
+ CXCursor parent,
+ CXClientData client_data);
+
+/**
+ * \brief Visit the children of a particular cursor.
+ *
+ * This function visits all the direct children of the given cursor,
+ * invoking the given \p visitor function with the cursors of each
+ * visited child. The traversal may be recursive, if the visitor returns
+ * \c CXChildVisit_Recurse. The traversal may also be ended prematurely, if
+ * the visitor returns \c CXChildVisit_Break.
+ *
+ * \param tu the translation unit into which the cursor refers.
*** DIFF OUTPUT TRUNCATED AT 1000 LINES ***
More information about the svn-src-all
mailing list