File tree Expand file tree Collapse file tree 1 file changed +18
-0
lines changed
swift/ql/lib/codeql/swift/elements Expand file tree Collapse file tree 1 file changed +18
-0
lines changed Original file line number Diff line number Diff line change 11private import codeql.swift.generated.Diagnostics
22
3+ /**
4+ * A compiler-generated error, warning, note or remark.
5+ */
36class Diagnostics extends Generated:: Diagnostics {
47 override string toString ( ) { result = this .getSeverity ( ) + ": " + this .getText ( ) }
58
9+ /**
10+ * Gets a string representing the severity of this compiler diagnostic.
11+ */
612 string getSeverity ( ) {
713 this .getKind ( ) = 1 and result = "error"
814 or
@@ -14,18 +20,30 @@ class Diagnostics extends Generated::Diagnostics {
1420 }
1521}
1622
23+ /**
24+ * A compiler error message.
25+ */
1726class CompilerError extends Diagnostics {
1827 CompilerError ( ) { this .getSeverity ( ) = "error" }
1928}
2029
30+ /**
31+ * A compiler-generated warning.
32+ */
2133class CompilerWarning extends Diagnostics {
2234 CompilerWarning ( ) { this .getSeverity ( ) = "warning" }
2335}
2436
37+ /**
38+ * A compiler-generated note (typically attached to an error or warning).
39+ */
2540class CompilerNote extends Diagnostics {
2641 CompilerNote ( ) { this .getSeverity ( ) = "note" }
2742}
2843
44+ /**
45+ * A compiler-generated remark (milder than a warning, this does not indicate an issue).
46+ */
2947class CompilerRemark extends Diagnostics {
3048 CompilerRemark ( ) { this .getSeverity ( ) = "remark" }
3149}
You can’t perform that action at this time.
0 commit comments