Skip to content

Commit 668841c

Browse files
committed
C++: Rename diagnostic queries.
1 parent e482d21 commit 668841c

File tree

5 files changed

+20
-20
lines changed

5 files changed

+20
-20
lines changed
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
/**
2+
* @name Extraction errors
3+
* @description List all extraction errors for files in the source code directory.
4+
* @kind diagnostic
5+
* @id cpp/diagnostics/extraction-errors
6+
*/
7+
8+
import cpp
9+
import ExtractionErrors
10+
11+
from ExtractionError error
12+
where
13+
error instanceof ExtractionUnknownError or
14+
exists(error.getFile().getRelativePath())
15+
select error, "Extraction failed in " + error.getFile() + " with error " + error.getErrorMessage(),
16+
error.getSeverity()

cpp/ql/src/Diagnostics/FailedExtractions.qll renamed to cpp/ql/src/Diagnostics/ExtractionErrors.qll

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,12 +12,12 @@ import cpp
1212
* Thus, if the extractor emitted at least one diagnostic of severity discretionary
1313
* error (or higher), it *also* emits a simple "There was an error during this compilation"
1414
* error diagnostic, without location information.
15-
* In the common case, this means that a file with one (or more) errors also gets
15+
* In the common case, this means that a compilation during which one or more errors happened also gets
1616
* the catch-all diagnostic.
1717
* This diagnostic has the empty string as file path.
1818
* We filter out these useless diagnostics if there is at least one error-level diagnostic
1919
* for the affected compilation in the database.
20-
* Otherwise, we show it to, to indicate that something went wrong, and we
20+
* Otherwise, we show it to indicate that something went wrong and that we
2121
* don't know what exactly happened.
2222
*/
2323

cpp/ql/src/Diagnostics/FailedExtractions.ql

Lines changed: 0 additions & 16 deletions
This file was deleted.

cpp/ql/src/Diagnostics/SuccessfulExtractions.ql renamed to cpp/ql/src/Diagnostics/SuccessfullyExtractedFiles.ql

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
11
/**
22
* @name Successfully extracted files
3-
* @description Lists all files in the source code directory that were extracted without encountering an error.
3+
* @description Lists all files in the source code directory that were extracted without encountering an error in the file.
44
* @kind diagnostic
55
* @id cpp/diagnostics/successfully-extracted-files
66
*/
77

88
import cpp
9-
import FailedExtractions
9+
import ExtractionErrors
1010

1111
from File f
1212
where

0 commit comments

Comments
 (0)