MCPcopy Create free account
hub / github.com/KDAB/codebrowser / Initialize

Method Initialize

generator/main.cpp:163–170  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

161 }
162
163 virtual void Initialize(clang::ASTContext& Ctx) override {
164 annotator.setSourceMgr(Ctx.getSourceManager(), Ctx.getLangOpts());
165 annotator.setMangleContext(Ctx.createMangleContext());
166 ci.getPreprocessor().addPPCallbacks(maybe_unique(new PreprocessorCallback(
167 annotator, ci.getPreprocessor(), WasInDatabase == DatabaseType::ProcessFullDirectory)));
168 ci.getDiagnostics().setClient(new BrowserDiagnosticClient(annotator), true);
169 ci.getDiagnostics().setErrorLimit(0);
170 }
171
172 virtual bool HandleTopLevelDecl(clang::DeclGroupRef D) override {
173 if (ci.getDiagnostics().hasFatalErrorOccurred()) {

Callers

nothing calls this directly

Calls 3

maybe_uniqueFunction · 0.85
setSourceMgrMethod · 0.80
setMangleContextMethod · 0.80

Tested by

no test coverage detected