dot-language-support 2.3.0 → 3.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.ts +497 -0
- package/dist/index.js +3853 -0
- package/package.json +10 -11
- package/.github/dependabot.yml +0 -15
- package/.github/workflows/CD.yml +0 -37
- package/.github/workflows/CI.yml +0 -28
- package/.github/workflows/auto-merge.yaml +0 -26
- package/CITATION.cff +0 -14
- package/biome.json +0 -48
- package/lib/cjs/binder.d.ts +0 -2
- package/lib/cjs/binder.js +0 -297
- package/lib/cjs/checker.d.ts +0 -15
- package/lib/cjs/checker.js +0 -228
- package/lib/cjs/core.d.ts +0 -1
- package/lib/cjs/core.js +0 -13
- package/lib/cjs/error.d.ts +0 -3
- package/lib/cjs/error.js +0 -12
- package/lib/cjs/index.d.ts +0 -5
- package/lib/cjs/index.js +0 -22
- package/lib/cjs/parser.d.ts +0 -27
- package/lib/cjs/parser.js +0 -664
- package/lib/cjs/scanner.d.ts +0 -41
- package/lib/cjs/scanner.js +0 -578
- package/lib/cjs/service/codeAction.d.ts +0 -12
- package/lib/cjs/service/codeAction.js +0 -245
- package/lib/cjs/service/colorProvider.d.ts +0 -5
- package/lib/cjs/service/colorProvider.js +0 -91
- package/lib/cjs/service/command/ChangeAllOtherEdgeOpsAndFixGraphCommand.d.ts +0 -10
- package/lib/cjs/service/command/ChangeAllOtherEdgeOpsAndFixGraphCommand.js +0 -42
- package/lib/cjs/service/command/ChangeEdgeOpCommand.d.ts +0 -10
- package/lib/cjs/service/command/ChangeEdgeOpCommand.js +0 -67
- package/lib/cjs/service/command/ConsolidateDescendantsCommand.d.ts +0 -10
- package/lib/cjs/service/command/ConsolidateDescendantsCommand.js +0 -87
- package/lib/cjs/service/command/RemoveSemicolons.d.ts +0 -10
- package/lib/cjs/service/command/RemoveSemicolons.js +0 -39
- package/lib/cjs/service/command/common.d.ts +0 -31
- package/lib/cjs/service/command/common.js +0 -33
- package/lib/cjs/service/completion.d.ts +0 -4
- package/lib/cjs/service/completion.js +0 -173
- package/lib/cjs/service/hover.d.ts +0 -4
- package/lib/cjs/service/hover.js +0 -142
- package/lib/cjs/service/languageFacts.d.ts +0 -683
- package/lib/cjs/service/languageFacts.js +0 -996
- package/lib/cjs/service/reference.d.ts +0 -5
- package/lib/cjs/service/reference.js +0 -67
- package/lib/cjs/service/rename.d.ts +0 -4
- package/lib/cjs/service/rename.js +0 -51
- package/lib/cjs/service/service.d.ts +0 -28
- package/lib/cjs/service/service.js +0 -38
- package/lib/cjs/service/util.d.ts +0 -11
- package/lib/cjs/service/util.js +0 -49
- package/lib/cjs/service/validation.d.ts +0 -4
- package/lib/cjs/service/validation.js +0 -23
- package/lib/cjs/tester.d.ts +0 -1
- package/lib/cjs/tester.js +0 -23
- package/lib/cjs/types.d.ts +0 -397
- package/lib/cjs/types.js +0 -74
- package/lib/cjs/visitor.d.ts +0 -2
- package/lib/cjs/visitor.js +0 -76
- package/lib/esm/binder.d.ts +0 -2
- package/lib/esm/binder.js +0 -294
- package/lib/esm/checker.d.ts +0 -15
- package/lib/esm/checker.js +0 -212
- package/lib/esm/core.d.ts +0 -1
- package/lib/esm/core.js +0 -10
- package/lib/esm/error.d.ts +0 -3
- package/lib/esm/error.js +0 -8
- package/lib/esm/index.d.ts +0 -5
- package/lib/esm/index.js +0 -6
- package/lib/esm/parser.d.ts +0 -27
- package/lib/esm/parser.js +0 -714
- package/lib/esm/scanner.d.ts +0 -41
- package/lib/esm/scanner.js +0 -581
- package/lib/esm/service/codeAction.d.ts +0 -12
- package/lib/esm/service/codeAction.js +0 -207
- package/lib/esm/service/colorProvider.d.ts +0 -5
- package/lib/esm/service/colorProvider.js +0 -54
- package/lib/esm/service/command/ChangeAllOtherEdgeOpsAndFixGraphCommand.d.ts +0 -10
- package/lib/esm/service/command/ChangeAllOtherEdgeOpsAndFixGraphCommand.js +0 -38
- package/lib/esm/service/command/ChangeEdgeOpCommand.d.ts +0 -10
- package/lib/esm/service/command/ChangeEdgeOpCommand.js +0 -30
- package/lib/esm/service/command/ConsolidateDescendantsCommand.d.ts +0 -10
- package/lib/esm/service/command/ConsolidateDescendantsCommand.js +0 -83
- package/lib/esm/service/command/RemoveSemicolons.d.ts +0 -10
- package/lib/esm/service/command/RemoveSemicolons.js +0 -35
- package/lib/esm/service/command/common.d.ts +0 -31
- package/lib/esm/service/command/common.js +0 -25
- package/lib/esm/service/completion.d.ts +0 -4
- package/lib/esm/service/completion.js +0 -137
- package/lib/esm/service/hover.d.ts +0 -4
- package/lib/esm/service/hover.js +0 -135
- package/lib/esm/service/languageFacts.d.ts +0 -683
- package/lib/esm/service/languageFacts.js +0 -993
- package/lib/esm/service/reference.d.ts +0 -5
- package/lib/esm/service/reference.js +0 -63
- package/lib/esm/service/rename.d.ts +0 -4
- package/lib/esm/service/rename.js +0 -48
- package/lib/esm/service/service.d.ts +0 -28
- package/lib/esm/service/service.js +0 -35
- package/lib/esm/service/util.d.ts +0 -11
- package/lib/esm/service/util.js +0 -42
- package/lib/esm/service/validation.d.ts +0 -4
- package/lib/esm/service/validation.js +0 -20
- package/lib/esm/tester.d.ts +0 -1
- package/lib/esm/tester.js +0 -21
- package/lib/esm/types.d.ts +0 -397
- package/lib/esm/types.js +0 -71
- package/lib/esm/visitor.d.ts +0 -2
- package/lib/esm/visitor.js +0 -73
package/lib/cjs/checker.js
DELETED
|
@@ -1,228 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.checkSourceFile = checkSourceFile;
|
|
4
|
-
exports.findNodeAtOffset = findNodeAtOffset;
|
|
5
|
-
exports.getAllowedEdgeOperation = getAllowedEdgeOperation;
|
|
6
|
-
exports.findAllEdges = findAllEdges;
|
|
7
|
-
exports.findOptionalSemicolons = findOptionalSemicolons;
|
|
8
|
-
exports.findAllStatements = findAllStatements;
|
|
9
|
-
exports.isAttrStatement = isAttrStatement;
|
|
10
|
-
exports.isEdgeStatement = isEdgeStatement;
|
|
11
|
-
exports.isSubGraphStatement = isSubGraphStatement;
|
|
12
|
-
exports.isGraph = isGraph;
|
|
13
|
-
exports.isNodeId = isNodeId;
|
|
14
|
-
exports.edgeStatementHasAttributes = edgeStatementHasAttributes;
|
|
15
|
-
exports.getIdentifierText = getIdentifierText;
|
|
16
|
-
exports.nodeContainsErrors = nodeContainsErrors;
|
|
17
|
-
const languageFacts_js_1 = require("./service/languageFacts.js");
|
|
18
|
-
const util_js_1 = require("./service/util.js");
|
|
19
|
-
const types_js_1 = require("./types.js");
|
|
20
|
-
const visitor_js_1 = require("./visitor.js");
|
|
21
|
-
function checkSourceFile(file) {
|
|
22
|
-
const g = file.graph;
|
|
23
|
-
if (g) {
|
|
24
|
-
const messages = checkGraphSemantics(file, g);
|
|
25
|
-
if (messages) {
|
|
26
|
-
file.diagnostics.push.apply(file.diagnostics, messages);
|
|
27
|
-
}
|
|
28
|
-
}
|
|
29
|
-
}
|
|
30
|
-
function getNarrowerNode(offset, prev, toCheck) {
|
|
31
|
-
const prevRange = prev.end - prev.pos;
|
|
32
|
-
if (toCheck.pos <= offset && offset <= toCheck.end) {
|
|
33
|
-
const nrange = toCheck.end - toCheck.pos;
|
|
34
|
-
if (nrange < prevRange) {
|
|
35
|
-
return toCheck;
|
|
36
|
-
}
|
|
37
|
-
}
|
|
38
|
-
return prev;
|
|
39
|
-
}
|
|
40
|
-
function rangeContainsOffset(range, offset, inclusiveEnd) {
|
|
41
|
-
return inclusiveEnd
|
|
42
|
-
? range.pos <= offset && offset <= range.end
|
|
43
|
-
: range.pos <= offset && offset < range.end;
|
|
44
|
-
}
|
|
45
|
-
function findNodeAtOffset(root, offset, inclusiveEnd = false) {
|
|
46
|
-
if (root.pos === offset && root.pos === root.end)
|
|
47
|
-
return root;
|
|
48
|
-
if (rangeContainsOffset(root, offset, inclusiveEnd)) {
|
|
49
|
-
const narrowerChild = (0, visitor_js_1.forEachChild)(root, child => findNodeAtOffset(child, offset, inclusiveEnd));
|
|
50
|
-
return narrowerChild ? narrowerChild : root;
|
|
51
|
-
}
|
|
52
|
-
return undefined;
|
|
53
|
-
}
|
|
54
|
-
function getAllowedEdgeOperation(graph) {
|
|
55
|
-
return graph.kind === types_js_1.SyntaxKind.DirectedGraph
|
|
56
|
-
? types_js_1.SyntaxKind.DirectedEdgeOp
|
|
57
|
-
: types_js_1.SyntaxKind.UndirectedEdgeOp;
|
|
58
|
-
}
|
|
59
|
-
function checkGraphSemantics(file, root) {
|
|
60
|
-
const expectedEdgeOp = getAllowedEdgeOperation(root);
|
|
61
|
-
const invalidEdgeRhses = findEdgeErrors(expectedEdgeOp, root);
|
|
62
|
-
const invalidShapes = checkShapeLabelValues(root);
|
|
63
|
-
const invalidEdgeDiagnostics = invalidEdgeRhses === undefined || invalidEdgeRhses.length === 0
|
|
64
|
-
? []
|
|
65
|
-
: createEdgeViolationDiagnostics(file, expectedEdgeOp, invalidEdgeRhses);
|
|
66
|
-
return [...invalidEdgeDiagnostics, ...invalidShapes];
|
|
67
|
-
}
|
|
68
|
-
function forEachAssignmentTransitive(root, cb) {
|
|
69
|
-
(0, visitor_js_1.forEachChild)(root, child => {
|
|
70
|
-
if (child.kind === types_js_1.SyntaxKind.Assignment) {
|
|
71
|
-
cb(child);
|
|
72
|
-
return;
|
|
73
|
-
}
|
|
74
|
-
(0, visitor_js_1.forEachChild)(child, c => forEachAssignmentTransitive(c, cb));
|
|
75
|
-
});
|
|
76
|
-
}
|
|
77
|
-
function checkShapeLabelValues(root) {
|
|
78
|
-
const invalidShapes = [];
|
|
79
|
-
forEachAssignmentTransitive(root, assignment => {
|
|
80
|
-
const { leftId, rightId } = assignment;
|
|
81
|
-
if (leftId.kind !== types_js_1.SyntaxKind.TextIdentifier ||
|
|
82
|
-
rightId.kind !== types_js_1.SyntaxKind.TextIdentifier) {
|
|
83
|
-
return;
|
|
84
|
-
}
|
|
85
|
-
const leftText = leftId.text.trim();
|
|
86
|
-
if (leftText.toLocaleLowerCase() !== "shape") {
|
|
87
|
-
return;
|
|
88
|
-
}
|
|
89
|
-
const rightText = rightId.text.trim();
|
|
90
|
-
const shapeCandidate = rightText.toLowerCase();
|
|
91
|
-
if (languageFacts_js_1.shapes.includes(shapeCandidate)) {
|
|
92
|
-
return;
|
|
93
|
-
}
|
|
94
|
-
invalidShapes.push({
|
|
95
|
-
category: types_js_1.DiagnosticCategory.Warning,
|
|
96
|
-
code: createCheckerError(1),
|
|
97
|
-
message: `Unknown shape "${rightText}".`,
|
|
98
|
-
start: rightId.pos,
|
|
99
|
-
end: rightId.end,
|
|
100
|
-
});
|
|
101
|
-
});
|
|
102
|
-
return invalidShapes;
|
|
103
|
-
}
|
|
104
|
-
function findAllEdges(node) {
|
|
105
|
-
const allEdges = [];
|
|
106
|
-
(0, visitor_js_1.forEachChild)(node, child => {
|
|
107
|
-
if (isEdgeStatement(child)) {
|
|
108
|
-
if (child.rhs && child.rhs.length > 0) {
|
|
109
|
-
for (const edgeRhs of child.rhs)
|
|
110
|
-
allEdges.push(edgeRhs);
|
|
111
|
-
}
|
|
112
|
-
}
|
|
113
|
-
const childEdges = findAllEdges(child);
|
|
114
|
-
if (childEdges && childEdges.length > 0)
|
|
115
|
-
allEdges.push.apply(allEdges, childEdges);
|
|
116
|
-
});
|
|
117
|
-
return allEdges;
|
|
118
|
-
}
|
|
119
|
-
function findOptionalSemicolons(node) {
|
|
120
|
-
const statements = findAllStatements(node);
|
|
121
|
-
const terminators = statements.map(p => p.terminator);
|
|
122
|
-
return terminators.filter(t => !!t);
|
|
123
|
-
}
|
|
124
|
-
function isStatement(node) {
|
|
125
|
-
return (node.kind === types_js_1.SyntaxKind.SubGraphStatement ||
|
|
126
|
-
node.kind === types_js_1.SyntaxKind.EdgeStatement ||
|
|
127
|
-
node.kind === types_js_1.SyntaxKind.NodeStatement ||
|
|
128
|
-
node.kind === types_js_1.SyntaxKind.IdEqualsIdStatement ||
|
|
129
|
-
node.kind === types_js_1.SyntaxKind.AttributeStatement);
|
|
130
|
-
}
|
|
131
|
-
function findAllStatements(node, kind) {
|
|
132
|
-
const allStatements = [];
|
|
133
|
-
(0, visitor_js_1.forEachChild)(node, child => {
|
|
134
|
-
if ((kind === undefined && isStatement(child)) || child.kind === kind) {
|
|
135
|
-
allStatements.push(child);
|
|
136
|
-
}
|
|
137
|
-
const childStatements = findAllStatements(child, kind);
|
|
138
|
-
if (childStatements && childStatements.length > 0)
|
|
139
|
-
allStatements.push.apply(allStatements, childStatements);
|
|
140
|
-
});
|
|
141
|
-
return allStatements;
|
|
142
|
-
}
|
|
143
|
-
function findEdgeErrors(expectedEdgeOp, node) {
|
|
144
|
-
const edges = findAllEdges(node);
|
|
145
|
-
const wrongEdges = edges && edges.length > 0
|
|
146
|
-
? edges.filter(e => e.operation.kind !== expectedEdgeOp)
|
|
147
|
-
: undefined;
|
|
148
|
-
if (wrongEdges && wrongEdges.length > 0) {
|
|
149
|
-
for (const edge of wrongEdges) {
|
|
150
|
-
edge.operation.flags |= 2;
|
|
151
|
-
}
|
|
152
|
-
return wrongEdges;
|
|
153
|
-
}
|
|
154
|
-
return undefined;
|
|
155
|
-
}
|
|
156
|
-
function createEdgeViolationDiagnostics(file, expectedEdgeOp, violators) {
|
|
157
|
-
const op = expectedEdgeOp === types_js_1.SyntaxKind.UndirectedEdgeOp ? "--" : "->";
|
|
158
|
-
const graphType = expectedEdgeOp === types_js_1.SyntaxKind.UndirectedEdgeOp ? "undirected" : "directed";
|
|
159
|
-
const message = `Invalid edge operation, use "${op}" in ${graphType} graph`;
|
|
160
|
-
const code = createCheckerError(0);
|
|
161
|
-
const category = types_js_1.DiagnosticCategory.Error;
|
|
162
|
-
for (const edge of violators) {
|
|
163
|
-
edge.operation.flags |= 2;
|
|
164
|
-
}
|
|
165
|
-
return violators.map(edge => {
|
|
166
|
-
const start = (0, util_js_1.getStart)(file, edge.operation);
|
|
167
|
-
const end = edge.operation.end;
|
|
168
|
-
return {
|
|
169
|
-
message,
|
|
170
|
-
code,
|
|
171
|
-
category,
|
|
172
|
-
start,
|
|
173
|
-
end,
|
|
174
|
-
};
|
|
175
|
-
});
|
|
176
|
-
}
|
|
177
|
-
function getInvalidEdgeRhs(allowedOp, edges) {
|
|
178
|
-
const res = [];
|
|
179
|
-
for (const e of edges) {
|
|
180
|
-
if (e.operation.kind !== allowedOp)
|
|
181
|
-
res.push(e);
|
|
182
|
-
}
|
|
183
|
-
return res;
|
|
184
|
-
}
|
|
185
|
-
function isAttrStatement(node) {
|
|
186
|
-
return node.kind === types_js_1.SyntaxKind.AttributeStatement;
|
|
187
|
-
}
|
|
188
|
-
function isEdgeStatement(node) {
|
|
189
|
-
return node.kind === types_js_1.SyntaxKind.EdgeStatement;
|
|
190
|
-
}
|
|
191
|
-
function isSubGraphStatement(node) {
|
|
192
|
-
return node.kind === types_js_1.SyntaxKind.SubGraphStatement;
|
|
193
|
-
}
|
|
194
|
-
function isGraph(node) {
|
|
195
|
-
return node.kind === types_js_1.SyntaxKind.DirectedGraph || node.kind === types_js_1.SyntaxKind.UndirectedGraph;
|
|
196
|
-
}
|
|
197
|
-
function isNodeId(node) {
|
|
198
|
-
return node.kind === types_js_1.SyntaxKind.NodeId;
|
|
199
|
-
}
|
|
200
|
-
function edgeStatementHasAttributes(es) {
|
|
201
|
-
return (es.attributes &&
|
|
202
|
-
es.attributes.length > 0 &&
|
|
203
|
-
es.attributes.some(a => a.assignments && a.assignments.length > 0));
|
|
204
|
-
}
|
|
205
|
-
function getIdentifierText(n) {
|
|
206
|
-
switch (n.kind) {
|
|
207
|
-
case types_js_1.SyntaxKind.HtmlIdentifier:
|
|
208
|
-
return n.htmlContent;
|
|
209
|
-
case types_js_1.SyntaxKind.TextIdentifier:
|
|
210
|
-
return n.text;
|
|
211
|
-
case types_js_1.SyntaxKind.NumericIdentifier:
|
|
212
|
-
return n.text;
|
|
213
|
-
case types_js_1.SyntaxKind.QuotedTextIdentifier:
|
|
214
|
-
return n.concatenation;
|
|
215
|
-
default:
|
|
216
|
-
return (0, util_js_1.assertNever)(n);
|
|
217
|
-
}
|
|
218
|
-
}
|
|
219
|
-
function createCheckerError(sub) {
|
|
220
|
-
return {
|
|
221
|
-
source: 4,
|
|
222
|
-
sub,
|
|
223
|
-
};
|
|
224
|
-
}
|
|
225
|
-
function nodeContainsErrors(node) {
|
|
226
|
-
return (node.flags & 2) === 2;
|
|
227
|
-
}
|
|
228
|
-
//# sourceMappingURL=checker.js.map
|
package/lib/cjs/core.d.ts
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare function createMapFromTemplate<T>(template: Record<string, T>): Map<string, T>;
|
package/lib/cjs/core.js
DELETED
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.createMapFromTemplate = createMapFromTemplate;
|
|
4
|
-
function createMapFromTemplate(template) {
|
|
5
|
-
const map = new Map();
|
|
6
|
-
for (const key in template) {
|
|
7
|
-
if (key in template) {
|
|
8
|
-
map.set(key, template[key]);
|
|
9
|
-
}
|
|
10
|
-
}
|
|
11
|
-
return map;
|
|
12
|
-
}
|
|
13
|
-
//# sourceMappingURL=core.js.map
|
package/lib/cjs/error.d.ts
DELETED
package/lib/cjs/error.js
DELETED
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.diagnosicSource = void 0;
|
|
4
|
-
exports.formatError = formatError;
|
|
5
|
-
exports.diagnosicSource = "DOT";
|
|
6
|
-
const errorCodeLength = 4;
|
|
7
|
-
const subErrorCodeLength = errorCodeLength - 1;
|
|
8
|
-
function formatError(error) {
|
|
9
|
-
const subCode = (error.sub | 0).toString().padStart(subErrorCodeLength, "0");
|
|
10
|
-
return exports.diagnosicSource + error.source + subCode;
|
|
11
|
-
}
|
|
12
|
-
//# sourceMappingURL=error.js.map
|
package/lib/cjs/index.d.ts
DELETED
package/lib/cjs/index.js
DELETED
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
-
if (k2 === undefined) k2 = k;
|
|
4
|
-
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
-
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
-
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
-
}
|
|
8
|
-
Object.defineProperty(o, k2, desc);
|
|
9
|
-
}) : (function(o, m, k, k2) {
|
|
10
|
-
if (k2 === undefined) k2 = k;
|
|
11
|
-
o[k2] = m[k];
|
|
12
|
-
}));
|
|
13
|
-
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
-
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
-
};
|
|
16
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
-
__exportStar(require("./parser.js"), exports);
|
|
18
|
-
__exportStar(require("./scanner.js"), exports);
|
|
19
|
-
__exportStar(require("./service/service.js"), exports);
|
|
20
|
-
__exportStar(require("./types.js"), exports);
|
|
21
|
-
__exportStar(require("./visitor.js"), exports);
|
|
22
|
-
//# sourceMappingURL=index.js.map
|
package/lib/cjs/parser.d.ts
DELETED
|
@@ -1,27 +0,0 @@
|
|
|
1
|
-
import { type Scanner } from "./scanner.js";
|
|
2
|
-
import { type DiagnosticMessage, type Identifier, type SourceFile, SyntaxKind, type SyntaxNode } from "./types";
|
|
3
|
-
export declare enum ParsingContext {
|
|
4
|
-
None = 0,
|
|
5
|
-
StatementList = 1,
|
|
6
|
-
AttributeContainerList = 2,
|
|
7
|
-
AssignmentList = 3,
|
|
8
|
-
EdgeRhsList = 4,
|
|
9
|
-
QuotedTextIdentifierConcatenation = 5,
|
|
10
|
-
Count = 6
|
|
11
|
-
}
|
|
12
|
-
export declare class Parser {
|
|
13
|
-
#private;
|
|
14
|
-
currentToken: SyntaxKind;
|
|
15
|
-
nodeCount: number;
|
|
16
|
-
identifiers: Set<string>;
|
|
17
|
-
identifierCount: number;
|
|
18
|
-
sourceText: string;
|
|
19
|
-
scanner: Scanner;
|
|
20
|
-
currentNodeHasError: boolean;
|
|
21
|
-
currentContext: ParsingContext;
|
|
22
|
-
diagnostics: DiagnosticMessage[];
|
|
23
|
-
constructor();
|
|
24
|
-
parse(sourceText: string): SourceFile;
|
|
25
|
-
}
|
|
26
|
-
export declare function isIdentifier(kind: SyntaxKind): kind is SyntaxKind.HtmlIdentifier | SyntaxKind.TextIdentifier | SyntaxKind.QuotedTextIdentifier | SyntaxKind.NumericIdentifier;
|
|
27
|
-
export declare function isIdentifierNode(node: SyntaxNode): node is Identifier;
|