File tree Expand file tree Collapse file tree 2 files changed +18
-18
lines changed Expand file tree Collapse file tree 2 files changed +18
-18
lines changed Original file line number Diff line number Diff line change 2
2
3
3
private import codeql.Locations
4
4
private import codeql.util.FileSystem
5
- private import codeql.ruby.Diagnostics
6
5
7
6
private module Input implements InputSig {
8
7
abstract class ContainerBase extends @container {
@@ -35,20 +34,3 @@ class File extends Container, Impl::File {
35
34
/** Holds if this file was extracted from ordinary source code. */
36
35
predicate fromSource ( ) { any ( ) }
37
36
}
38
-
39
- /**
40
- * A successfully extracted file, that is, a file that was extracted and
41
- * contains no extraction errors or warnings.
42
- */
43
- class SuccessfullyExtractedFile extends File {
44
- SuccessfullyExtractedFile ( ) {
45
- not exists ( Diagnostic d |
46
- d .getLocation ( ) .getFile ( ) = this and
47
- (
48
- d instanceof ExtractionError
49
- or
50
- d instanceof ExtractionWarning
51
- )
52
- )
53
- }
54
- }
Original file line number Diff line number Diff line change @@ -18,6 +18,7 @@ private import ast.internal.Scope
18
18
private import ast.internal.Synthesis
19
19
private import ast.internal.TreeSitter
20
20
private import Customizations
21
+ private import Diagnostics
21
22
22
23
cached
23
24
private module Cached {
@@ -166,3 +167,20 @@ class RubyFile extends File {
166
167
/** Gets the number of lines of comments in this file. */
167
168
int getNumberOfLinesOfComments ( ) { result = count ( int line | this .line ( line , true ) ) }
168
169
}
170
+
171
+ /**
172
+ * A successfully extracted file, that is, a file that was extracted and
173
+ * contains no extraction errors or warnings.
174
+ */
175
+ class SuccessfullyExtractedFile extends RubyFile {
176
+ SuccessfullyExtractedFile ( ) {
177
+ not exists ( Diagnostic d |
178
+ d .getLocation ( ) .getFile ( ) = this and
179
+ (
180
+ d instanceof ExtractionError
181
+ or
182
+ d instanceof ExtractionWarning
183
+ )
184
+ )
185
+ }
186
+ }
You can’t perform that action at this time.
0 commit comments