diff options
author | Roman Divacky <rdivacky@FreeBSD.org> | 2010-05-04 16:12:48 +0000 |
---|---|---|
committer | Roman Divacky <rdivacky@FreeBSD.org> | 2010-05-04 16:12:48 +0000 |
commit | 0883ccd9eac3b974df00e6548ee319a7dd3646f4 (patch) | |
tree | d6a70c3518b8dea8be7062438d7e8676820ed17f /include/clang/Frontend/VerifyDiagnosticsClient.h | |
parent | 60bfabcd8ce617297c0d231f77d14ab507e98796 (diff) |
Notes
Diffstat (limited to 'include/clang/Frontend/VerifyDiagnosticsClient.h')
-rw-r--r-- | include/clang/Frontend/VerifyDiagnosticsClient.h | 19 |
1 files changed, 18 insertions, 1 deletions
diff --git a/include/clang/Frontend/VerifyDiagnosticsClient.h b/include/clang/Frontend/VerifyDiagnosticsClient.h index 08adbb04d1664..6f45e49ec0efe 100644 --- a/include/clang/Frontend/VerifyDiagnosticsClient.h +++ b/include/clang/Frontend/VerifyDiagnosticsClient.h @@ -25,7 +25,10 @@ class TextDiagnosticBuffer; /// USING THE DIAGNOSTIC CHECKER: /// /// Indicating that a line expects an error or a warning is simple. Put a -/// comment on the line that has the diagnostic, use "expected-{error,warning}" +/// comment on the line that has the diagnostic, use: +/// +/// expected-{error,warning,note} +/// /// to tag if it's an expected error or warning, and place the expected text /// between {{ and }} markers. The full text doesn't have to be included, only /// enough to ensure that the correct diagnostic was emitted. @@ -45,6 +48,20 @@ class TextDiagnosticBuffer; /// /// void f(); // expected-note 2 {{previous declaration is here}} /// +/// Regex matching mode may be selected by appending '-re' to type. Example: +/// +/// expected-error-re +/// +/// Examples matching error: "variable has incomplete type 'struct s'" +/// +/// // expected-error {{variable has incomplete type 'struct s'}} +/// // expected-error {{variable has incomplete type}} +/// +/// // expected-error-re {{variable has has type 'struct .'}} +/// // expected-error-re {{variable has has type 'struct .*'}} +/// // expected-error-re {{variable has has type 'struct (.*)'}} +/// // expected-error-re {{variable has has type 'struct[[:space:]](.*)'}} +/// class VerifyDiagnosticsClient : public DiagnosticClient { public: Diagnostic &Diags; |