|
|
|
@ -10,6 +10,14 @@ namespace clang { |
|
|
|
friend class TranslationUnit; |
|
|
|
friend class TranslationUnit; |
|
|
|
Diagnostic(CXTranslationUnit& cx_tu, CXDiagnostic& cx_diagnostic); |
|
|
|
Diagnostic(CXTranslationUnit& cx_tu, CXDiagnostic& cx_diagnostic); |
|
|
|
public: |
|
|
|
public: |
|
|
|
|
|
|
|
class FixIt { |
|
|
|
|
|
|
|
public: |
|
|
|
|
|
|
|
FixIt(const std::string &source, const std::pair<clang::Offset, clang::Offset> &offsets): |
|
|
|
|
|
|
|
source(source), offsets(offsets) {} |
|
|
|
|
|
|
|
std::string source; |
|
|
|
|
|
|
|
std::pair<clang::Offset, clang::Offset> offsets; |
|
|
|
|
|
|
|
}; |
|
|
|
|
|
|
|
|
|
|
|
static const std::string get_severity_spelling(unsigned severity); |
|
|
|
static const std::string get_severity_spelling(unsigned severity); |
|
|
|
|
|
|
|
|
|
|
|
unsigned severity; |
|
|
|
unsigned severity; |
|
|
|
@ -17,6 +25,7 @@ namespace clang { |
|
|
|
std::string spelling; |
|
|
|
std::string spelling; |
|
|
|
std::string path; |
|
|
|
std::string path; |
|
|
|
std::pair<clang::Offset, clang::Offset> offsets; |
|
|
|
std::pair<clang::Offset, clang::Offset> offsets; |
|
|
|
|
|
|
|
std::vector<FixIt> fix_its; |
|
|
|
}; |
|
|
|
}; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|