Home
last modified time | relevance | path

Searched refs:LangOpts (Results 1 – 25 of 116) sorted by relevance

12345

/external/clang/lib/Lex/
DPPMacroExpansion.cpp102 if (LangOpts.MicrosoftExt) { in RegisterBuiltinMacros()
121 if (LangOpts.Modules) { in RegisterBuiltinMacros()
125 if (!LangOpts.CurrentModule.empty()) in RegisterBuiltinMacros()
633 if (ArgTokens.size() == ArgTokenStart && !LangOpts.C99) in ReadFunctionLikeMacroArgs()
634 Diag(Tok, LangOpts.CPlusPlus11 ? in ReadFunctionLikeMacroArgs()
852 const LangOptions &LangOpts = PP.getLangOpts(); in HasFeature() local
860 .Case("address_sanitizer", LangOpts.Sanitize.Address) in HasFeature()
878 .Case("blocks", LangOpts.Blocks) in HasFeature()
880 .Case("cxx_exceptions", LangOpts.CXXExceptions) in HasFeature()
881 .Case("cxx_rtti", LangOpts.RTTI) in HasFeature()
[all …]
DLexer.cpp112 LangOpts(PP.getLangOpts()) { in Lexer()
122 if (LangOpts.TraditionalCPP) in resetExtendedTokenMode()
133 : FileLoc(fileloc), LangOpts(langOpts) { in Lexer()
146 : FileLoc(SM.getLocForStartOfFile(FID)), LangOpts(langOpts) { in Lexer()
238 const LangOptions &LangOpts, char *Spelling) { in getSpellingSlow() argument
248 Spelling[Length++] = Lexer::getCharAndSizeNoWarn(BufPtr, Size, LangOpts); in getSpellingSlow()
277 Spelling[Length++] = Lexer::getCharAndSizeNoWarn(BufPtr, Size, LangOpts); in getSpellingSlow()
333 const LangOptions &LangOpts, bool *Invalid) { in getSpelling() argument
350 Result.resize(getSpellingSlow(Tok, TokStart, LangOpts, &*Result.begin())); in getSpelling()
366 const LangOptions &LangOpts, bool *Invalid) { in getSpelling() argument
[all …]
/external/clang/lib/Frontend/
DInitPreprocessor.cpp293 static void AddObjCXXARCLibstdcxxDefines(const LangOptions &LangOpts, in AddObjCXXARCLibstdcxxDefines() argument
322 if (LangOpts.ObjCARCWeak) { in AddObjCXXARCLibstdcxxDefines()
345 const LangOptions &LangOpts, in InitializeStandardPredefinedMacros() argument
348 if (!LangOpts.MSVCCompat && !LangOpts.TraditionalCPP) in InitializeStandardPredefinedMacros()
350 if (LangOpts.Freestanding) in InitializeStandardPredefinedMacros()
355 if (!LangOpts.CPlusPlus) { in InitializeStandardPredefinedMacros()
356 if (LangOpts.C11) in InitializeStandardPredefinedMacros()
358 else if (LangOpts.C99) in InitializeStandardPredefinedMacros()
360 else if (!LangOpts.GNUMode && LangOpts.Digraphs) in InitializeStandardPredefinedMacros()
364 if (LangOpts.CPlusPlus1z) in InitializeStandardPredefinedMacros()
[all …]
DFrontendActions.cpp134 const LangOptions &LangOpts, in addHeaderInclude() argument
136 if (IsExternC && LangOpts.CPlusPlus) in addHeaderInclude()
138 if (LangOpts.ObjC1) in addHeaderInclude()
154 if (IsExternC && LangOpts.CPlusPlus) in addHeaderInclude()
161 const LangOptions &LangOpts, in addHeaderInclude() argument
163 return addHeaderInclude(Header->getName(), Includes, LangOpts, IsExternC); in addHeaderInclude()
174 collectModuleHeaderIncludes(const LangOptions &LangOpts, FileManager &FileMgr, in collectModuleHeaderIncludes() argument
186 addHeaderInclude(Header, Includes, LangOpts, Module->IsExternC)) in collectModuleHeaderIncludes()
196 LangOpts, Module->IsExternC)) in collectModuleHeaderIncludes()
224 LangOpts, Module->IsExternC)) in collectModuleHeaderIncludes()
[all …]
DDiagnosticRenderer.cpp44 const LangOptions &LangOpts) { in getImmediateMacroName() argument
63 unsigned MacroTokenLength = Lexer::MeasureTokenLength(Loc, SM, LangOpts); in getImmediateMacroName()
68 DiagnosticRenderer::DiagnosticRenderer(const LangOptions &LangOpts, in DiagnosticRenderer() argument
70 : LangOpts(LangOpts), DiagOpts(DiagOpts), LastLevel() {} in DiagnosticRenderer()
93 const SourceManager &SM, const LangOptions &LangOpts, in mergeFixits() argument
95 edit::Commit commit(SM, LangOpts); in mergeFixits()
116 edit::EditedSource Editor(SM, LangOpts); in mergeFixits()
144 mergeFixits(FixItHints, *SM, LangOpts, MergedFixits); in emitDiagnostic()
466 StringRef MacroName = getImmediateMacroName(Loc, SM, LangOpts); in emitMacroExpansions()
/external/clang/include/clang/Lex/
DLexer.h54 LangOptions LangOpts; // LangOpts enabled by this language (cache). variable
108 Lexer(SourceLocation FileLoc, const LangOptions &LangOpts,
115 const SourceManager &SM, const LangOptions &LangOpts);
128 const LangOptions &getLangOpts() const { return LangOpts; } in getLangOpts()
173 assert((!Val || LexingRawMode || LangOpts.TraditionalCPP) && in SetKeepWhitespaceMode()
250 const LangOptions &LangOpts,
260 const LangOptions &LangOpts,
274 const LangOptions &LangOpts,
283 const LangOptions &LangOpts);
289 const LangOptions &LangOpts,
[all …]
/external/clang/lib/Basic/
DIdentifierTable.cpp75 IdentifierTable::IdentifierTable(const LangOptions &LangOpts, in IdentifierTable() argument
82 AddKeywords(LangOpts); in IdentifierTable()
125 const LangOptions &LangOpts, IdentifierTable &Table) { in AddKeyword() argument
128 else if (LangOpts.CPlusPlus && (Flags & KEYCXX)) AddResult = 2; in AddKeyword()
129 else if (LangOpts.CPlusPlus11 && (Flags & KEYCXX11)) AddResult = 2; in AddKeyword()
130 else if (LangOpts.C99 && (Flags & KEYC99)) AddResult = 2; in AddKeyword()
131 else if (LangOpts.GNUKeywords && (Flags & KEYGNU)) AddResult = 1; in AddKeyword()
132 else if (LangOpts.MicrosoftExt && (Flags & KEYMS)) AddResult = 1; in AddKeyword()
133 else if (LangOpts.Borland && (Flags & KEYBORLAND)) AddResult = 1; in AddKeyword()
134 else if (LangOpts.Bool && (Flags & BOOLSUPPORT)) AddResult = 2; in AddKeyword()
[all …]
DBuiltins.cpp50 const LangOptions &LangOpts) { in BuiltinIsSupported() argument
51 bool BuiltinsUnsupported = LangOpts.NoBuiltin && in BuiltinIsSupported()
54 LangOpts.NoMathBuiltin && BuiltinInfo.HeaderName && in BuiltinIsSupported()
56 bool GnuModeUnsupported = !LangOpts.GNUMode && in BuiltinIsSupported()
58 bool MSModeUnsupported = !LangOpts.MicrosoftExt && in BuiltinIsSupported()
60 bool ObjCUnsupported = !LangOpts.ObjC1 && in BuiltinIsSupported()
70 const LangOptions& LangOpts) { in InitializeBuiltins() argument
73 if (BuiltinIsSupported(BuiltinInfo[i], LangOpts)) { in InitializeBuiltins()
79 if (BuiltinIsSupported(TSRecords[i], LangOpts)) in InitializeBuiltins()
DModule.cpp59 static bool hasFeature(StringRef Feature, const LangOptions &LangOpts, in hasFeature() argument
62 .Case("altivec", LangOpts.AltiVec) in hasFeature()
63 .Case("blocks", LangOpts.Blocks) in hasFeature()
64 .Case("cplusplus", LangOpts.CPlusPlus) in hasFeature()
65 .Case("cplusplus11", LangOpts.CPlusPlus11) in hasFeature()
66 .Case("objc", LangOpts.ObjC1) in hasFeature()
67 .Case("objc_arc", LangOpts.ObjCAutoRefCount) in hasFeature()
68 .Case("opencl", LangOpts.OpenCL) in hasFeature()
74 Module::isAvailable(const LangOptions &LangOpts, const TargetInfo &Target, in isAvailable() argument
85 if (hasFeature(Current->Requirements[I].first, LangOpts, Target) != in isAvailable()
[all …]
/external/clang/lib/StaticAnalyzer/Core/
DPlistDiagnostics.cpp32 const LangOptions &LangOpts; member in __anonc875182c0111::PlistDiagnostics
37 const LangOptions &LangOpts,
64 LangOpts(LO), in PlistDiagnostics()
87 const LangOptions &LangOpts, in ReportControlFlow() argument
110 EmitRange(o, SM, LangOpts, CharSourceRange::getTokenRange(StartEdge), FM, in ReportControlFlow()
115 EmitRange(o, SM, LangOpts, CharSourceRange::getTokenRange(EndEdge), FM, in ReportControlFlow()
139 const LangOptions &LangOpts, in ReportEvent() argument
157 EmitLocation(o, SM, LangOpts, L, FM, indent); in ReportEvent()
168 EmitRange(o, SM, LangOpts, CharSourceRange::getTokenRange(*I), FM, in ReportEvent()
199 const LangOptions &LangOpts,
[all …]
/external/clang/unittests/Lex/
DLexerTest.cpp69 HeaderSearch HeaderInfo(new HeaderSearchOptions, SourceMgr, Diags, LangOpts, in CheckLex()
71 Preprocessor PP(new PreprocessorOptions(), Diags, LangOpts, SourceMgr, in CheckLex()
99 SourceMgr, LangOpts, &Invalid); in getSourceText()
110 LangOptions LangOpts; member in __anon3f68e8070111::LexerTest
296 EXPECT_TRUE(Lexer::isAtStartOfMacroExpansion(lsqrLoc, SourceMgr, LangOpts, &Loc)); in TEST_F()
298 EXPECT_FALSE(Lexer::isAtStartOfMacroExpansion(idLoc, SourceMgr, LangOpts)); in TEST_F()
299 EXPECT_FALSE(Lexer::isAtEndOfMacroExpansion(idLoc, SourceMgr, LangOpts)); in TEST_F()
300 EXPECT_TRUE(Lexer::isAtEndOfMacroExpansion(rsqrLoc, SourceMgr, LangOpts, &Loc)); in TEST_F()
304 CharSourceRange::getTokenRange(lsqrLoc, idLoc), SourceMgr, LangOpts); in TEST_F()
307 SourceMgr, LangOpts); in TEST_F()
[all …]
/external/clang/lib/Edit/
DEditedSource.cpp244 static bool canBeJoined(char left, char right, const LangOptions &LangOpts) { in canBeJoined() argument
247 return !(Lexer::isIdentifierBodyChar(left, LangOpts) && in canBeJoined()
248 Lexer::isIdentifierBodyChar(right, LangOpts)); in canBeJoined()
254 const LangOptions &LangOpts) { in canRemoveWhitespace() argument
255 if (!canBeJoined(left, right, LangOpts)) in canRemoveWhitespace()
259 if (canBeJoined(beforeWSpace, right, LangOpts)) in canRemoveWhitespace()
267 static void adjustRemoval(const SourceManager &SM, const LangOptions &LangOpts, in adjustRemoval() argument
271 SourceLocation BeginTokLoc = Lexer::GetBeginningOfToken(Loc, SM, LangOpts); in adjustRemoval()
295 LangOpts)) in adjustRemoval()
300 if (!canBeJoined(buffer[begin-1], buffer[end], LangOpts)) in adjustRemoval()
[all …]
/external/clang/include/clang/Edit/
DEditedSource.h29 const LangOptions &LangOpts; variable
47 EditedSource(const SourceManager &SM, const LangOptions &LangOpts,
49 : SourceMgr(SM), LangOpts(LangOpts), PPRec(PPRec), in SourceMgr()
53 const LangOptions &getLangOpts() const { return LangOpts; } in getLangOpts()
DCommit.h49 const LangOptions &LangOpts; variable
60 Commit(const SourceManager &SM, const LangOptions &LangOpts,
62 : SourceMgr(SM), LangOpts(LangOpts), PPRec(PPRec), Editor(nullptr), in SourceMgr()
/external/clang/lib/CodeGen/
DBackendUtil.cpp51 const LangOptions &LangOpts; member in __anonfd95b7bd0111::EmitAssemblyHelper
114 : Diags(_Diags), CodeGenOpts(CGOpts), TargetOpts(TOpts), LangOpts(LOpts), in EmitAssemblyHelper()
137 const LangOptions &LangOpts) in PassManagerBuilderWrapper() argument
138 : PassManagerBuilder(), CGOpts(CGOpts), LangOpts(LangOpts) {} in PassManagerBuilderWrapper()
140 const LangOptions &getLangOpts() const { return LangOpts; } in getLangOpts()
143 const LangOptions &LangOpts; member in __anonfd95b7bd0111::PassManagerBuilderWrapper
231 PassManagerBuilderWrapper PMBuilder(CodeGenOpts, LangOpts); in CreatePasses()
251 if (LangOpts.ObjCAutoRefCount) { in CreatePasses()
260 if (LangOpts.Sanitize.LocalBounds) { in CreatePasses()
267 if (LangOpts.Sanitize.Address) { in CreatePasses()
[all …]
/external/clang/include/clang/Basic/
DPlistSupport.h92 const LangOptions &LangOpts, SourceLocation L,
99 extend ? Lexer::MeasureTokenLength(Loc, SM, LangOpts) - 1 : 0;
112 const LangOptions &LangOpts, CharSourceRange R, in EmitRange() argument
115 EmitLocation(o, SM, LangOpts, R.getBegin(), FM, indent + 1); in EmitRange()
116 EmitLocation(o, SM, LangOpts, R.getEnd(), FM, indent + 1, R.isTokenRange()); in EmitRange()
/external/clang/tools/libclang/
DCIndexDiagnostic.h114 const LangOptions &LangOpts; member
117 const LangOptions &LangOpts) in CXStoredDiagnostic()
119 Diag(Diag), LangOpts(LangOpts) { } in CXStoredDiagnostic()
DCXSourceLocation.h30 translateSourceLocation(const SourceManager &SM, const LangOptions &LangOpts, in translateSourceLocation() argument
35 CXSourceLocation Result = { { &SM, &LangOpts, }, in translateSourceLocation()
55 const LangOptions &LangOpts,
DCXStoredDiagnostic.cpp49 LangOpts, Diag.getLocation()); in getLocation()
93 LangOpts, in getRange()
111 LangOpts, Hint.RemoveRange); in getFixIt()
/external/clang/include/clang/Rewrite/Core/
DRewriter.h129 const LangOptions *LangOpts; variable
153 : SourceMgr(&SM), LangOpts(&LO) {} in Rewriter()
154 explicit Rewriter() : SourceMgr(nullptr), LangOpts(nullptr) {} in Rewriter()
158 LangOpts = &LO; in setSourceMgr()
161 const LangOptions &getLangOpts() const { return *LangOpts; } in getLangOpts()
/external/clang/include/clang/Frontend/
DDiagnosticRenderer.h48 const LangOptions &LangOpts;
70 DiagnosticRenderer(const LangOptions &LangOpts,
155 DiagnosticNoteRenderer(const LangOptions &LangOpts, in DiagnosticNoteRenderer() argument
157 : DiagnosticRenderer(LangOpts, DiagOpts) {} in DiagnosticNoteRenderer()
DCompilerInvocation.h57 std::shared_ptr<LangOptions> LangOpts;
76 LangOptions *getLangOpts() { return LangOpts.get(); } in getLangOpts()
77 const LangOptions *getLangOpts() const { return LangOpts.get(); } in getLangOpts()
/external/clang/unittests/Basic/
DSourceManagerTest.cpp49 LangOptions LangOpts; member in __anonc0f8f66c0111::SourceManagerTest
82 HeaderSearch HeaderInfo(new HeaderSearchOptions, SourceMgr, Diags, LangOpts, in TEST_F()
84 Preprocessor PP(new PreprocessorOptions(), Diags, LangOpts, SourceMgr, in TEST_F()
199 HeaderSearch HeaderInfo(new HeaderSearchOptions, SourceMgr, Diags, LangOpts, in TEST_F()
201 Preprocessor PP(new PreprocessorOptions(), Diags, LangOpts, SourceMgr, in TEST_F()
297 HeaderSearch HeaderInfo(new HeaderSearchOptions, SourceMgr, Diags, LangOpts, in TEST_F()
299 Preprocessor PP(new PreprocessorOptions(), Diags, LangOpts, SourceMgr, in TEST_F()
/external/clang/lib/ARCMigrate/
DPlistReporter.cpp38 const LangOptions &LangOpts) { in writeARCDiagsToPlist() argument
103 EmitLocation(o, SM, LangOpts, D.getLocation(), FM, 2); in writeARCDiagsToPlist()
112 EmitRange(o, SM, LangOpts, *RI, FM, 4); in writeARCDiagsToPlist()
/external/clang/lib/Rewrite/Frontend/
DRewriteTest.cpp21 const LangOptions &LangOpts = PP.getLangOpts(); in DoRewriteTest() local
23 TokenRewriter Rewriter(SM.getMainFileID(), SM, LangOpts); in DoRewriteTest()

12345