occam-verify-cli 0.0.1136 → 0.0.1138
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/lib/context/bracketed/combinator.js +4 -3
- package/lib/context/bracketed/constructor.js +4 -3
- package/lib/context/bracketted.js +4 -16
- package/lib/{nodeAndTokens → context/partial}/metavariable.js +18 -18
- package/lib/{nodeAndTokens → context/partial}/statement.js +18 -18
- package/lib/{nodeAndTokens/substitution/statement.js → context/partial/substitution/frame.js} +16 -16
- package/lib/{nodeAndTokens/substitution/term.js → context/partial/substitution/reference.js} +16 -16
- package/lib/{nodeAndTokens/substitution/frame.js → context/partial/substitution/statement.js} +16 -16
- package/lib/{nodeAndTokens/substitution/reference.js → context/partial/substitution/term.js} +16 -16
- package/lib/{nodeAndTokens → context/partial}/term.js +19 -19
- package/lib/{nodeAndTokens → context/partial}/variable.js +19 -19
- package/lib/context/partial.js +93 -0
- package/lib/dom/metavariable.js +10 -10
- package/lib/dom/statement.js +3 -3
- package/lib/dom/term.js +2 -2
- package/lib/dom/variable.js +3 -3
- package/lib/log.js +1 -2
- package/lib/substitution/frame.js +3 -3
- package/lib/substitution/reference.js +3 -3
- package/lib/substitution/statement.js +5 -5
- package/lib/substitution/term.js +3 -3
- package/package.json +1 -1
- package/src/context/bracketed/combinator.js +7 -3
- package/src/context/bracketed/constructor.js +7 -3
- package/src/context/bracketted.js +3 -23
- package/src/context/partial/metavariable.js +39 -0
- package/src/context/partial/statement.js +39 -0
- package/src/context/partial/substitution/frame.js +18 -0
- package/src/context/partial/substitution/reference.js +18 -0
- package/src/context/partial/substitution/statement.js +18 -0
- package/src/context/partial/substitution/term.js +18 -0
- package/src/context/partial/term.js +49 -0
- package/src/context/partial/variable.js +49 -0
- package/src/{nodeAndTokens.js → context/partial.js} +5 -7
- package/src/dom/metavariable.js +14 -13
- package/src/dom/statement.js +6 -5
- package/src/dom/term.js +1 -1
- package/src/dom/variable.js +2 -2
- package/src/log.js +0 -2
- package/src/substitution/frame.js +6 -4
- package/src/substitution/reference.js +6 -4
- package/src/substitution/statement.js +16 -11
- package/src/substitution/term.js +6 -4
- package/lib/nodeAndTokens.js +0 -93
- package/lib/utilities/message.js +0 -52
- package/src/nodeAndTokens/metavariable.js +0 -37
- package/src/nodeAndTokens/statement.js +0 -37
- package/src/nodeAndTokens/substitution/frame.js +0 -18
- package/src/nodeAndTokens/substitution/reference.js +0 -18
- package/src/nodeAndTokens/substitution/statement.js +0 -18
- package/src/nodeAndTokens/substitution/term.js +0 -18
- package/src/nodeAndTokens/term.js +0 -45
- package/src/nodeAndTokens/variable.js +0 -45
- package/src/utilities/message.js +0 -49
package/src/utilities/message.js
DELETED
|
@@ -1,49 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
export function leastLineIndexFromNodeAndTokens(node, tokens) {
|
|
4
|
-
let leastLineIndex = undefined; ///
|
|
5
|
-
|
|
6
|
-
const firstSignificantTokenIndex = node.getFirstSignificantTokenIndex(tokens);
|
|
7
|
-
|
|
8
|
-
let lineIndex = 0;
|
|
9
|
-
|
|
10
|
-
tokens.some((token, tokenIndex) => { ///
|
|
11
|
-
if (tokenIndex === firstSignificantTokenIndex) {
|
|
12
|
-
leastLineIndex = lineIndex; ///
|
|
13
|
-
|
|
14
|
-
return true;
|
|
15
|
-
}
|
|
16
|
-
|
|
17
|
-
const tokenEndOfLineToken = token.isEndOfLineToken();
|
|
18
|
-
|
|
19
|
-
if (tokenEndOfLineToken) {
|
|
20
|
-
lineIndex += 1;
|
|
21
|
-
}
|
|
22
|
-
});
|
|
23
|
-
|
|
24
|
-
return leastLineIndex;
|
|
25
|
-
}
|
|
26
|
-
|
|
27
|
-
export function greatestLineIndexFromNodeAndTokens(node, tokens) {
|
|
28
|
-
let greatestLineIndex = undefined; ///
|
|
29
|
-
|
|
30
|
-
const lastSignificantTokenIndex = node.getLastSignificantTokenIndex(tokens);
|
|
31
|
-
|
|
32
|
-
let lineIndex = 0;
|
|
33
|
-
|
|
34
|
-
tokens.some((token, tokenIndex) => { ///
|
|
35
|
-
if (tokenIndex === lastSignificantTokenIndex) {
|
|
36
|
-
greatestLineIndex = lineIndex; ///
|
|
37
|
-
|
|
38
|
-
return true;
|
|
39
|
-
}
|
|
40
|
-
|
|
41
|
-
const tokenEndOfLineToken = token.isEndOfLineToken();
|
|
42
|
-
|
|
43
|
-
if (tokenEndOfLineToken) {
|
|
44
|
-
lineIndex += 1;
|
|
45
|
-
}
|
|
46
|
-
});
|
|
47
|
-
|
|
48
|
-
return greatestLineIndex;
|
|
49
|
-
}
|