swift-module-digester: refactor the ABI/API diagnostics to use DiagnosticEngine. NFC (#18957)

Before this patch, we used to define tooling-specific diagnostics. With adding more
checking logics, we found this mechanism hard to extend. This patch
eliminates the home-made diagnostics model to use the one from compiler, which provides
several benefits: less boiler-templates, better integration with DiagnosticConsumer,
and easy ordering of detected issues.
This commit is contained in:
Xi Ge
2018-08-24 13:11:32 -07:00
committed by GitHub
parent 574b7f45be
commit e4388af6be
15 changed files with 349 additions and 290 deletions

View File

@@ -139,6 +139,7 @@ struct CheckerOptions {
bool ABI;
bool Verbose;
bool AbortOnModuleLoadFailure;
bool PrintModule;
StringRef LocationFilter;
};
@@ -303,6 +304,7 @@ public:
bool hasDeclAttribute(DeclAttrKind DAKind) const;
bool isStatic() const { return IsStatic; };
StringRef getGenericSignature() const { return GenericSig; }
StringRef getScreenInfo() const;
};
class SDKNodeRoot: public SDKNode {