File tree Expand file tree Collapse file tree 4 files changed +11
-3
lines changed Expand file tree Collapse file tree 4 files changed +11
-3
lines changed Original file line number Diff line number Diff line change @@ -37,7 +37,7 @@ public class Main {
37
37
* A version identifier that should be updated every time the extractor changes in such a way that
38
38
* it may produce different tuples for the same file under the same {@link ExtractorConfig}.
39
39
*/
40
- public static final String EXTRACTOR_VERSION = "2019-07-24 " ;
40
+ public static final String EXTRACTOR_VERSION = "2019-07-25 " ;
41
41
42
42
public static final Pattern NEWLINE = Pattern .compile ("\n " );
43
43
Original file line number Diff line number Diff line change @@ -99,6 +99,7 @@ public LoCInfo extract(TextualExtractor textualExtractor) {
99
99
trapWriter = textualExtractor .getTrapwriter ();
100
100
101
101
Label fileLabel = locationManager .getFileLabel ();
102
+ locationManager .setHasLocationTable ("yaml_locations" );
102
103
try {
103
104
parser = new ParserImpl (new StreamReader (textualExtractor .getSource ()));
104
105
resolver = new Resolver ();
Original file line number Diff line number Diff line change @@ -13,7 +13,7 @@ import javascript
13
13
* referring to some other YAML value.
14
14
*/
15
15
class YAMLNode extends @yaml_node, Locatable {
16
- override Location getLocation ( ) { hasLocation ( this , result ) }
16
+ override Location getLocation ( ) { yaml_locations ( this , result ) }
17
17
18
18
/**
19
19
* Gets the parent node of this node, which is always a collection.
@@ -300,6 +300,8 @@ class YAMLDocument extends YAMLNode {
300
300
* An error message produced by the YAML parser while processing a YAML file.
301
301
*/
302
302
class YAMLParseError extends @yaml_error, Error {
303
+ override Location getLocation ( ) { yaml_locations ( this , result ) }
304
+
303
305
override string getMessage ( ) { yaml_errors ( this , result ) }
304
306
305
307
override string toString ( ) { result = getMessage ( ) }
Original file line number Diff line number Diff line change @@ -933,7 +933,7 @@ case @json_value.kind of
933
933
| @token
934
934
| @cfg_node
935
935
| @jsdoc | @jsdoc_type_expr | @jsdoc_tag
936
- | @yaml_node | @yaml_error
936
+ | @yaml_locatable
937
937
| @xmllocatable;
938
938
939
939
hasLocation (unique int locatable: @locatable ref,
@@ -1027,6 +1027,11 @@ yaml_scalars (unique int scalar: @yaml_scalar_node ref,
1027
1027
yaml_errors (unique int id: @yaml_error,
1028
1028
varchar(900) message: string ref);
1029
1029
1030
+ yaml_locations(unique int locatable: @yaml_locatable ref,
1031
+ int ___location: @location_default ref);
1032
+
1033
+ @yaml_locatable = @yaml_node | @yaml_error;
1034
+
1030
1035
/* XML Files */
1031
1036
1032
1037
xmlEncoding(
You can’t perform that action at this time.
0 commit comments