occam-verify-cli 1.0.935 → 1.0.937
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/action/verify.js +2 -2
- package/lib/element/assertion/contained.js +5 -5
- package/lib/element/assertion/defined.js +5 -5
- package/lib/element/assertion/property.js +5 -5
- package/lib/element/assertion/signature.js +5 -5
- package/lib/element/assertion/subproof.js +5 -5
- package/lib/element/assertion/type.js +12 -7
- package/lib/element/assertion.js +8 -3
- package/lib/element/assumption/metaLevel.js +12 -7
- package/lib/element/assumption.js +11 -6
- package/lib/element/combinator.js +12 -7
- package/lib/element/conclusion.js +12 -7
- package/lib/element/constructor.js +12 -7
- package/lib/element/declaration/combinator.js +3 -3
- package/lib/element/declaration/complexType.js +3 -3
- package/lib/element/declaration/constructor.js +3 -3
- package/lib/element/declaration/metavariable.js +3 -3
- package/lib/element/declaration/property.js +3 -3
- package/lib/element/declaration/simpleType.js +3 -3
- package/lib/element/declaration/typePrefix.js +3 -3
- package/lib/element/declaration/variable.js +3 -3
- package/lib/element/deduction.js +12 -7
- package/lib/element/derivation.js +3 -3
- package/lib/element/equality.js +12 -7
- package/lib/element/equivalence.js +3 -3
- package/lib/element/frame.js +12 -7
- package/lib/element/hypothesis.js +12 -7
- package/lib/element/judgement.js +12 -7
- package/lib/element/label.js +12 -7
- package/lib/element/metaType.js +11 -6
- package/lib/element/metavariable.js +11 -6
- package/lib/element/parameter.js +12 -7
- package/lib/element/procedureCall.js +12 -7
- package/lib/element/procedureReference.js +12 -7
- package/lib/element/proof.js +3 -3
- package/lib/element/proofAssertion/premise.js +12 -7
- package/lib/element/proofAssertion/step.js +3 -3
- package/lib/element/proofAssertion/supposition.js +12 -7
- package/lib/element/proofAssertion.js +3 -3
- package/lib/element/property.js +12 -7
- package/lib/element/propertyRelation.js +12 -7
- package/lib/element/reference.js +12 -7
- package/lib/element/rule.js +11 -6
- package/lib/element/section.js +3 -3
- package/lib/element/signature.js +12 -7
- package/lib/element/statement.js +10 -5
- package/lib/element/subDerivation.js +3 -3
- package/lib/element/subproof.js +3 -3
- package/lib/element/substitution/frame.js +5 -5
- package/lib/element/substitution/reference.js +5 -5
- package/lib/element/substitution/statement.js +5 -5
- package/lib/element/substitution/term.js +5 -5
- package/lib/element/substitution.js +15 -10
- package/lib/element/term.js +12 -7
- package/lib/element/topLevelAssertion.js +11 -6
- package/lib/element/topLevelMetaAssertion.js +11 -6
- package/lib/element/type.js +9 -9
- package/lib/element/typePrefix.js +12 -7
- package/lib/element/variable.js +12 -7
- package/lib/utilities/element.js +109 -109
- package/package.json +4 -4
- package/src/action/verify.js +1 -1
- package/src/element/assertion/contained.js +4 -4
- package/src/element/assertion/defined.js +4 -4
- package/src/element/assertion/property.js +4 -4
- package/src/element/assertion/signature.js +4 -4
- package/src/element/assertion/subproof.js +4 -4
- package/src/element/assertion/type.js +16 -8
- package/src/element/assertion.js +15 -7
- package/src/element/assumption/metaLevel.js +19 -11
- package/src/element/assumption.js +18 -10
- package/src/element/combinator.js +19 -11
- package/src/element/conclusion.js +19 -11
- package/src/element/constructor.js +16 -8
- package/src/element/declaration/combinator.js +2 -2
- package/src/element/declaration/complexType.js +2 -2
- package/src/element/declaration/constructor.js +2 -2
- package/src/element/declaration/metavariable.js +2 -2
- package/src/element/declaration/property.js +2 -2
- package/src/element/declaration/simpleType.js +2 -2
- package/src/element/declaration/typePrefix.js +2 -2
- package/src/element/declaration/variable.js +2 -2
- package/src/element/deduction.js +19 -11
- package/src/element/derivation.js +2 -2
- package/src/element/equality.js +18 -10
- package/src/element/equivalence.js +2 -2
- package/src/element/frame.js +18 -10
- package/src/element/hypothesis.js +19 -11
- package/src/element/judgement.js +18 -10
- package/src/element/label.js +19 -11
- package/src/element/metaType.js +18 -10
- package/src/element/metavariable.js +19 -11
- package/src/element/parameter.js +18 -10
- package/src/element/procedureCall.js +18 -10
- package/src/element/procedureReference.js +18 -10
- package/src/element/proof.js +2 -2
- package/src/element/proofAssertion/premise.js +19 -11
- package/src/element/proofAssertion/step.js +2 -2
- package/src/element/proofAssertion/supposition.js +19 -11
- package/src/element/proofAssertion.js +2 -2
- package/src/element/property.js +16 -8
- package/src/element/propertyRelation.js +18 -10
- package/src/element/reference.js +19 -11
- package/src/element/rule.js +16 -8
- package/src/element/section.js +2 -2
- package/src/element/signature.js +19 -11
- package/src/element/statement.js +16 -8
- package/src/element/subDerivation.js +2 -2
- package/src/element/subproof.js +2 -2
- package/src/element/substitution/frame.js +4 -4
- package/src/element/substitution/reference.js +4 -4
- package/src/element/substitution/statement.js +4 -4
- package/src/element/substitution/term.js +4 -4
- package/src/element/substitution.js +23 -15
- package/src/element/term.js +16 -8
- package/src/element/topLevelAssertion.js +16 -8
- package/src/element/topLevelMetaAssertion.js +16 -8
- package/src/element/type.js +8 -8
- package/src/element/typePrefix.js +18 -10
- package/src/element/variable.js +16 -8
- package/src/utilities/element.js +122 -122
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "occam-verify-cli",
|
|
3
3
|
"author": "James Smith",
|
|
4
|
-
"version": "1.0.
|
|
4
|
+
"version": "1.0.937",
|
|
5
5
|
"license": "MIT, Anti-996",
|
|
6
6
|
"homepage": "https://github.com/djalbat/occam-verify-cli",
|
|
7
7
|
"description": "Occam's Verifier",
|
|
@@ -12,12 +12,12 @@
|
|
|
12
12
|
"dependencies": {
|
|
13
13
|
"argumentative": "^2.0.47",
|
|
14
14
|
"necessary": "^17.1.7",
|
|
15
|
-
"occam-furtle": "^3.0.
|
|
15
|
+
"occam-furtle": "^3.0.203",
|
|
16
16
|
"occam-grammars": "^1.3.524",
|
|
17
|
-
"occam-languages": "^0.0.
|
|
17
|
+
"occam-languages": "^0.0.206",
|
|
18
18
|
"occam-lexers": "^23.1.44",
|
|
19
19
|
"occam-model": "^1.0.506",
|
|
20
|
-
"occam-nominal": "^1.0.
|
|
20
|
+
"occam-nominal": "^1.0.107",
|
|
21
21
|
"occam-parsers": "^23.1.50",
|
|
22
22
|
"occam-server": "^7.0.7"
|
|
23
23
|
},
|
package/src/action/verify.js
CHANGED
|
@@ -13,7 +13,7 @@ const { last } = arrayUtilities,
|
|
|
13
13
|
{ createReleaseContexts, verifyReleaseContexts, initialiseReleaseContexts } = verificationUtilities;
|
|
14
14
|
|
|
15
15
|
export default async function verifyAction(name, log) {
|
|
16
|
-
const callback = async (context,
|
|
16
|
+
const callback = async (context, breakPoint) => {
|
|
17
17
|
///
|
|
18
18
|
},
|
|
19
19
|
releaseContexts = [],
|
|
@@ -13,8 +13,8 @@ import { termFromContainedAssertionNode,
|
|
|
13
13
|
containedAssertionFromStatementNode } from "../../utilities/element";
|
|
14
14
|
|
|
15
15
|
export default define(class ContainedAssertion extends Assertion {
|
|
16
|
-
constructor(context, string, node,
|
|
17
|
-
super(context, string, node,
|
|
16
|
+
constructor(context, string, node, breakPoint, term, frame, negated, statement) {
|
|
17
|
+
super(context, string, node, breakPoint);
|
|
18
18
|
|
|
19
19
|
this.term = term;
|
|
20
20
|
this.frame = frame;
|
|
@@ -253,7 +253,7 @@ export default define(class ContainedAssertion extends Assertion {
|
|
|
253
253
|
|
|
254
254
|
if (this.name === name) {
|
|
255
255
|
instantiate((context) => {
|
|
256
|
-
const { string,
|
|
256
|
+
const { string, breakPoint } = json,
|
|
257
257
|
containedAssertionNode = instantiateContainedAssertion(string, context),
|
|
258
258
|
node = containedAssertionNode, ///
|
|
259
259
|
term = termFromContainedAssertionNode(containedAssertionNode, context),
|
|
@@ -263,7 +263,7 @@ export default define(class ContainedAssertion extends Assertion {
|
|
|
263
263
|
|
|
264
264
|
context = null;
|
|
265
265
|
|
|
266
|
-
containedAssertion = new ContainedAssertion(context, string, node,
|
|
266
|
+
containedAssertion = new ContainedAssertion(context, string, node, breakPoint, term, frame, negated, statement);
|
|
267
267
|
}, context);
|
|
268
268
|
}
|
|
269
269
|
|
|
@@ -10,8 +10,8 @@ import { termFromTermAndSubstitutions, frameFromFrameAndSubstitutions } from "..
|
|
|
10
10
|
import { termFromJDefinedAssertionNode, frameFromJDefinedAssertionNode, negatedFromJDefinedAssertionNode, definedAssertionFromStatementNode } from "../../utilities/element";
|
|
11
11
|
|
|
12
12
|
export default define(class DefinedAssertion extends Assertion {
|
|
13
|
-
constructor(context, string, node,
|
|
14
|
-
super(context, string, node,
|
|
13
|
+
constructor(context, string, node, breakPoint, term, frame, negated) {
|
|
14
|
+
super(context, string, node, breakPoint);
|
|
15
15
|
|
|
16
16
|
this.term = term;
|
|
17
17
|
this.frame= frame;
|
|
@@ -221,7 +221,7 @@ export default define(class DefinedAssertion extends Assertion {
|
|
|
221
221
|
|
|
222
222
|
if (this.name === name) {
|
|
223
223
|
instantiate((context) => {
|
|
224
|
-
const { string,
|
|
224
|
+
const { string, breakPoint } = json,
|
|
225
225
|
definedAssertionNode = instantiateDefinedAssertion(string, context),
|
|
226
226
|
node = definedAssertionNode, ///
|
|
227
227
|
term = termFromJDefinedAssertionNode(definedAssertionNode, context),
|
|
@@ -230,7 +230,7 @@ export default define(class DefinedAssertion extends Assertion {
|
|
|
230
230
|
|
|
231
231
|
context = null;
|
|
232
232
|
|
|
233
|
-
definedAssertion = new DefinedAssertion(context, string, node,
|
|
233
|
+
definedAssertion = new DefinedAssertion(context, string, node, breakPoint, term, frame, negated);
|
|
234
234
|
}, context);
|
|
235
235
|
}
|
|
236
236
|
|
|
@@ -9,8 +9,8 @@ import { variableAssignmentFromPrepertyAssertion } from "../../process/assign";
|
|
|
9
9
|
import { termFromPropertyAssertionNode, propertyAssertionFromStatementNode, propertyRelationFromPropertyAssertionNode } from "../../utilities/element";
|
|
10
10
|
|
|
11
11
|
export default define(class PropertyAssertion extends Assertion {
|
|
12
|
-
constructor(context, string, node,
|
|
13
|
-
super(context, string, node,
|
|
12
|
+
constructor(context, string, node, breakPoint, term, propertyRelation) {
|
|
13
|
+
super(context, string, node, breakPoint);
|
|
14
14
|
|
|
15
15
|
this.term = term;
|
|
16
16
|
this.propertyRelation = propertyRelation;
|
|
@@ -226,7 +226,7 @@ export default define(class PropertyAssertion extends Assertion {
|
|
|
226
226
|
|
|
227
227
|
if (this.name === name) {
|
|
228
228
|
instantiate((context) => {
|
|
229
|
-
const { string,
|
|
229
|
+
const { string, breakPoint } = json,
|
|
230
230
|
propertyAssertionNode = instantiatePropertyAssertion(string, context),
|
|
231
231
|
node = propertyAssertionNode, ///
|
|
232
232
|
term = termFromPropertyAssertionNode(propertyAssertionNode, context),
|
|
@@ -234,7 +234,7 @@ export default define(class PropertyAssertion extends Assertion {
|
|
|
234
234
|
|
|
235
235
|
context = null;
|
|
236
236
|
|
|
237
|
-
propertyAssertion = new PropertyAssertion(context, string, node,
|
|
237
|
+
propertyAssertion = new PropertyAssertion(context, string, node, breakPoint, term, propertyRelation);
|
|
238
238
|
}, context);
|
|
239
239
|
}
|
|
240
240
|
|
|
@@ -8,8 +8,8 @@ import { instantiateSignatureAssertion } from "../../process/instantiate";
|
|
|
8
8
|
import { signatureFromSignatureAssertionNode, referenceFromSignatureAssertionNode, signatureAssertionFromStatementNode } from "../../utilities/element";
|
|
9
9
|
|
|
10
10
|
export default define(class SignatureAssertion extends Assertion {
|
|
11
|
-
constructor(context, string, node,
|
|
12
|
-
super(context, string, node,
|
|
11
|
+
constructor(context, string, node, breakPoint, signature, reference) {
|
|
12
|
+
super(context, string, node, breakPoint);
|
|
13
13
|
|
|
14
14
|
this.signature = signature;
|
|
15
15
|
this.reference = reference;
|
|
@@ -211,7 +211,7 @@ export default define(class SignatureAssertion extends Assertion {
|
|
|
211
211
|
|
|
212
212
|
if (this.name === name) {
|
|
213
213
|
instantiate((context) => {
|
|
214
|
-
const { string,
|
|
214
|
+
const { string, breakPoint } = json,
|
|
215
215
|
definedAssertionNode = instantiateSignatureAssertion(string, context),
|
|
216
216
|
node = definedAssertionNode, ///
|
|
217
217
|
signature = signatureFromSignatureAssertionNode(definedAssertionNode, context),
|
|
@@ -219,7 +219,7 @@ export default define(class SignatureAssertion extends Assertion {
|
|
|
219
219
|
|
|
220
220
|
context = null;
|
|
221
221
|
|
|
222
|
-
signatureAssertion = new SignatureAssertion(context, string, node,
|
|
222
|
+
signatureAssertion = new SignatureAssertion(context, string, node, breakPoint, signature, reference);
|
|
223
223
|
}, context);
|
|
224
224
|
}
|
|
225
225
|
|
|
@@ -13,8 +13,8 @@ import { subproofAssertionFromStatementNode } from "../../utilities/element";
|
|
|
13
13
|
const { last, front, backwardsEvery } = arrayUtilities;
|
|
14
14
|
|
|
15
15
|
export default define(class SubproofAssertion extends Assertion {
|
|
16
|
-
constructor(context, string, node,
|
|
17
|
-
super(context, string, node,
|
|
16
|
+
constructor(context, string, node, breakPoint, statements) {
|
|
17
|
+
super(context, string, node, breakPoint);
|
|
18
18
|
|
|
19
19
|
this.statements = statements;
|
|
20
20
|
}
|
|
@@ -300,14 +300,14 @@ export default define(class SubproofAssertion extends Assertion {
|
|
|
300
300
|
|
|
301
301
|
if (this.name === name) {
|
|
302
302
|
instantiate((context) => {
|
|
303
|
-
const { string,
|
|
303
|
+
const { string, breakPoint } = json,
|
|
304
304
|
subproofAssertionNode = instantiateSubproofAssertion(string, context),
|
|
305
305
|
statements = statementsFromSubproofAssertionNode(subproofAssertionNode, context),
|
|
306
306
|
node = subproofAssertionNode; ///
|
|
307
307
|
|
|
308
308
|
context = null;
|
|
309
309
|
|
|
310
|
-
subproorAssertion = new SubproofAssertion(context, string, node,
|
|
310
|
+
subproorAssertion = new SubproofAssertion(context, string, node, breakPoint, statements);
|
|
311
311
|
}, context);
|
|
312
312
|
}
|
|
313
313
|
|
|
@@ -11,8 +11,8 @@ import { variableAssignmentFromTypeAssertion } from "../../process/assign";
|
|
|
11
11
|
import { termFromTypeAssertionNode, typeAssertionFromStatementNode } from "../../utilities/element";
|
|
12
12
|
|
|
13
13
|
export default define(class TypeAssertion extends Assertion {
|
|
14
|
-
constructor(context, string, node,
|
|
15
|
-
super(context, string, node,
|
|
14
|
+
constructor(context, string, node, breakPoint, term, type) {
|
|
15
|
+
super(context, string, node, breakPoint);
|
|
16
16
|
|
|
17
17
|
this.term = term;
|
|
18
18
|
this.type = type;
|
|
@@ -220,13 +220,21 @@ export default define(class TypeAssertion extends Assertion {
|
|
|
220
220
|
toJSON() {
|
|
221
221
|
const typeJSON = typeToTypeJSON(this.type),
|
|
222
222
|
name = this.getName(),
|
|
223
|
-
string = this.getString()
|
|
224
|
-
|
|
225
|
-
|
|
223
|
+
string = this.getString();
|
|
224
|
+
|
|
225
|
+
let breakPoint;
|
|
226
|
+
|
|
227
|
+
breakPoint = this.getBreakPoint();
|
|
228
|
+
|
|
229
|
+
const breakPointJSON = breakPoint.toJSON();
|
|
230
|
+
|
|
231
|
+
breakPoint = breakPointJSON; ///
|
|
232
|
+
|
|
233
|
+
const type = typeJSON,
|
|
226
234
|
json = {
|
|
227
235
|
name,
|
|
228
236
|
string,
|
|
229
|
-
|
|
237
|
+
breakPoint,
|
|
230
238
|
type
|
|
231
239
|
};
|
|
232
240
|
|
|
@@ -242,7 +250,7 @@ export default define(class TypeAssertion extends Assertion {
|
|
|
242
250
|
|
|
243
251
|
if (this.name === name) {
|
|
244
252
|
instantiate((context) => {
|
|
245
|
-
const { string,
|
|
253
|
+
const { string, breakPoint } = json,
|
|
246
254
|
typeAssertionNode = instantiateTypeAssertion(string, context),
|
|
247
255
|
term = termFromTypeAssertionNode(typeAssertionNode, context),
|
|
248
256
|
type = typeFromJSON(json, context),
|
|
@@ -250,7 +258,7 @@ export default define(class TypeAssertion extends Assertion {
|
|
|
250
258
|
|
|
251
259
|
context = null;
|
|
252
260
|
|
|
253
|
-
typeAssertion = new TypeAssertion(context, string, node,
|
|
261
|
+
typeAssertion = new TypeAssertion(context, string, node, breakPoint, term, type);
|
|
254
262
|
}, context);
|
|
255
263
|
}
|
|
256
264
|
|
package/src/element/assertion.js
CHANGED
|
@@ -42,13 +42,21 @@ export default class Assertion extends Element {
|
|
|
42
42
|
|
|
43
43
|
toJSON() {
|
|
44
44
|
const name = this.getName(),
|
|
45
|
-
string = this.getString()
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
45
|
+
string = this.getString();
|
|
46
|
+
|
|
47
|
+
let breakPoint;
|
|
48
|
+
|
|
49
|
+
breakPoint = this.getBreakPoint();
|
|
50
|
+
|
|
51
|
+
const breakPointJSON = breakPoint.toJSON();
|
|
52
|
+
|
|
53
|
+
breakPoint = breakPointJSON; ///
|
|
54
|
+
|
|
55
|
+
const json = {
|
|
56
|
+
name,
|
|
57
|
+
string,
|
|
58
|
+
breakPoint
|
|
59
|
+
};
|
|
52
60
|
|
|
53
61
|
return json;
|
|
54
62
|
}
|
|
@@ -11,8 +11,8 @@ import { metaLevelAssumptionStringFromReferenceAndStatement } from "../../utilit
|
|
|
11
11
|
import { join, ablate, attempt, descend, reconcile, serialise, unserialise, instantiate } from "../../utilities/context";
|
|
12
12
|
|
|
13
13
|
export default define(class MetaLevelAssumption extends Element {
|
|
14
|
-
constructor(context, string, node,
|
|
15
|
-
super(context, string, node,
|
|
14
|
+
constructor(context, string, node, breakPoint, reference, statement) {
|
|
15
|
+
super(context, string, node, breakPoint);
|
|
16
16
|
|
|
17
17
|
this.reference = reference;
|
|
18
18
|
this.statement = statement;
|
|
@@ -285,13 +285,21 @@ export default define(class MetaLevelAssumption extends Element {
|
|
|
285
285
|
const context = this.getContext();
|
|
286
286
|
|
|
287
287
|
return serialise((context) => {
|
|
288
|
-
const string = this.getString()
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
288
|
+
const string = this.getString();
|
|
289
|
+
|
|
290
|
+
let breakPoint;
|
|
291
|
+
|
|
292
|
+
breakPoint = this.getBreakPoint();
|
|
293
|
+
|
|
294
|
+
const breakPointJSON = breakPoint.toJSON();
|
|
295
|
+
|
|
296
|
+
breakPoint = breakPointJSON; ///
|
|
297
|
+
|
|
298
|
+
const json = {
|
|
299
|
+
context,
|
|
300
|
+
string,
|
|
301
|
+
breakPoint
|
|
302
|
+
};
|
|
295
303
|
|
|
296
304
|
return json;
|
|
297
305
|
}, context);
|
|
@@ -304,13 +312,13 @@ export default define(class MetaLevelAssumption extends Element {
|
|
|
304
312
|
|
|
305
313
|
unserialise((json, context) => {
|
|
306
314
|
instantiate((context) => {
|
|
307
|
-
const { string,
|
|
315
|
+
const { string, breakPoint } = json,
|
|
308
316
|
metaLevelAssumptionNode = instantiateMetaLevelAssumption(string, context),
|
|
309
317
|
node = metaLevelAssumptionNode, ///
|
|
310
318
|
reference = referenceFromMetaLevelAssumptionNode(metaLevelAssumptionNode, context),
|
|
311
319
|
statement = statementFromMetaLevelAssumptionNode(metaLevelAssumptionNode, context);
|
|
312
320
|
|
|
313
|
-
metaLevelAssumption = new MetaLevelAssumption(context, string, node,
|
|
321
|
+
metaLevelAssumption = new MetaLevelAssumption(context, string, node, breakPoint, reference, statement);
|
|
314
322
|
}, context);
|
|
315
323
|
}, json, context);
|
|
316
324
|
|
|
@@ -7,8 +7,8 @@ import {instantiate, reconcile} from "../utilities/context";
|
|
|
7
7
|
import { instantiateAssumption } from "../process/instantiate";
|
|
8
8
|
|
|
9
9
|
export default define(class Assumption extends Element {
|
|
10
|
-
constructor(context, string, node,
|
|
11
|
-
super(context, string, node,
|
|
10
|
+
constructor(context, string, node, breakPoint, reference, statement) {
|
|
11
|
+
super(context, string, node, breakPoint);
|
|
12
12
|
|
|
13
13
|
this.reference = reference;
|
|
14
14
|
this.statement = statement;
|
|
@@ -247,24 +247,32 @@ export default define(class Assumption extends Element {
|
|
|
247
247
|
static name = "Assumption";
|
|
248
248
|
|
|
249
249
|
toJSON() {
|
|
250
|
-
const string = this.getString()
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
250
|
+
const string = this.getString();
|
|
251
|
+
|
|
252
|
+
let breakPoint;
|
|
253
|
+
|
|
254
|
+
breakPoint = this.getBreakPoint();
|
|
255
|
+
|
|
256
|
+
const breakPointJSON = breakPoint.toJSON();
|
|
257
|
+
|
|
258
|
+
breakPoint = breakPointJSON; ///
|
|
259
|
+
|
|
260
|
+
const json = {
|
|
261
|
+
string,
|
|
262
|
+
breakPoint
|
|
263
|
+
};
|
|
256
264
|
|
|
257
265
|
return json;
|
|
258
266
|
}
|
|
259
267
|
|
|
260
268
|
static fromJSON(json, context) {
|
|
261
269
|
return instantiate((context) => {
|
|
262
|
-
const { string,
|
|
270
|
+
const { string, breakPoint } = json,
|
|
263
271
|
assumptionNode = instantiateAssumption(string, context),
|
|
264
272
|
node = assumptionNode, ///
|
|
265
273
|
reference = referenceFromAssumptionNode(assumptionNode, context),
|
|
266
274
|
statement = statementFromAssumptionNode(assumptionNode, context),
|
|
267
|
-
assumption = new Assumption(context, string, node,
|
|
275
|
+
assumption = new Assumption(context, string, node, breakPoint, reference, statement);
|
|
268
276
|
|
|
269
277
|
return assumption;
|
|
270
278
|
}, context);
|
|
@@ -10,8 +10,8 @@ import { validateStatementAsCombinator } from "../process/validate";
|
|
|
10
10
|
import { attempt, serialise, unserialise, instantiate } from "../utilities/context";
|
|
11
11
|
|
|
12
12
|
export default define(class Combinator extends Element {
|
|
13
|
-
constructor(context, string, node,
|
|
14
|
-
super(context, string, node,
|
|
13
|
+
constructor(context, string, node, breakPoint, statement) {
|
|
14
|
+
super(context, string, node, breakPoint);
|
|
15
15
|
|
|
16
16
|
this.statement = statement;
|
|
17
17
|
}
|
|
@@ -105,13 +105,21 @@ export default define(class Combinator extends Element {
|
|
|
105
105
|
const context = this.getContext();
|
|
106
106
|
|
|
107
107
|
return serialise((context) => {
|
|
108
|
-
const string = this.getString()
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
108
|
+
const string = this.getString();
|
|
109
|
+
|
|
110
|
+
let breakPoint;
|
|
111
|
+
|
|
112
|
+
breakPoint = this.getBreakPoint();
|
|
113
|
+
|
|
114
|
+
const breakPointJSON = breakPoint.toJSON();
|
|
115
|
+
|
|
116
|
+
breakPoint = breakPointJSON; ///
|
|
117
|
+
|
|
118
|
+
const json = {
|
|
119
|
+
context,
|
|
120
|
+
string,
|
|
121
|
+
breakPoint
|
|
122
|
+
};
|
|
115
123
|
|
|
116
124
|
return json;
|
|
117
125
|
}, context);
|
|
@@ -124,12 +132,12 @@ export default define(class Combinator extends Element {
|
|
|
124
132
|
|
|
125
133
|
unserialise((json, context) => {
|
|
126
134
|
instantiate((context) => {
|
|
127
|
-
const { string,
|
|
135
|
+
const { string, breakPoint } = json,
|
|
128
136
|
combinatorNode = instantiateCombinator(string, context),
|
|
129
137
|
node = combinatorNode, ///
|
|
130
138
|
statement = statementFromCombinatorNode(combinatorNode, context);
|
|
131
139
|
|
|
132
|
-
combinator = new Combinator(context, string, node,
|
|
140
|
+
combinator = new Combinator(context, string, node, breakPoint, statement);
|
|
133
141
|
}, context);
|
|
134
142
|
}, json, context);
|
|
135
143
|
|
|
@@ -7,8 +7,8 @@ import { instantiateConclusion } from "../process/instantiate";
|
|
|
7
7
|
import { declare, attempt, descend, serialise, unserialise, instantiate } from "../utilities/context";
|
|
8
8
|
|
|
9
9
|
export default define(class Conclusion extends Element {
|
|
10
|
-
constructor(context, string, node,
|
|
11
|
-
super(context, string, node,
|
|
10
|
+
constructor(context, string, node, breakPoint, statement) {
|
|
11
|
+
super(context, string, node, breakPoint);
|
|
12
12
|
|
|
13
13
|
this.statement = statement;
|
|
14
14
|
}
|
|
@@ -134,13 +134,21 @@ export default define(class Conclusion extends Element {
|
|
|
134
134
|
const context = this.getContext();
|
|
135
135
|
|
|
136
136
|
return serialise((context) => {
|
|
137
|
-
const string = this.getString()
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
137
|
+
const string = this.getString();
|
|
138
|
+
|
|
139
|
+
let breakPoint;
|
|
140
|
+
|
|
141
|
+
breakPoint = this.getBreakPoint();
|
|
142
|
+
|
|
143
|
+
const breakPointJSON = breakPoint.toJSON();
|
|
144
|
+
|
|
145
|
+
breakPoint = breakPointJSON; ///
|
|
146
|
+
|
|
147
|
+
const json = {
|
|
148
|
+
context,
|
|
149
|
+
string,
|
|
150
|
+
breakPoint
|
|
151
|
+
};
|
|
144
152
|
|
|
145
153
|
return json;
|
|
146
154
|
}, context);
|
|
@@ -153,12 +161,12 @@ export default define(class Conclusion extends Element {
|
|
|
153
161
|
|
|
154
162
|
unserialise((json, context) => {
|
|
155
163
|
instantiate((context) => {
|
|
156
|
-
const { string,
|
|
164
|
+
const { string, breakPoint } = json,
|
|
157
165
|
conclusionNode = instantiateConclusion(string, context),
|
|
158
166
|
node = conclusionNode, ///
|
|
159
167
|
statement = statementFromConclusionNode(conclusionNode, context);
|
|
160
168
|
|
|
161
|
-
conclusion = new Conclusion(context, string, node,
|
|
169
|
+
conclusion = new Conclusion(context, string, node, breakPoint, statement);
|
|
162
170
|
}, context);
|
|
163
171
|
}, json, context);
|
|
164
172
|
|
|
@@ -12,8 +12,8 @@ import { provisionallyStringFromProvisional } from "../utilities/string";
|
|
|
12
12
|
import { attempt, serialise, unserialise, instantiate } from "../utilities/context";
|
|
13
13
|
|
|
14
14
|
export default define(class Constructor extends Element {
|
|
15
|
-
constructor(context, string, node,
|
|
16
|
-
super(context, string, node,
|
|
15
|
+
constructor(context, string, node, breakPoint, term, type) {
|
|
16
|
+
super(context, string, node, breakPoint);
|
|
17
17
|
|
|
18
18
|
this.term = term;
|
|
19
19
|
this.type = type;
|
|
@@ -154,13 +154,21 @@ export default define(class Constructor extends Element {
|
|
|
154
154
|
return serialise((context) => {
|
|
155
155
|
const includeType = false,
|
|
156
156
|
typeJSON = typeToTypeJSON(this.type),
|
|
157
|
-
string = this.getString(includeType)
|
|
158
|
-
|
|
159
|
-
|
|
157
|
+
string = this.getString(includeType);
|
|
158
|
+
|
|
159
|
+
let breakPoint;
|
|
160
|
+
|
|
161
|
+
breakPoint = this.getBreakPoint();
|
|
162
|
+
|
|
163
|
+
const breakPointJSON = breakPoint.toJSON();
|
|
164
|
+
|
|
165
|
+
breakPoint = breakPointJSON; ///
|
|
166
|
+
|
|
167
|
+
const type = typeJSON, ///
|
|
160
168
|
json = {
|
|
161
169
|
context,
|
|
162
170
|
string,
|
|
163
|
-
|
|
171
|
+
breakPoint,
|
|
164
172
|
type
|
|
165
173
|
};
|
|
166
174
|
|
|
@@ -175,13 +183,13 @@ export default define(class Constructor extends Element {
|
|
|
175
183
|
|
|
176
184
|
unserialise((json, context) => {
|
|
177
185
|
instantiate((context) => {
|
|
178
|
-
const { string,
|
|
186
|
+
const { string, breakPoint } = json,
|
|
179
187
|
constructorNode = instantiateConstructor(string, context),
|
|
180
188
|
node = constructorNode, ///
|
|
181
189
|
term = termFromConstructorNode(constructorNode, context),
|
|
182
190
|
type = typeFromJSON(json, context);
|
|
183
191
|
|
|
184
|
-
constructor = new Constructor(context, string, node,
|
|
192
|
+
constructor = new Constructor(context, string, node, breakPoint, term, type);
|
|
185
193
|
}, context);
|
|
186
194
|
}, json, context);
|
|
187
195
|
|
|
@@ -5,8 +5,8 @@ import Declaration from "../declaration";
|
|
|
5
5
|
import { define } from "../../elements";
|
|
6
6
|
|
|
7
7
|
export default define(class CombinatorDeclaration extends Declaration {
|
|
8
|
-
constructor(context, string, node,
|
|
9
|
-
super(context, string, node,
|
|
8
|
+
constructor(context, string, node, breakPoint, combinator) {
|
|
9
|
+
super(context, string, node, breakPoint);
|
|
10
10
|
|
|
11
11
|
this.combinator = combinator;
|
|
12
12
|
}
|
|
@@ -10,8 +10,8 @@ import { baseTypeFromNothing } from "../../utilities/type";
|
|
|
10
10
|
const { asyncEvery } = asynchronousUtilities;
|
|
11
11
|
|
|
12
12
|
export default define(class ComplexTypeDeclaration extends Declaration {
|
|
13
|
-
constructor(context, string, node,
|
|
14
|
-
super(context, string, node,
|
|
13
|
+
constructor(context, string, node, breakPoint, type, superTypes, provisional, propertyDeclarations) {
|
|
14
|
+
super(context, string, node, breakPoint);
|
|
15
15
|
|
|
16
16
|
this.type = type;
|
|
17
17
|
this.superTypes = superTypes;
|
|
@@ -5,8 +5,8 @@ import Declaration from "../declaration";
|
|
|
5
5
|
import { define } from "../../elements";
|
|
6
6
|
|
|
7
7
|
export default define(class ConstructorDeclaration extends Declaration {
|
|
8
|
-
constructor(context, string, node,
|
|
9
|
-
super(context, string, node,
|
|
8
|
+
constructor(context, string, node, breakPoint, type, provisional, constructor) {
|
|
9
|
+
super(context, string, node, breakPoint);
|
|
10
10
|
|
|
11
11
|
this.type = type;
|
|
12
12
|
this.provisional = provisional;
|
|
@@ -5,8 +5,8 @@ import Declaration from "../declaration";
|
|
|
5
5
|
import { define } from "../../elements";
|
|
6
6
|
|
|
7
7
|
export default define(class MetavariableDeclaration extends Declaration {
|
|
8
|
-
constructor(context, string, node,
|
|
9
|
-
super(context, string, node,
|
|
8
|
+
constructor(context, string, node, breakPoint, metaType, metavariable) {
|
|
9
|
+
super(context, string, node, breakPoint);
|
|
10
10
|
|
|
11
11
|
this.metaType = metaType;
|
|
12
12
|
this.metavariable = metavariable;
|
|
@@ -5,8 +5,8 @@ import Declaration from "../declaration";
|
|
|
5
5
|
import { define } from "../../elements";
|
|
6
6
|
|
|
7
7
|
export default define(class PropertyDeclaration extends Declaration {
|
|
8
|
-
constructor(context, string, node,
|
|
9
|
-
super(context, string, node,
|
|
8
|
+
constructor(context, string, node, breakPoint, property, type) {
|
|
9
|
+
super(context, string, node, breakPoint);
|
|
10
10
|
|
|
11
11
|
this.property = property;
|
|
12
12
|
this.type = type;
|
|
@@ -6,8 +6,8 @@ import { define } from "../../elements";
|
|
|
6
6
|
import { baseTypeFromNothing } from "../../utilities/type";
|
|
7
7
|
|
|
8
8
|
export default define(class SimpleTypeDeclaration extends Declaration {
|
|
9
|
-
constructor(context, string, node,
|
|
10
|
-
super(context, string, node,
|
|
9
|
+
constructor(context, string, node, breakPoint, type, superTypes, provisional) {
|
|
10
|
+
super(context, string, node, breakPoint);
|
|
11
11
|
|
|
12
12
|
this.type = type;
|
|
13
13
|
this.superTypes = superTypes;
|
|
@@ -5,8 +5,8 @@ import Declaration from "../declaration";
|
|
|
5
5
|
import { define } from "../../elements";
|
|
6
6
|
|
|
7
7
|
export default define(class TypePrefixDeclaration extends Declaration {
|
|
8
|
-
constructor(context, string, node,
|
|
9
|
-
super(context, string, node,
|
|
8
|
+
constructor(context, string, node, breakPoint, typePrefix) {
|
|
9
|
+
super(context, string, node, breakPoint);
|
|
10
10
|
|
|
11
11
|
this.typePrefix = typePrefix;
|
|
12
12
|
}
|
|
@@ -5,8 +5,8 @@ import Declaration from "../declaration";
|
|
|
5
5
|
import { define } from "../../elements";
|
|
6
6
|
|
|
7
7
|
export default define(class VariableDeclaration extends Declaration {
|
|
8
|
-
constructor(context, string, node,
|
|
9
|
-
super(context, string, node,
|
|
8
|
+
constructor(context, string, node, breakPoint, type, variable, provisional) {
|
|
9
|
+
super(context, string, node, breakPoint);
|
|
10
10
|
|
|
11
11
|
this.type = type;
|
|
12
12
|
this.variable = variable;
|