|
@@ -23,15 +23,15 @@ class Module;
|
|
//===----------------------------------------------------------------------===//
|
|
//===----------------------------------------------------------------------===//
|
|
|
|
|
|
class InitOnlyAction : public FrontendAction {
|
|
class InitOnlyAction : public FrontendAction {
|
|
- virtual void ExecuteAction();
|
|
|
|
|
|
+ void ExecuteAction() override;
|
|
|
|
|
|
- virtual ASTConsumer *CreateASTConsumer(CompilerInstance &CI,
|
|
|
|
- StringRef InFile);
|
|
|
|
|
|
+ ASTConsumer *CreateASTConsumer(CompilerInstance &CI,
|
|
|
|
+ StringRef InFile) override;
|
|
|
|
|
|
public:
|
|
public:
|
|
// Don't claim to only use the preprocessor, we want to follow the AST path,
|
|
// Don't claim to only use the preprocessor, we want to follow the AST path,
|
|
// but do nothing.
|
|
// but do nothing.
|
|
- virtual bool usesPreprocessorOnly() const { return false; }
|
|
|
|
|
|
+ bool usesPreprocessorOnly() const override { return false; }
|
|
};
|
|
};
|
|
|
|
|
|
//===----------------------------------------------------------------------===//
|
|
//===----------------------------------------------------------------------===//
|
|
@@ -40,44 +40,44 @@ public:
|
|
|
|
|
|
class ASTPrintAction : public ASTFrontendAction {
|
|
class ASTPrintAction : public ASTFrontendAction {
|
|
protected:
|
|
protected:
|
|
- virtual ASTConsumer *CreateASTConsumer(CompilerInstance &CI,
|
|
|
|
- StringRef InFile);
|
|
|
|
|
|
+ ASTConsumer *CreateASTConsumer(CompilerInstance &CI,
|
|
|
|
+ StringRef InFile) override;
|
|
};
|
|
};
|
|
|
|
|
|
class ASTDumpAction : public ASTFrontendAction {
|
|
class ASTDumpAction : public ASTFrontendAction {
|
|
protected:
|
|
protected:
|
|
- virtual ASTConsumer *CreateASTConsumer(CompilerInstance &CI,
|
|
|
|
- StringRef InFile);
|
|
|
|
|
|
+ ASTConsumer *CreateASTConsumer(CompilerInstance &CI,
|
|
|
|
+ StringRef InFile) override;
|
|
};
|
|
};
|
|
|
|
|
|
class ASTDeclListAction : public ASTFrontendAction {
|
|
class ASTDeclListAction : public ASTFrontendAction {
|
|
protected:
|
|
protected:
|
|
- virtual ASTConsumer *CreateASTConsumer(CompilerInstance &CI,
|
|
|
|
- StringRef InFile);
|
|
|
|
|
|
+ ASTConsumer *CreateASTConsumer(CompilerInstance &CI,
|
|
|
|
+ StringRef InFile) override;
|
|
};
|
|
};
|
|
|
|
|
|
class ASTViewAction : public ASTFrontendAction {
|
|
class ASTViewAction : public ASTFrontendAction {
|
|
protected:
|
|
protected:
|
|
- virtual ASTConsumer *CreateASTConsumer(CompilerInstance &CI,
|
|
|
|
- StringRef InFile);
|
|
|
|
|
|
+ ASTConsumer *CreateASTConsumer(CompilerInstance &CI,
|
|
|
|
+ StringRef InFile) override;
|
|
};
|
|
};
|
|
|
|
|
|
class DeclContextPrintAction : public ASTFrontendAction {
|
|
class DeclContextPrintAction : public ASTFrontendAction {
|
|
protected:
|
|
protected:
|
|
- virtual ASTConsumer *CreateASTConsumer(CompilerInstance &CI,
|
|
|
|
- StringRef InFile);
|
|
|
|
|
|
+ ASTConsumer *CreateASTConsumer(CompilerInstance &CI,
|
|
|
|
+ StringRef InFile) override;
|
|
};
|
|
};
|
|
|
|
|
|
class GeneratePCHAction : public ASTFrontendAction {
|
|
class GeneratePCHAction : public ASTFrontendAction {
|
|
protected:
|
|
protected:
|
|
- virtual ASTConsumer *CreateASTConsumer(CompilerInstance &CI,
|
|
|
|
- StringRef InFile);
|
|
|
|
|
|
+ ASTConsumer *CreateASTConsumer(CompilerInstance &CI,
|
|
|
|
+ StringRef InFile) override;
|
|
|
|
|
|
- virtual TranslationUnitKind getTranslationUnitKind() {
|
|
|
|
|
|
+ TranslationUnitKind getTranslationUnitKind() override {
|
|
return TU_Prefix;
|
|
return TU_Prefix;
|
|
}
|
|
}
|
|
|
|
|
|
- virtual bool hasASTFileSupport() const { return false; }
|
|
|
|
|
|
+ bool hasASTFileSupport() const override { return false; }
|
|
|
|
|
|
public:
|
|
public:
|
|
/// \brief Compute the AST consumer arguments that will be used to
|
|
/// \brief Compute the AST consumer arguments that will be used to
|
|
@@ -96,21 +96,21 @@ class GenerateModuleAction : public ASTFrontendAction {
|
|
bool IsSystem;
|
|
bool IsSystem;
|
|
|
|
|
|
protected:
|
|
protected:
|
|
- virtual ASTConsumer *CreateASTConsumer(CompilerInstance &CI,
|
|
|
|
- StringRef InFile);
|
|
|
|
-
|
|
|
|
- virtual TranslationUnitKind getTranslationUnitKind() {
|
|
|
|
|
|
+ ASTConsumer *CreateASTConsumer(CompilerInstance &CI,
|
|
|
|
+ StringRef InFile) override;
|
|
|
|
+
|
|
|
|
+ TranslationUnitKind getTranslationUnitKind() override {
|
|
return TU_Module;
|
|
return TU_Module;
|
|
}
|
|
}
|
|
-
|
|
|
|
- virtual bool hasASTFileSupport() const { return false; }
|
|
|
|
-
|
|
|
|
|
|
+
|
|
|
|
+ bool hasASTFileSupport() const override { return false; }
|
|
|
|
+
|
|
public:
|
|
public:
|
|
explicit GenerateModuleAction(bool IsSystem = false)
|
|
explicit GenerateModuleAction(bool IsSystem = false)
|
|
: ASTFrontendAction(), IsSystem(IsSystem) { }
|
|
: ASTFrontendAction(), IsSystem(IsSystem) { }
|
|
|
|
|
|
- virtual bool BeginSourceFileAction(CompilerInstance &CI, StringRef Filename);
|
|
|
|
-
|
|
|
|
|
|
+ bool BeginSourceFileAction(CompilerInstance &CI, StringRef Filename) override;
|
|
|
|
+
|
|
/// \brief Compute the AST consumer arguments that will be used to
|
|
/// \brief Compute the AST consumer arguments that will be used to
|
|
/// create the PCHGenerator instance returned by CreateASTConsumer.
|
|
/// create the PCHGenerator instance returned by CreateASTConsumer.
|
|
///
|
|
///
|
|
@@ -124,37 +124,37 @@ public:
|
|
|
|
|
|
class SyntaxOnlyAction : public ASTFrontendAction {
|
|
class SyntaxOnlyAction : public ASTFrontendAction {
|
|
protected:
|
|
protected:
|
|
- virtual ASTConsumer *CreateASTConsumer(CompilerInstance &CI,
|
|
|
|
- StringRef InFile);
|
|
|
|
|
|
+ ASTConsumer *CreateASTConsumer(CompilerInstance &CI,
|
|
|
|
+ StringRef InFile) override;
|
|
|
|
|
|
public:
|
|
public:
|
|
- virtual bool hasCodeCompletionSupport() const { return true; }
|
|
|
|
|
|
+ bool hasCodeCompletionSupport() const override { return true; }
|
|
};
|
|
};
|
|
|
|
|
|
/// \brief Dump information about the given module file, to be used for
|
|
/// \brief Dump information about the given module file, to be used for
|
|
/// basic debugging and discovery.
|
|
/// basic debugging and discovery.
|
|
class DumpModuleInfoAction : public ASTFrontendAction {
|
|
class DumpModuleInfoAction : public ASTFrontendAction {
|
|
protected:
|
|
protected:
|
|
- virtual ASTConsumer *CreateASTConsumer(CompilerInstance &CI,
|
|
|
|
- StringRef InFile);
|
|
|
|
- virtual void ExecuteAction();
|
|
|
|
-
|
|
|
|
|
|
+ ASTConsumer *CreateASTConsumer(CompilerInstance &CI,
|
|
|
|
+ StringRef InFile) override;
|
|
|
|
+ void ExecuteAction() override;
|
|
|
|
+
|
|
public:
|
|
public:
|
|
- virtual bool hasPCHSupport() const { return false; }
|
|
|
|
- virtual bool hasASTFileSupport() const { return true; }
|
|
|
|
- virtual bool hasIRSupport() const { return false; }
|
|
|
|
- virtual bool hasCodeCompletionSupport() const { return false; }
|
|
|
|
|
|
+ bool hasPCHSupport() const override { return false; }
|
|
|
|
+ bool hasASTFileSupport() const override { return true; }
|
|
|
|
+ bool hasIRSupport() const override { return false; }
|
|
|
|
+ bool hasCodeCompletionSupport() const override { return false; }
|
|
};
|
|
};
|
|
|
|
|
|
class VerifyPCHAction : public ASTFrontendAction {
|
|
class VerifyPCHAction : public ASTFrontendAction {
|
|
protected:
|
|
protected:
|
|
- virtual ASTConsumer *CreateASTConsumer(CompilerInstance &CI,
|
|
|
|
- StringRef InFile);
|
|
|
|
|
|
+ ASTConsumer *CreateASTConsumer(CompilerInstance &CI,
|
|
|
|
+ StringRef InFile) override;
|
|
|
|
|
|
- virtual void ExecuteAction();
|
|
|
|
|
|
+ void ExecuteAction() override;
|
|
|
|
|
|
public:
|
|
public:
|
|
- virtual bool hasCodeCompletionSupport() const { return false; }
|
|
|
|
|
|
+ bool hasCodeCompletionSupport() const override { return false; }
|
|
};
|
|
};
|
|
|
|
|
|
/**
|
|
/**
|
|
@@ -173,34 +173,34 @@ class ASTMergeAction : public FrontendAction {
|
|
std::vector<std::string> ASTFiles;
|
|
std::vector<std::string> ASTFiles;
|
|
|
|
|
|
protected:
|
|
protected:
|
|
- virtual ASTConsumer *CreateASTConsumer(CompilerInstance &CI,
|
|
|
|
- StringRef InFile);
|
|
|
|
|
|
+ ASTConsumer *CreateASTConsumer(CompilerInstance &CI,
|
|
|
|
+ StringRef InFile) override;
|
|
|
|
|
|
- virtual bool BeginSourceFileAction(CompilerInstance &CI,
|
|
|
|
- StringRef Filename);
|
|
|
|
|
|
+ bool BeginSourceFileAction(CompilerInstance &CI,
|
|
|
|
+ StringRef Filename) override;
|
|
|
|
|
|
- virtual void ExecuteAction();
|
|
|
|
- virtual void EndSourceFileAction();
|
|
|
|
|
|
+ void ExecuteAction() override;
|
|
|
|
+ void EndSourceFileAction() override;
|
|
|
|
|
|
public:
|
|
public:
|
|
ASTMergeAction(FrontendAction *AdaptedAction, ArrayRef<std::string> ASTFiles);
|
|
ASTMergeAction(FrontendAction *AdaptedAction, ArrayRef<std::string> ASTFiles);
|
|
virtual ~ASTMergeAction();
|
|
virtual ~ASTMergeAction();
|
|
|
|
|
|
- virtual bool usesPreprocessorOnly() const;
|
|
|
|
- virtual TranslationUnitKind getTranslationUnitKind();
|
|
|
|
- virtual bool hasPCHSupport() const;
|
|
|
|
- virtual bool hasASTFileSupport() const;
|
|
|
|
- virtual bool hasCodeCompletionSupport() const;
|
|
|
|
|
|
+ bool usesPreprocessorOnly() const override;
|
|
|
|
+ TranslationUnitKind getTranslationUnitKind() override;
|
|
|
|
+ bool hasPCHSupport() const override;
|
|
|
|
+ bool hasASTFileSupport() const override;
|
|
|
|
+ bool hasCodeCompletionSupport() const override;
|
|
};
|
|
};
|
|
|
|
|
|
class PrintPreambleAction : public FrontendAction {
|
|
class PrintPreambleAction : public FrontendAction {
|
|
protected:
|
|
protected:
|
|
- void ExecuteAction();
|
|
|
|
- virtual ASTConsumer *CreateASTConsumer(CompilerInstance &, StringRef) {
|
|
|
|
- return 0;
|
|
|
|
|
|
+ void ExecuteAction() override;
|
|
|
|
+ ASTConsumer *CreateASTConsumer(CompilerInstance &, StringRef) override {
|
|
|
|
+ return 0;
|
|
}
|
|
}
|
|
-
|
|
|
|
- virtual bool usesPreprocessorOnly() const { return true; }
|
|
|
|
|
|
+
|
|
|
|
+ bool usesPreprocessorOnly() const override { return true; }
|
|
};
|
|
};
|
|
|
|
|
|
//===----------------------------------------------------------------------===//
|
|
//===----------------------------------------------------------------------===//
|
|
@@ -209,29 +209,29 @@ protected:
|
|
|
|
|
|
class DumpRawTokensAction : public PreprocessorFrontendAction {
|
|
class DumpRawTokensAction : public PreprocessorFrontendAction {
|
|
protected:
|
|
protected:
|
|
- void ExecuteAction();
|
|
|
|
|
|
+ void ExecuteAction() override;
|
|
};
|
|
};
|
|
|
|
|
|
class DumpTokensAction : public PreprocessorFrontendAction {
|
|
class DumpTokensAction : public PreprocessorFrontendAction {
|
|
protected:
|
|
protected:
|
|
- void ExecuteAction();
|
|
|
|
|
|
+ void ExecuteAction() override;
|
|
};
|
|
};
|
|
|
|
|
|
class GeneratePTHAction : public PreprocessorFrontendAction {
|
|
class GeneratePTHAction : public PreprocessorFrontendAction {
|
|
protected:
|
|
protected:
|
|
- void ExecuteAction();
|
|
|
|
|
|
+ void ExecuteAction() override;
|
|
};
|
|
};
|
|
|
|
|
|
class PreprocessOnlyAction : public PreprocessorFrontendAction {
|
|
class PreprocessOnlyAction : public PreprocessorFrontendAction {
|
|
protected:
|
|
protected:
|
|
- void ExecuteAction();
|
|
|
|
|
|
+ void ExecuteAction() override;
|
|
};
|
|
};
|
|
|
|
|
|
class PrintPreprocessedAction : public PreprocessorFrontendAction {
|
|
class PrintPreprocessedAction : public PreprocessorFrontendAction {
|
|
protected:
|
|
protected:
|
|
- void ExecuteAction();
|
|
|
|
|
|
+ void ExecuteAction() override;
|
|
|
|
|
|
- virtual bool hasPCHSupport() const { return true; }
|
|
|
|
|
|
+ bool hasPCHSupport() const override { return true; }
|
|
};
|
|
};
|
|
|
|
|
|
} // end namespace clang
|
|
} // end namespace clang
|