@tuprolog/arg2p 0.16.2 → 0.16.3
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/2p-core.js +3214 -3035
- package/2p-core.js.map +1 -1
- package/2p-dsl-core.js +303 -303
- package/2p-dsl-core.js.map +1 -1
- package/2p-dsl-solve.js +252 -252
- package/2p-dsl-theory.js +160 -160
- package/2p-dsl-unify.js +6 -6
- package/2p-io-lib.js +3496 -0
- package/2p-io-lib.js.map +1 -0
- package/2p-parser-core.js +124 -123
- package/2p-parser-core.js.map +1 -1
- package/2p-parser-impl.js +1480 -1389
- package/2p-parser-impl.js.map +1 -1
- package/2p-parser-theory.js +89 -88
- package/2p-parser-theory.js.map +1 -1
- package/2p-solve-classic.js +1004 -1004
- package/2p-solve.js +3933 -3464
- package/2p-solve.js.map +1 -1
- package/2p-theory.js +1423 -1423
- package/2p-theory.js.map +1 -1
- package/2p-unify.js +349 -349
- package/2p-utils.js +391 -391
- package/README.md +59 -12
- package/arg2p-causality-solver.js +151 -151
- package/arg2p-core.js +1792 -1744
- package/arg2p-core.js.map +1 -1
- package/arg2p.js +95 -95
- package/kotlin-kotlin-stdlib.js +2583 -1714
- package/kotlin-kotlin-stdlib.js.map +1 -1
- package/kt-math.js +1531 -1531
- package/okio-parent-okio-nodefilesystem.js +211 -0
- package/okio-parent-okio-nodefilesystem.js.map +1 -0
- package/okio-parent-okio.js +3873 -0
- package/okio-parent-okio.js.map +1 -0
- package/package.json +5 -2
package/2p-unify.js
CHANGED
|
@@ -19,67 +19,67 @@
|
|
|
19
19
|
'use strict';
|
|
20
20
|
//region block: imports
|
|
21
21
|
var imul = Math.imul;
|
|
22
|
-
var protoOf = kotlin_kotlin.$_$.
|
|
23
|
-
var getBooleanHashCode = kotlin_kotlin.$_$.
|
|
24
|
-
var initMetadataForClass = kotlin_kotlin.$_$.
|
|
25
|
-
var toString = kotlin_kotlin.$_$.
|
|
26
|
-
var hashCode = kotlin_kotlin.$_$.
|
|
27
|
-
var equals = kotlin_kotlin.$_$.
|
|
28
|
-
var KProperty1 = kotlin_kotlin.$_$.
|
|
29
|
-
var getPropertyCallableRef = kotlin_kotlin.$_$.
|
|
30
|
-
var asSequence = kotlin_kotlin.$_$.
|
|
31
|
-
var plus = kotlin_kotlin.$_$.
|
|
32
|
-
var map = kotlin_kotlin.$_$.
|
|
33
|
-
var Unit_instance = kotlin_kotlin.$_$.
|
|
22
|
+
var protoOf = kotlin_kotlin.$_$.o7;
|
|
23
|
+
var getBooleanHashCode = kotlin_kotlin.$_$.x6;
|
|
24
|
+
var initMetadataForClass = kotlin_kotlin.$_$.b7;
|
|
25
|
+
var toString = kotlin_kotlin.$_$.r7;
|
|
26
|
+
var hashCode = kotlin_kotlin.$_$.a7;
|
|
27
|
+
var equals = kotlin_kotlin.$_$.u6;
|
|
28
|
+
var KProperty1 = kotlin_kotlin.$_$.j8;
|
|
29
|
+
var getPropertyCallableRef = kotlin_kotlin.$_$.y6;
|
|
30
|
+
var asSequence = kotlin_kotlin.$_$.k2;
|
|
31
|
+
var plus = kotlin_kotlin.$_$.m9;
|
|
32
|
+
var map = kotlin_kotlin.$_$.i9;
|
|
33
|
+
var Unit_instance = kotlin_kotlin.$_$.p;
|
|
34
34
|
var Companion_getInstance = kotlin_it_unibo_tuprolog_core.$_$.o;
|
|
35
|
-
var ArrayList_init_$Create$ = kotlin_kotlin.$_$.
|
|
36
|
-
var toCollection = kotlin_kotlin.$_$.
|
|
37
|
-
var constructCallableReference = kotlin_kotlin.$_$.
|
|
38
|
-
var Pair = kotlin_kotlin.$_$.
|
|
39
|
-
var lazy = kotlin_kotlin.$_$.
|
|
40
|
-
var asSequence_0 = kotlin_kotlin.$_$.
|
|
41
|
-
var THROW_CCE = kotlin_kotlin.$_$.
|
|
35
|
+
var ArrayList_init_$Create$ = kotlin_kotlin.$_$.s;
|
|
36
|
+
var toCollection = kotlin_kotlin.$_$.v9;
|
|
37
|
+
var constructCallableReference = kotlin_kotlin.$_$.s6;
|
|
38
|
+
var Pair = kotlin_kotlin.$_$.zb;
|
|
39
|
+
var lazy = kotlin_kotlin.$_$.jc;
|
|
40
|
+
var asSequence_0 = kotlin_kotlin.$_$.l2;
|
|
41
|
+
var THROW_CCE = kotlin_kotlin.$_$.bc;
|
|
42
42
|
var VOID = kotlin_kotlin.$_$.b;
|
|
43
43
|
var Companion_instance = kotlin_it_unibo_tuprolog_utils.$_$.a;
|
|
44
|
-
var Triple = kotlin_kotlin.$_$.
|
|
44
|
+
var Triple = kotlin_kotlin.$_$.dc;
|
|
45
45
|
var Some = kotlin_it_unibo_tuprolog_utils.$_$.l;
|
|
46
|
-
var zip = kotlin_kotlin.$_$.
|
|
47
|
-
var flatMap = kotlin_kotlin.$_$.
|
|
48
|
-
var sequenceOf = kotlin_kotlin.$_$.
|
|
49
|
-
var defineProp = kotlin_kotlin.$_$.
|
|
50
|
-
var sequenceOf_0 = kotlin_kotlin.$_$.
|
|
51
|
-
var initMetadataForCompanion = kotlin_kotlin.$_$.
|
|
52
|
-
var getKClass = kotlin_kotlin.$_$.
|
|
53
|
-
var ClassCastException_init_$Create$ = kotlin_kotlin.$_$.
|
|
54
|
-
var IllegalArgumentException_init_$Create$ = kotlin_kotlin.$_$.
|
|
55
|
-
var to = kotlin_kotlin.$_$.
|
|
46
|
+
var zip = kotlin_kotlin.$_$.ca;
|
|
47
|
+
var flatMap = kotlin_kotlin.$_$.z8;
|
|
48
|
+
var sequenceOf = kotlin_kotlin.$_$.p9;
|
|
49
|
+
var defineProp = kotlin_kotlin.$_$.t6;
|
|
50
|
+
var sequenceOf_0 = kotlin_kotlin.$_$.o9;
|
|
51
|
+
var initMetadataForCompanion = kotlin_kotlin.$_$.c7;
|
|
52
|
+
var getKClass = kotlin_kotlin.$_$.h8;
|
|
53
|
+
var ClassCastException_init_$Create$ = kotlin_kotlin.$_$.d1;
|
|
54
|
+
var IllegalArgumentException_init_$Create$ = kotlin_kotlin.$_$.h1;
|
|
55
|
+
var to = kotlin_kotlin.$_$.oc;
|
|
56
56
|
var Companion_getInstance_0 = kotlin_it_unibo_tuprolog_core.$_$.n;
|
|
57
57
|
var castTo = kotlin_it_unibo_tuprolog_utils.$_$.e;
|
|
58
|
-
var TermConvertible = kotlin_it_unibo_tuprolog_core.$_$.
|
|
58
|
+
var TermConvertible = kotlin_it_unibo_tuprolog_core.$_$.d2;
|
|
59
59
|
var Castable = kotlin_it_unibo_tuprolog_utils.$_$.f;
|
|
60
|
-
var collectionSizeOrDefault = kotlin_kotlin.$_$.
|
|
61
|
-
var ArrayList_init_$Create$_0 = kotlin_kotlin.$_$.
|
|
62
|
-
var initMetadataForInterface = kotlin_kotlin.$_$.
|
|
60
|
+
var collectionSizeOrDefault = kotlin_kotlin.$_$.o2;
|
|
61
|
+
var ArrayList_init_$Create$_0 = kotlin_kotlin.$_$.r;
|
|
62
|
+
var initMetadataForInterface = kotlin_kotlin.$_$.d7;
|
|
63
63
|
//endregion
|
|
64
64
|
//region block: pre-declaration
|
|
65
65
|
initMetadataForClass(Mgu, 'Mgu');
|
|
66
66
|
initMetadataForClass(Merge, 'Merge');
|
|
67
67
|
function mguWithOccurCheck(term1, term2, occurCheckEnabled, $super) {
|
|
68
68
|
occurCheckEnabled = occurCheckEnabled === VOID ? true : occurCheckEnabled;
|
|
69
|
-
return $super === VOID ? this.
|
|
69
|
+
return $super === VOID ? this.g1l(term1, term2, occurCheckEnabled) : $super.g1l.call(this, term1, term2, occurCheckEnabled);
|
|
70
70
|
}
|
|
71
71
|
function mgu(term1, term2) {
|
|
72
|
-
return this.
|
|
72
|
+
return this.g1l(term1, term2, true);
|
|
73
73
|
}
|
|
74
74
|
function matchWithOccurCheck(term1, term2, occurCheckEnabled) {
|
|
75
|
-
return !(this.
|
|
75
|
+
return !(this.g1l(term1, term2, occurCheckEnabled) === Companion_getInstance().failed());
|
|
76
76
|
}
|
|
77
77
|
function match(term1, term2) {
|
|
78
78
|
return this.matchWithOccurCheck(term1, term2, true);
|
|
79
79
|
}
|
|
80
80
|
function unifyWithOccurCheck(term1, term2, occurCheckEnabled) {
|
|
81
|
-
var substitution = this.
|
|
82
|
-
return substitution.
|
|
81
|
+
var substitution = this.g1l(term1, term2, occurCheckEnabled);
|
|
82
|
+
return substitution.v12() ? null : term1.getSubstituted(substitution, []);
|
|
83
83
|
}
|
|
84
84
|
function unify(term1, term2) {
|
|
85
85
|
return this.unifyWithOccurCheck(term1, term2, true);
|
|
@@ -103,17 +103,17 @@
|
|
|
103
103
|
initMetadataForCompanion(Companion_0);
|
|
104
104
|
//endregion
|
|
105
105
|
function Mgu(term1, term2, occurCheckEnabled) {
|
|
106
|
-
this.
|
|
107
|
-
this.
|
|
108
|
-
this.
|
|
106
|
+
this.e1k_1 = term1;
|
|
107
|
+
this.f1k_1 = term2;
|
|
108
|
+
this.g1k_1 = occurCheckEnabled;
|
|
109
109
|
}
|
|
110
110
|
protoOf(Mgu).toString = function () {
|
|
111
|
-
return 'Mgu(term1=' + this.
|
|
111
|
+
return 'Mgu(term1=' + this.e1k_1.toString() + ', term2=' + this.f1k_1.toString() + ', occurCheckEnabled=' + this.g1k_1 + ')';
|
|
112
112
|
};
|
|
113
113
|
protoOf(Mgu).hashCode = function () {
|
|
114
|
-
var result = this.
|
|
115
|
-
result = imul(result, 31) + this.
|
|
116
|
-
result = imul(result, 31) + getBooleanHashCode(this.
|
|
114
|
+
var result = this.e1k_1.hashCode();
|
|
115
|
+
result = imul(result, 31) + this.f1k_1.hashCode() | 0;
|
|
116
|
+
result = imul(result, 31) + getBooleanHashCode(this.g1k_1) | 0;
|
|
117
117
|
return result;
|
|
118
118
|
};
|
|
119
119
|
protoOf(Mgu).equals = function (other) {
|
|
@@ -121,26 +121,26 @@
|
|
|
121
121
|
return true;
|
|
122
122
|
if (!(other instanceof Mgu))
|
|
123
123
|
return false;
|
|
124
|
-
if (!this.
|
|
124
|
+
if (!this.e1k_1.equals(other.e1k_1))
|
|
125
125
|
return false;
|
|
126
|
-
if (!this.
|
|
126
|
+
if (!this.f1k_1.equals(other.f1k_1))
|
|
127
127
|
return false;
|
|
128
|
-
if (!(this.
|
|
128
|
+
if (!(this.g1k_1 === other.g1k_1))
|
|
129
129
|
return false;
|
|
130
130
|
return true;
|
|
131
131
|
};
|
|
132
132
|
function Merge(substitution1, substitution2, occurCheckEnabled) {
|
|
133
|
-
this.
|
|
134
|
-
this.
|
|
135
|
-
this.
|
|
133
|
+
this.h1k_1 = substitution1;
|
|
134
|
+
this.i1k_1 = substitution2;
|
|
135
|
+
this.j1k_1 = occurCheckEnabled;
|
|
136
136
|
}
|
|
137
137
|
protoOf(Merge).toString = function () {
|
|
138
|
-
return 'Merge(substitution1=' + toString(this.
|
|
138
|
+
return 'Merge(substitution1=' + toString(this.h1k_1) + ', substitution2=' + toString(this.i1k_1) + ', occurCheckEnabled=' + this.j1k_1 + ')';
|
|
139
139
|
};
|
|
140
140
|
protoOf(Merge).hashCode = function () {
|
|
141
|
-
var result = hashCode(this.
|
|
142
|
-
result = imul(result, 31) + hashCode(this.
|
|
143
|
-
result = imul(result, 31) + getBooleanHashCode(this.
|
|
141
|
+
var result = hashCode(this.h1k_1);
|
|
142
|
+
result = imul(result, 31) + hashCode(this.i1k_1) | 0;
|
|
143
|
+
result = imul(result, 31) + getBooleanHashCode(this.j1k_1) | 0;
|
|
144
144
|
return result;
|
|
145
145
|
};
|
|
146
146
|
protoOf(Merge).equals = function (other) {
|
|
@@ -148,16 +148,16 @@
|
|
|
148
148
|
return true;
|
|
149
149
|
if (!(other instanceof Merge))
|
|
150
150
|
return false;
|
|
151
|
-
if (!equals(this.
|
|
151
|
+
if (!equals(this.h1k_1, other.h1k_1))
|
|
152
152
|
return false;
|
|
153
|
-
if (!equals(this.
|
|
153
|
+
if (!equals(this.i1k_1, other.i1k_1))
|
|
154
154
|
return false;
|
|
155
|
-
if (!(this.
|
|
155
|
+
if (!(this.j1k_1 === other.j1k_1))
|
|
156
156
|
return false;
|
|
157
157
|
return true;
|
|
158
158
|
};
|
|
159
159
|
function _get_contextEquations__x0dd77($this) {
|
|
160
|
-
var tmp0 = $this.
|
|
160
|
+
var tmp0 = $this.l1k_1;
|
|
161
161
|
var tmp = KProperty1;
|
|
162
162
|
// Inline function 'kotlin.getValue' call
|
|
163
163
|
/* dead property reference removed */
|
|
@@ -165,10 +165,10 @@
|
|
|
165
165
|
}
|
|
166
166
|
function occurrenceCheck($this, variable, term) {
|
|
167
167
|
var tmp;
|
|
168
|
-
if (term.
|
|
169
|
-
tmp = $this.
|
|
170
|
-
} else if (term.
|
|
171
|
-
var tmp0 = term.
|
|
168
|
+
if (term.mx()) {
|
|
169
|
+
tmp = $this.m1k(variable, term);
|
|
170
|
+
} else if (term.ww()) {
|
|
171
|
+
var tmp0 = term.sw();
|
|
172
172
|
var tmp$ret$0;
|
|
173
173
|
$l$block: {
|
|
174
174
|
// Inline function 'kotlin.sequences.any' call
|
|
@@ -190,7 +190,7 @@
|
|
|
190
190
|
}
|
|
191
191
|
function equationsFor($this, term1, term2) {
|
|
192
192
|
var tmp = Companion_instance_0;
|
|
193
|
-
return tmp.
|
|
193
|
+
return tmp.n1k(term1, term2, AbstractUnificator$checkTermsEquality$ref($this));
|
|
194
194
|
}
|
|
195
195
|
function equationsFor_0($this, substitution1, substitution2) {
|
|
196
196
|
var tmp = Companion_instance_0;
|
|
@@ -222,33 +222,33 @@
|
|
|
222
222
|
var changed = true;
|
|
223
223
|
while (changed) {
|
|
224
224
|
changed = false;
|
|
225
|
-
var eqIterator = equations.
|
|
225
|
+
var eqIterator = equations.h4();
|
|
226
226
|
while (eqIterator.q()) {
|
|
227
|
-
var eq = $this.
|
|
228
|
-
if (eq.
|
|
227
|
+
var eq = $this.o1k(request, eqIterator.r());
|
|
228
|
+
if (eq.t1k()) {
|
|
229
229
|
return Companion_getInstance().failed();
|
|
230
|
-
} else if (eq.
|
|
231
|
-
eqIterator.
|
|
230
|
+
} else if (eq.u1k()) {
|
|
231
|
+
eqIterator.i3();
|
|
232
232
|
changed = true;
|
|
233
|
-
} else if (eq.
|
|
233
|
+
} else if (eq.d1l()) {
|
|
234
234
|
var assignment = eq.castToAssignment();
|
|
235
|
-
if (occurCheckEnabled && occurrenceCheck($this, assignment.
|
|
235
|
+
if (occurCheckEnabled && occurrenceCheck($this, assignment.b1l(), assignment.c1l())) {
|
|
236
236
|
return Companion_getInstance().failed();
|
|
237
237
|
} else {
|
|
238
|
-
changed = changed || applySubstitutionToEquations($this, assignment.
|
|
238
|
+
changed = changed || applySubstitutionToEquations($this, assignment.a1l(), equations, eqIterator.x3());
|
|
239
239
|
}
|
|
240
|
-
} else if (eq.
|
|
241
|
-
eqIterator.
|
|
242
|
-
var _iterator__ex2g4s = equationsFor($this, eq.
|
|
240
|
+
} else if (eq.v1k()) {
|
|
241
|
+
eqIterator.i3();
|
|
242
|
+
var _iterator__ex2g4s = equationsFor($this, eq.r1k(), eq.s1k()).n();
|
|
243
243
|
$l$loop: while (_iterator__ex2g4s.q()) {
|
|
244
244
|
var it = _iterator__ex2g4s.r();
|
|
245
|
-
var subEq = it.
|
|
246
|
-
if (subEq.
|
|
245
|
+
var subEq = it.t1k() || it.u1k() ? $this.o1k(request, it) : it;
|
|
246
|
+
if (subEq.u1k())
|
|
247
247
|
continue $l$loop;
|
|
248
|
-
else if (subEq.
|
|
248
|
+
else if (subEq.t1k())
|
|
249
249
|
return Companion_getInstance().failed();
|
|
250
250
|
else {
|
|
251
|
-
eqIterator.
|
|
251
|
+
eqIterator.a4(subEq);
|
|
252
252
|
}
|
|
253
253
|
}
|
|
254
254
|
changed = true;
|
|
@@ -261,11 +261,11 @@
|
|
|
261
261
|
var _iterator__ex2g4s_0 = equations.n();
|
|
262
262
|
while (_iterator__ex2g4s_0.q()) {
|
|
263
263
|
var element = _iterator__ex2g4s_0.r();
|
|
264
|
-
if (element.
|
|
264
|
+
if (element.d1l()) {
|
|
265
265
|
destination.k(element);
|
|
266
266
|
}
|
|
267
267
|
}
|
|
268
|
-
return $this.
|
|
268
|
+
return $this.e1l(request, toSubstitution(destination));
|
|
269
269
|
}
|
|
270
270
|
function newDeque($this, items) {
|
|
271
271
|
// Inline function 'kotlin.collections.arrayListOf' call
|
|
@@ -274,52 +274,52 @@
|
|
|
274
274
|
}
|
|
275
275
|
function AbstractUnificator$contextEquations$delegate$lambda(this$0) {
|
|
276
276
|
return function () {
|
|
277
|
-
return toEquations(this$0.
|
|
277
|
+
return toEquations(this$0.p8());
|
|
278
278
|
};
|
|
279
279
|
}
|
|
280
280
|
function AbstractUnificator$_get_contextEquations_$ref_7ajcte() {
|
|
281
281
|
return constructCallableReference(function (p0) {
|
|
282
282
|
return _get_contextEquations__x0dd77(p0);
|
|
283
|
-
}, 1, 0,
|
|
283
|
+
}, 1, 0, 27);
|
|
284
284
|
}
|
|
285
285
|
function AbstractUnificator$checkTermsEquality$ref(p0) {
|
|
286
286
|
return constructCallableReference(function (p0_0, p1) {
|
|
287
|
-
return p0.
|
|
288
|
-
}, 2, 0,
|
|
287
|
+
return p0.m1k(p0_0, p1);
|
|
288
|
+
}, 2, 0, 28, 'checkTermsEquality', [p0]);
|
|
289
289
|
}
|
|
290
290
|
function AbstractUnificator$equationsFor$lambda(it) {
|
|
291
291
|
// Inline function 'kotlin.collections.toPair' call
|
|
292
292
|
return new Pair(it.e2(), it.f2());
|
|
293
293
|
}
|
|
294
294
|
function applySubstitutionToEquations$handleIndex($equations, $substitution, this$0, changed, i) {
|
|
295
|
-
if ($equations.u(i).
|
|
295
|
+
if ($equations.u(i).t1k() || $equations.u(i).u1k())
|
|
296
296
|
return Unit_instance;
|
|
297
297
|
var currentEq = $equations.u(i);
|
|
298
298
|
var _destruct__k2r9zo = currentEq.apply($substitution).toPair();
|
|
299
|
-
var newLhs = _destruct__k2r9zo.
|
|
300
|
-
var newRhs = _destruct__k2r9zo.
|
|
301
|
-
if (!currentEq.
|
|
299
|
+
var newLhs = _destruct__k2r9zo.td();
|
|
300
|
+
var newRhs = _destruct__k2r9zo.ud();
|
|
301
|
+
if (!currentEq.r1k().equals(newLhs) || !currentEq.s1k().equals(newRhs)) {
|
|
302
302
|
var tmp = Companion_instance_0;
|
|
303
|
-
$equations.
|
|
303
|
+
$equations.f3(i, tmp.f1l(newLhs, newRhs, AbstractUnificator$checkTermsEquality$ref(this$0)));
|
|
304
304
|
changed._v = true;
|
|
305
305
|
}
|
|
306
306
|
}
|
|
307
307
|
function AbstractUnificator(context) {
|
|
308
|
-
this.
|
|
308
|
+
this.k1k_1 = context;
|
|
309
309
|
var tmp = this;
|
|
310
|
-
tmp.
|
|
310
|
+
tmp.l1k_1 = lazy(AbstractUnificator$contextEquations$delegate$lambda(this));
|
|
311
311
|
}
|
|
312
|
-
protoOf(AbstractUnificator).
|
|
313
|
-
return this.
|
|
312
|
+
protoOf(AbstractUnificator).p8 = function () {
|
|
313
|
+
return this.k1k_1;
|
|
314
314
|
};
|
|
315
|
-
protoOf(AbstractUnificator).
|
|
315
|
+
protoOf(AbstractUnificator).e1l = function (request, result) {
|
|
316
316
|
return result;
|
|
317
317
|
};
|
|
318
|
-
protoOf(AbstractUnificator).
|
|
318
|
+
protoOf(AbstractUnificator).o1k = function (request, equation) {
|
|
319
319
|
return equation;
|
|
320
320
|
};
|
|
321
|
-
protoOf(AbstractUnificator).
|
|
322
|
-
if (this.
|
|
321
|
+
protoOf(AbstractUnificator).g1l = function (term1, term2, occurCheckEnabled) {
|
|
322
|
+
if (this.p8().v12())
|
|
323
323
|
return Companion_getInstance().failed();
|
|
324
324
|
var equations = newDeque(this, plus(asSequence_0(_get_contextEquations__x0dd77(this)), equationsFor(this, term1, term2)));
|
|
325
325
|
return mgu_0(this, new Mgu(term1, term2, occurCheckEnabled), equations, occurCheckEnabled);
|
|
@@ -327,12 +327,12 @@
|
|
|
327
327
|
protoOf(AbstractUnificator).mguWithOccurCheck = function (term1, term2, occurCheckEnabled, $super) {
|
|
328
328
|
return this.mguWithOccurCheck(term1, term2, occurCheckEnabled, ($super == null ? true : $super instanceof AbstractUnificator) ? $super : THROW_CCE());
|
|
329
329
|
};
|
|
330
|
-
protoOf(AbstractUnificator).
|
|
331
|
-
if (this.
|
|
330
|
+
protoOf(AbstractUnificator).h1l = function (substitution1, substitution2, occurCheckEnabled) {
|
|
331
|
+
if (this.p8().v12() || substitution1.v12() || substitution2.v12())
|
|
332
332
|
return Companion_getInstance().failed();
|
|
333
333
|
if (!occurCheckEnabled) {
|
|
334
|
-
var quickMerge = this.
|
|
335
|
-
if (quickMerge.
|
|
334
|
+
var quickMerge = this.p8().plus(substitution1).plus(substitution2);
|
|
335
|
+
if (quickMerge.u12()) {
|
|
336
336
|
return quickMerge;
|
|
337
337
|
}
|
|
338
338
|
}
|
|
@@ -340,21 +340,21 @@
|
|
|
340
340
|
return mgu_0(this, new Merge(substitution1, substitution2, occurCheckEnabled), equations, occurCheckEnabled);
|
|
341
341
|
};
|
|
342
342
|
protoOf(AbstractUnificator).mergeWithOccurCheck = function (substitution1, substitution2, occurCheckEnabled) {
|
|
343
|
-
return this.
|
|
343
|
+
return this.h1l(substitution1, substitution2, occurCheckEnabled);
|
|
344
344
|
};
|
|
345
345
|
function CachedUnificator(decorated, cacheCapacity) {
|
|
346
|
-
this.
|
|
347
|
-
this.
|
|
346
|
+
this.i1l_1 = decorated;
|
|
347
|
+
this.j1l_1 = Companion_instance.tq(cacheCapacity);
|
|
348
348
|
}
|
|
349
|
-
protoOf(CachedUnificator).
|
|
349
|
+
protoOf(CachedUnificator).g1l = function (term1, term2, occurCheckEnabled) {
|
|
350
350
|
var mguRequest = new Triple(term1, term2, occurCheckEnabled);
|
|
351
|
-
var cached = this.
|
|
351
|
+
var cached = this.j1l_1.i2(mguRequest);
|
|
352
352
|
var tmp;
|
|
353
353
|
if (cached instanceof Some) {
|
|
354
|
-
tmp = cached.
|
|
354
|
+
tmp = cached.wq_1;
|
|
355
355
|
} else {
|
|
356
|
-
var mguResult = this.
|
|
357
|
-
this.
|
|
356
|
+
var mguResult = this.i1l_1.g1l(term1, term2, occurCheckEnabled);
|
|
357
|
+
this.j1l_1.uq(mguRequest, mguResult);
|
|
358
358
|
tmp = mguResult;
|
|
359
359
|
}
|
|
360
360
|
return tmp;
|
|
@@ -362,21 +362,21 @@
|
|
|
362
362
|
protoOf(CachedUnificator).mguWithOccurCheck = function (term1, term2, occurCheckEnabled, $super) {
|
|
363
363
|
return this.mguWithOccurCheck(term1, term2, occurCheckEnabled, ($super == null ? true : $super instanceof CachedUnificator) ? $super : THROW_CCE());
|
|
364
364
|
};
|
|
365
|
-
protoOf(CachedUnificator).
|
|
365
|
+
protoOf(CachedUnificator).h1l = function (substitution1, substitution2, occurCheckEnabled) {
|
|
366
366
|
var mguRequest = new Triple(substitution1, substitution2, occurCheckEnabled);
|
|
367
|
-
var cached = this.
|
|
367
|
+
var cached = this.j1l_1.i2(mguRequest);
|
|
368
368
|
var tmp;
|
|
369
369
|
if (cached instanceof Some) {
|
|
370
|
-
tmp = cached.
|
|
370
|
+
tmp = cached.wq_1;
|
|
371
371
|
} else {
|
|
372
|
-
var mguResult = this.
|
|
373
|
-
this.
|
|
372
|
+
var mguResult = this.i1l_1.mergeWithOccurCheck(substitution1, substitution2, occurCheckEnabled);
|
|
373
|
+
this.j1l_1.uq(mguRequest, mguResult);
|
|
374
374
|
tmp = mguResult;
|
|
375
375
|
}
|
|
376
376
|
return tmp;
|
|
377
377
|
};
|
|
378
378
|
protoOf(CachedUnificator).mergeWithOccurCheck = function (substitution1, substitution2, occurCheckEnabled) {
|
|
379
|
-
return this.
|
|
379
|
+
return this.h1l(substitution1, substitution2, occurCheckEnabled);
|
|
380
380
|
};
|
|
381
381
|
function allOfLists($this, lhs, rhs, equalityChecker) {
|
|
382
382
|
var tmp;
|
|
@@ -403,64 +403,64 @@
|
|
|
403
403
|
function Term$equals$ref() {
|
|
404
404
|
return constructCallableReference(function (p0, p1) {
|
|
405
405
|
return p0.equals(p1);
|
|
406
|
-
}, 2, 0,
|
|
406
|
+
}, 2, 0, 29, 'equals');
|
|
407
407
|
}
|
|
408
408
|
function Equation$Companion$from$lambda($equalityChecker) {
|
|
409
409
|
return function (it) {
|
|
410
|
-
return Companion_instance_0.
|
|
410
|
+
return Companion_instance_0.k1l(it, $equalityChecker);
|
|
411
411
|
};
|
|
412
412
|
}
|
|
413
413
|
function Equation$Companion$allOfLists$lambda($equalityChecker) {
|
|
414
414
|
return function (_destruct__k2r9zo) {
|
|
415
|
-
var l = _destruct__k2r9zo.
|
|
416
|
-
var r = _destruct__k2r9zo.
|
|
417
|
-
return l.
|
|
415
|
+
var l = _destruct__k2r9zo.td();
|
|
416
|
+
var r = _destruct__k2r9zo.ud();
|
|
417
|
+
return l.dx() && r.dx() ? sequenceOf(Companion_instance_0.f1l(l.castToCons().wy(), r.castToCons().wy(), $equalityChecker)) : l.cx() && r.cx() ? sequenceOf(Companion_instance_0.f1l(l.castToList(), r.castToList(), $equalityChecker)) : Companion_instance_0.n1k(l, r, $equalityChecker);
|
|
418
418
|
};
|
|
419
419
|
}
|
|
420
420
|
function Equation$Companion$allOfTuples$lambda($equalityChecker) {
|
|
421
421
|
return function (_destruct__k2r9zo) {
|
|
422
|
-
var l = _destruct__k2r9zo.
|
|
423
|
-
var r = _destruct__k2r9zo.
|
|
424
|
-
return l.
|
|
422
|
+
var l = _destruct__k2r9zo.td();
|
|
423
|
+
var r = _destruct__k2r9zo.ud();
|
|
424
|
+
return l.bx() && r.bx() ? sequenceOf(Companion_instance_0.f1l(l.castToTuple().ky(), r.castToTuple().ky(), $equalityChecker)) : Companion_instance_0.n1k(l, r, $equalityChecker);
|
|
425
425
|
};
|
|
426
426
|
}
|
|
427
427
|
function Equation$Companion$allOf$lambda($equalityChecker) {
|
|
428
428
|
return function (it) {
|
|
429
|
-
return Companion_instance_0.
|
|
429
|
+
return Companion_instance_0.k1l(it, $equalityChecker);
|
|
430
430
|
};
|
|
431
431
|
}
|
|
432
432
|
function Identity(lhs, rhs) {
|
|
433
433
|
Equation.call(this, lhs, rhs);
|
|
434
|
-
this.
|
|
435
|
-
this.
|
|
434
|
+
this.n1l_1 = lhs;
|
|
435
|
+
this.o1l_1 = rhs;
|
|
436
436
|
}
|
|
437
|
-
protoOf(Identity).
|
|
438
|
-
return this.
|
|
437
|
+
protoOf(Identity).r1k = function () {
|
|
438
|
+
return this.n1l_1;
|
|
439
439
|
};
|
|
440
|
-
protoOf(Identity).
|
|
441
|
-
return this.
|
|
440
|
+
protoOf(Identity).s1k = function () {
|
|
441
|
+
return this.o1l_1;
|
|
442
442
|
};
|
|
443
|
-
protoOf(Identity).
|
|
443
|
+
protoOf(Identity).u1k = function () {
|
|
444
444
|
return true;
|
|
445
445
|
};
|
|
446
|
-
protoOf(Identity).
|
|
446
|
+
protoOf(Identity).p1l = function () {
|
|
447
447
|
return this;
|
|
448
448
|
};
|
|
449
449
|
protoOf(Identity).asIdentity = function () {
|
|
450
|
-
return this.
|
|
450
|
+
return this.p1l();
|
|
451
451
|
};
|
|
452
|
-
protoOf(Identity).
|
|
453
|
-
return this.
|
|
452
|
+
protoOf(Identity).q1l = function (lhs, rhs) {
|
|
453
|
+
return this.r1l(lhs, rhs);
|
|
454
454
|
};
|
|
455
|
-
protoOf(Identity).
|
|
455
|
+
protoOf(Identity).r1l = function (lhs, rhs) {
|
|
456
456
|
return new Identity(lhs, rhs);
|
|
457
457
|
};
|
|
458
458
|
protoOf(Identity).toString = function () {
|
|
459
|
-
return 'Identity(lhs=' + this.
|
|
459
|
+
return 'Identity(lhs=' + this.n1l_1.toString() + ', rhs=' + this.o1l_1.toString() + ')';
|
|
460
460
|
};
|
|
461
461
|
protoOf(Identity).hashCode = function () {
|
|
462
|
-
var result = this.
|
|
463
|
-
result = imul(result, 31) + this.
|
|
462
|
+
var result = this.n1l_1.hashCode();
|
|
463
|
+
result = imul(result, 31) + this.o1l_1.hashCode() | 0;
|
|
464
464
|
return result;
|
|
465
465
|
};
|
|
466
466
|
protoOf(Identity).equals = function (other) {
|
|
@@ -468,90 +468,90 @@
|
|
|
468
468
|
return true;
|
|
469
469
|
if (!(other instanceof Identity))
|
|
470
470
|
return false;
|
|
471
|
-
if (!this.
|
|
471
|
+
if (!this.n1l_1.equals(other.n1l_1))
|
|
472
472
|
return false;
|
|
473
|
-
if (!this.
|
|
473
|
+
if (!this.o1l_1.equals(other.o1l_1))
|
|
474
474
|
return false;
|
|
475
475
|
return true;
|
|
476
476
|
};
|
|
477
477
|
function Assignment(lhs, rhs) {
|
|
478
478
|
Equation.call(this, lhs, rhs);
|
|
479
|
-
this.
|
|
480
|
-
this.
|
|
479
|
+
this.y1k_1 = lhs;
|
|
480
|
+
this.z1k_1 = rhs;
|
|
481
481
|
}
|
|
482
|
-
protoOf(Assignment).
|
|
483
|
-
return this.
|
|
482
|
+
protoOf(Assignment).r1k = function () {
|
|
483
|
+
return this.y1k_1;
|
|
484
484
|
};
|
|
485
|
-
protoOf(Assignment).
|
|
486
|
-
return this.
|
|
485
|
+
protoOf(Assignment).s1k = function () {
|
|
486
|
+
return this.z1k_1;
|
|
487
487
|
};
|
|
488
|
-
protoOf(Assignment).
|
|
488
|
+
protoOf(Assignment).d1l = function () {
|
|
489
489
|
return true;
|
|
490
490
|
};
|
|
491
|
-
protoOf(Assignment).
|
|
491
|
+
protoOf(Assignment).v1l = function () {
|
|
492
492
|
return this;
|
|
493
493
|
};
|
|
494
494
|
protoOf(Assignment).asAssignment = function () {
|
|
495
|
-
return this.
|
|
495
|
+
return this.v1l();
|
|
496
496
|
};
|
|
497
|
-
protoOf(Assignment).
|
|
498
|
-
return new Pair(this.
|
|
497
|
+
protoOf(Assignment).w1l = function () {
|
|
498
|
+
return new Pair(this.b1l(), this.c1l());
|
|
499
499
|
};
|
|
500
500
|
protoOf(Assignment).toAssignmentPair = function () {
|
|
501
|
-
return this.
|
|
501
|
+
return this.w1l();
|
|
502
502
|
};
|
|
503
|
-
protoOf(Assignment).
|
|
504
|
-
return Companion_getInstance().unifier(this.
|
|
503
|
+
protoOf(Assignment).a1l = function () {
|
|
504
|
+
return Companion_getInstance().unifier(this.b1l(), this.c1l());
|
|
505
505
|
};
|
|
506
506
|
protoOf(Assignment).toSubstitution = function () {
|
|
507
|
-
return this.
|
|
507
|
+
return this.a1l();
|
|
508
508
|
};
|
|
509
509
|
function LeftAssignment(lhs, rhs) {
|
|
510
510
|
Assignment.call(this, lhs, rhs);
|
|
511
|
-
this.
|
|
512
|
-
this.
|
|
513
|
-
this.
|
|
514
|
-
this.
|
|
511
|
+
this.b1m_1 = lhs;
|
|
512
|
+
this.c1m_1 = rhs;
|
|
513
|
+
this.d1m_1 = this.b1m_1;
|
|
514
|
+
this.e1m_1 = this.c1m_1;
|
|
515
515
|
}
|
|
516
|
-
protoOf(LeftAssignment).
|
|
517
|
-
return this.
|
|
516
|
+
protoOf(LeftAssignment).r1k = function () {
|
|
517
|
+
return this.b1m_1;
|
|
518
518
|
};
|
|
519
|
-
protoOf(LeftAssignment).
|
|
520
|
-
return this.
|
|
519
|
+
protoOf(LeftAssignment).s1k = function () {
|
|
520
|
+
return this.c1m_1;
|
|
521
521
|
};
|
|
522
|
-
protoOf(LeftAssignment).
|
|
523
|
-
return this.
|
|
522
|
+
protoOf(LeftAssignment).b1l = function () {
|
|
523
|
+
return this.d1m_1;
|
|
524
524
|
};
|
|
525
|
-
protoOf(LeftAssignment).
|
|
526
|
-
return this.
|
|
525
|
+
protoOf(LeftAssignment).c1l = function () {
|
|
526
|
+
return this.e1m_1;
|
|
527
527
|
};
|
|
528
|
-
protoOf(LeftAssignment).
|
|
528
|
+
protoOf(LeftAssignment).s1l = function () {
|
|
529
529
|
return true;
|
|
530
530
|
};
|
|
531
|
-
protoOf(LeftAssignment).
|
|
531
|
+
protoOf(LeftAssignment).f1m = function () {
|
|
532
532
|
return this;
|
|
533
533
|
};
|
|
534
534
|
protoOf(LeftAssignment).asLeftAssignment = function () {
|
|
535
|
-
return this.
|
|
535
|
+
return this.f1m();
|
|
536
536
|
};
|
|
537
|
-
protoOf(LeftAssignment).
|
|
538
|
-
return this.
|
|
537
|
+
protoOf(LeftAssignment).q1l = function (lhs, rhs) {
|
|
538
|
+
return this.g1m(lhs.castToVar(), rhs);
|
|
539
539
|
};
|
|
540
|
-
protoOf(LeftAssignment).
|
|
541
|
-
return new Pair(this.
|
|
540
|
+
protoOf(LeftAssignment).h1m = function () {
|
|
541
|
+
return new Pair(this.b1m_1, this.c1m_1);
|
|
542
542
|
};
|
|
543
543
|
protoOf(LeftAssignment).toPair = function () {
|
|
544
|
-
return this.
|
|
544
|
+
return this.h1m();
|
|
545
545
|
};
|
|
546
|
-
protoOf(LeftAssignment).
|
|
546
|
+
protoOf(LeftAssignment).g1m = function (lhs, rhs) {
|
|
547
547
|
return new LeftAssignment(lhs, rhs);
|
|
548
548
|
};
|
|
549
549
|
protoOf(LeftAssignment).toString = function () {
|
|
550
|
-
return 'LeftAssignment(lhs=' + this.
|
|
550
|
+
return 'LeftAssignment(lhs=' + this.b1m_1.toString() + ', rhs=' + this.c1m_1.toString() + ')';
|
|
551
551
|
};
|
|
552
552
|
protoOf(LeftAssignment).hashCode = function () {
|
|
553
|
-
var result = this.
|
|
554
|
-
result = imul(result, 31) + this.
|
|
553
|
+
var result = this.b1m_1.hashCode();
|
|
554
|
+
result = imul(result, 31) + this.c1m_1.hashCode() | 0;
|
|
555
555
|
return result;
|
|
556
556
|
};
|
|
557
557
|
protoOf(LeftAssignment).equals = function (other) {
|
|
@@ -559,58 +559,58 @@
|
|
|
559
559
|
return true;
|
|
560
560
|
if (!(other instanceof LeftAssignment))
|
|
561
561
|
return false;
|
|
562
|
-
if (!this.
|
|
562
|
+
if (!this.b1m_1.equals(other.b1m_1))
|
|
563
563
|
return false;
|
|
564
|
-
if (!this.
|
|
564
|
+
if (!this.c1m_1.equals(other.c1m_1))
|
|
565
565
|
return false;
|
|
566
566
|
return true;
|
|
567
567
|
};
|
|
568
568
|
function RightAssignment(lhs, rhs) {
|
|
569
569
|
Assignment.call(this, lhs, rhs);
|
|
570
|
-
this.
|
|
571
|
-
this.
|
|
572
|
-
this.
|
|
573
|
-
this.
|
|
570
|
+
this.m1m_1 = lhs;
|
|
571
|
+
this.n1m_1 = rhs;
|
|
572
|
+
this.o1m_1 = this.n1m_1;
|
|
573
|
+
this.p1m_1 = this.m1m_1;
|
|
574
574
|
}
|
|
575
|
-
protoOf(RightAssignment).
|
|
576
|
-
return this.
|
|
575
|
+
protoOf(RightAssignment).r1k = function () {
|
|
576
|
+
return this.m1m_1;
|
|
577
577
|
};
|
|
578
|
-
protoOf(RightAssignment).
|
|
579
|
-
return this.
|
|
578
|
+
protoOf(RightAssignment).s1k = function () {
|
|
579
|
+
return this.n1m_1;
|
|
580
580
|
};
|
|
581
|
-
protoOf(RightAssignment).
|
|
582
|
-
return this.
|
|
581
|
+
protoOf(RightAssignment).b1l = function () {
|
|
582
|
+
return this.o1m_1;
|
|
583
583
|
};
|
|
584
|
-
protoOf(RightAssignment).
|
|
585
|
-
return this.
|
|
584
|
+
protoOf(RightAssignment).c1l = function () {
|
|
585
|
+
return this.p1m_1;
|
|
586
586
|
};
|
|
587
|
-
protoOf(RightAssignment).
|
|
587
|
+
protoOf(RightAssignment).t1l = function () {
|
|
588
588
|
return true;
|
|
589
589
|
};
|
|
590
|
-
protoOf(RightAssignment).
|
|
590
|
+
protoOf(RightAssignment).q1m = function () {
|
|
591
591
|
return this;
|
|
592
592
|
};
|
|
593
593
|
protoOf(RightAssignment).asRightAssignment = function () {
|
|
594
|
-
return this.
|
|
594
|
+
return this.q1m();
|
|
595
595
|
};
|
|
596
|
-
protoOf(RightAssignment).
|
|
597
|
-
return this.
|
|
596
|
+
protoOf(RightAssignment).q1l = function (lhs, rhs) {
|
|
597
|
+
return this.r1m(lhs, rhs.castToVar());
|
|
598
598
|
};
|
|
599
|
-
protoOf(RightAssignment).
|
|
600
|
-
return new Pair(this.
|
|
599
|
+
protoOf(RightAssignment).h1m = function () {
|
|
600
|
+
return new Pair(this.m1m_1, this.n1m_1);
|
|
601
601
|
};
|
|
602
602
|
protoOf(RightAssignment).toPair = function () {
|
|
603
|
-
return this.
|
|
603
|
+
return this.h1m();
|
|
604
604
|
};
|
|
605
|
-
protoOf(RightAssignment).
|
|
605
|
+
protoOf(RightAssignment).r1m = function (lhs, rhs) {
|
|
606
606
|
return new RightAssignment(lhs, rhs);
|
|
607
607
|
};
|
|
608
608
|
protoOf(RightAssignment).toString = function () {
|
|
609
|
-
return 'RightAssignment(lhs=' + this.
|
|
609
|
+
return 'RightAssignment(lhs=' + this.m1m_1.toString() + ', rhs=' + this.n1m_1.toString() + ')';
|
|
610
610
|
};
|
|
611
611
|
protoOf(RightAssignment).hashCode = function () {
|
|
612
|
-
var result = this.
|
|
613
|
-
result = imul(result, 31) + this.
|
|
612
|
+
var result = this.m1m_1.hashCode();
|
|
613
|
+
result = imul(result, 31) + this.n1m_1.hashCode() | 0;
|
|
614
614
|
return result;
|
|
615
615
|
};
|
|
616
616
|
protoOf(RightAssignment).equals = function (other) {
|
|
@@ -618,44 +618,44 @@
|
|
|
618
618
|
return true;
|
|
619
619
|
if (!(other instanceof RightAssignment))
|
|
620
620
|
return false;
|
|
621
|
-
if (!this.
|
|
621
|
+
if (!this.m1m_1.equals(other.m1m_1))
|
|
622
622
|
return false;
|
|
623
|
-
if (!this.
|
|
623
|
+
if (!this.n1m_1.equals(other.n1m_1))
|
|
624
624
|
return false;
|
|
625
625
|
return true;
|
|
626
626
|
};
|
|
627
627
|
function Comparison(lhs, rhs) {
|
|
628
628
|
Equation.call(this, lhs, rhs);
|
|
629
|
-
this.
|
|
630
|
-
this.
|
|
629
|
+
this.u1m_1 = lhs;
|
|
630
|
+
this.v1m_1 = rhs;
|
|
631
631
|
}
|
|
632
|
-
protoOf(Comparison).
|
|
633
|
-
return this.
|
|
632
|
+
protoOf(Comparison).r1k = function () {
|
|
633
|
+
return this.u1m_1;
|
|
634
634
|
};
|
|
635
|
-
protoOf(Comparison).
|
|
636
|
-
return this.
|
|
635
|
+
protoOf(Comparison).s1k = function () {
|
|
636
|
+
return this.v1m_1;
|
|
637
637
|
};
|
|
638
|
-
protoOf(Comparison).
|
|
638
|
+
protoOf(Comparison).v1k = function () {
|
|
639
639
|
return true;
|
|
640
640
|
};
|
|
641
|
-
protoOf(Comparison).
|
|
641
|
+
protoOf(Comparison).w1m = function () {
|
|
642
642
|
return this;
|
|
643
643
|
};
|
|
644
644
|
protoOf(Comparison).asComparison = function () {
|
|
645
|
-
return this.
|
|
645
|
+
return this.w1m();
|
|
646
646
|
};
|
|
647
|
-
protoOf(Comparison).
|
|
648
|
-
return this.
|
|
647
|
+
protoOf(Comparison).q1l = function (lhs, rhs) {
|
|
648
|
+
return this.r1l(lhs, rhs);
|
|
649
649
|
};
|
|
650
|
-
protoOf(Comparison).
|
|
650
|
+
protoOf(Comparison).r1l = function (lhs, rhs) {
|
|
651
651
|
return new Comparison(lhs, rhs);
|
|
652
652
|
};
|
|
653
653
|
protoOf(Comparison).toString = function () {
|
|
654
|
-
return 'Comparison(lhs=' + this.
|
|
654
|
+
return 'Comparison(lhs=' + this.u1m_1.toString() + ', rhs=' + this.v1m_1.toString() + ')';
|
|
655
655
|
};
|
|
656
656
|
protoOf(Comparison).hashCode = function () {
|
|
657
|
-
var result = this.
|
|
658
|
-
result = imul(result, 31) + this.
|
|
657
|
+
var result = this.u1m_1.hashCode();
|
|
658
|
+
result = imul(result, 31) + this.v1m_1.hashCode() | 0;
|
|
659
659
|
return result;
|
|
660
660
|
};
|
|
661
661
|
protoOf(Comparison).equals = function (other) {
|
|
@@ -663,50 +663,50 @@
|
|
|
663
663
|
return true;
|
|
664
664
|
if (!(other instanceof Comparison))
|
|
665
665
|
return false;
|
|
666
|
-
if (!this.
|
|
666
|
+
if (!this.u1m_1.equals(other.u1m_1))
|
|
667
667
|
return false;
|
|
668
|
-
if (!this.
|
|
668
|
+
if (!this.v1m_1.equals(other.v1m_1))
|
|
669
669
|
return false;
|
|
670
670
|
return true;
|
|
671
671
|
};
|
|
672
672
|
function Contradiction(lhs, rhs) {
|
|
673
673
|
Equation.call(this, lhs, rhs);
|
|
674
|
-
this.
|
|
675
|
-
this.
|
|
674
|
+
this.z1m_1 = lhs;
|
|
675
|
+
this.a1n_1 = rhs;
|
|
676
676
|
}
|
|
677
|
-
protoOf(Contradiction).
|
|
678
|
-
return this.
|
|
677
|
+
protoOf(Contradiction).r1k = function () {
|
|
678
|
+
return this.z1m_1;
|
|
679
679
|
};
|
|
680
|
-
protoOf(Contradiction).
|
|
681
|
-
return this.
|
|
680
|
+
protoOf(Contradiction).s1k = function () {
|
|
681
|
+
return this.a1n_1;
|
|
682
682
|
};
|
|
683
|
-
protoOf(Contradiction).
|
|
683
|
+
protoOf(Contradiction).t1k = function () {
|
|
684
684
|
return true;
|
|
685
685
|
};
|
|
686
|
-
protoOf(Contradiction).
|
|
686
|
+
protoOf(Contradiction).b1n = function () {
|
|
687
687
|
return this;
|
|
688
688
|
};
|
|
689
689
|
protoOf(Contradiction).asContradiction = function () {
|
|
690
|
-
return this.
|
|
690
|
+
return this.b1n();
|
|
691
691
|
};
|
|
692
|
-
protoOf(Contradiction).
|
|
693
|
-
return this.
|
|
692
|
+
protoOf(Contradiction).q1l = function (lhs, rhs) {
|
|
693
|
+
return this.r1l(lhs, rhs);
|
|
694
694
|
};
|
|
695
|
-
protoOf(Contradiction).
|
|
695
|
+
protoOf(Contradiction).a1l = function () {
|
|
696
696
|
return Companion_getInstance().failed();
|
|
697
697
|
};
|
|
698
698
|
protoOf(Contradiction).toSubstitution = function () {
|
|
699
|
-
return this.
|
|
699
|
+
return this.a1l();
|
|
700
700
|
};
|
|
701
|
-
protoOf(Contradiction).
|
|
701
|
+
protoOf(Contradiction).r1l = function (lhs, rhs) {
|
|
702
702
|
return new Contradiction(lhs, rhs);
|
|
703
703
|
};
|
|
704
704
|
protoOf(Contradiction).toString = function () {
|
|
705
|
-
return 'Contradiction(lhs=' + this.
|
|
705
|
+
return 'Contradiction(lhs=' + this.z1m_1.toString() + ', rhs=' + this.a1n_1.toString() + ')';
|
|
706
706
|
};
|
|
707
707
|
protoOf(Contradiction).hashCode = function () {
|
|
708
|
-
var result = this.
|
|
709
|
-
result = imul(result, 31) + this.
|
|
708
|
+
var result = this.z1m_1.hashCode();
|
|
709
|
+
result = imul(result, 31) + this.a1n_1.hashCode() | 0;
|
|
710
710
|
return result;
|
|
711
711
|
};
|
|
712
712
|
protoOf(Contradiction).equals = function (other) {
|
|
@@ -714,17 +714,17 @@
|
|
|
714
714
|
return true;
|
|
715
715
|
if (!(other instanceof Contradiction))
|
|
716
716
|
return false;
|
|
717
|
-
if (!this.
|
|
717
|
+
if (!this.z1m_1.equals(other.z1m_1))
|
|
718
718
|
return false;
|
|
719
|
-
if (!this.
|
|
719
|
+
if (!this.a1n_1.equals(other.a1n_1))
|
|
720
720
|
return false;
|
|
721
721
|
return true;
|
|
722
722
|
};
|
|
723
723
|
function Companion() {
|
|
724
724
|
}
|
|
725
|
-
protoOf(Companion).
|
|
725
|
+
protoOf(Companion).f1l = function (lhs, rhs, equalityChecker) {
|
|
726
726
|
var tmp;
|
|
727
|
-
if (lhs.
|
|
727
|
+
if (lhs.mx() && rhs.mx()) {
|
|
728
728
|
var tmp_0;
|
|
729
729
|
if (equalityChecker(lhs, rhs)) {
|
|
730
730
|
tmp_0 = new Identity(lhs, rhs);
|
|
@@ -732,11 +732,11 @@
|
|
|
732
732
|
tmp_0 = new LeftAssignment(lhs.castToVar(), rhs);
|
|
733
733
|
}
|
|
734
734
|
tmp = tmp_0;
|
|
735
|
-
} else if (lhs.
|
|
735
|
+
} else if (lhs.mx()) {
|
|
736
736
|
tmp = new LeftAssignment(lhs.castToVar(), rhs);
|
|
737
|
-
} else if (rhs.
|
|
737
|
+
} else if (rhs.mx()) {
|
|
738
738
|
tmp = new RightAssignment(lhs, rhs.castToVar());
|
|
739
|
-
} else if (lhs.
|
|
739
|
+
} else if (lhs.px() && rhs.px()) {
|
|
740
740
|
var tmp_1;
|
|
741
741
|
if (equalityChecker(lhs, rhs)) {
|
|
742
742
|
tmp_1 = new Identity(lhs, rhs);
|
|
@@ -744,13 +744,13 @@
|
|
|
744
744
|
tmp_1 = new Contradiction(lhs, rhs);
|
|
745
745
|
}
|
|
746
746
|
tmp = tmp_1;
|
|
747
|
-
} else if (lhs.
|
|
747
|
+
} else if (lhs.px() || rhs.px()) {
|
|
748
748
|
tmp = new Contradiction(lhs, rhs);
|
|
749
|
-
} else if (lhs.
|
|
749
|
+
} else if (lhs.ww() && rhs.ww()) {
|
|
750
750
|
var lhsStruct = lhs.castToStruct();
|
|
751
751
|
var rhsStruct = rhs.castToStruct();
|
|
752
752
|
var tmp_2;
|
|
753
|
-
if (!(lhsStruct.
|
|
753
|
+
if (!(lhsStruct.kw() === rhsStruct.kw()) || !(lhsStruct.qw() === rhsStruct.qw())) {
|
|
754
754
|
tmp_2 = new Contradiction(lhsStruct, rhsStruct);
|
|
755
755
|
} else {
|
|
756
756
|
tmp_2 = new Comparison(lhsStruct, rhsStruct);
|
|
@@ -769,10 +769,10 @@
|
|
|
769
769
|
tmp = equalityChecker;
|
|
770
770
|
}
|
|
771
771
|
equalityChecker = tmp;
|
|
772
|
-
return $super === VOID ? this.
|
|
772
|
+
return $super === VOID ? this.f1l(lhs, rhs, equalityChecker) : $super.f1l.call(this, lhs, rhs, equalityChecker);
|
|
773
773
|
};
|
|
774
|
-
protoOf(Companion).
|
|
775
|
-
return this.
|
|
774
|
+
protoOf(Companion).c1n = function (pair, equalityChecker) {
|
|
775
|
+
return this.f1l(pair.first, pair.second, equalityChecker);
|
|
776
776
|
};
|
|
777
777
|
protoOf(Companion).ofPair = function (pair, equalityChecker, $super) {
|
|
778
778
|
var tmp;
|
|
@@ -782,9 +782,9 @@
|
|
|
782
782
|
tmp = equalityChecker;
|
|
783
783
|
}
|
|
784
784
|
equalityChecker = tmp;
|
|
785
|
-
return $super === VOID ? this.
|
|
785
|
+
return $super === VOID ? this.c1n(pair, equalityChecker) : $super.c1n.call(this, pair, equalityChecker);
|
|
786
786
|
};
|
|
787
|
-
protoOf(Companion).
|
|
787
|
+
protoOf(Companion).d1n = function (pairs, equalityChecker) {
|
|
788
788
|
return flatMap(pairs, Equation$Companion$from$lambda(equalityChecker));
|
|
789
789
|
};
|
|
790
790
|
protoOf(Companion).fromSequence = function (pairs, equalityChecker, $super) {
|
|
@@ -795,10 +795,10 @@
|
|
|
795
795
|
tmp = equalityChecker;
|
|
796
796
|
}
|
|
797
797
|
equalityChecker = tmp;
|
|
798
|
-
return $super === VOID ? this.
|
|
798
|
+
return $super === VOID ? this.d1n(pairs, equalityChecker) : $super.d1n.call(this, pairs, equalityChecker);
|
|
799
799
|
};
|
|
800
|
-
protoOf(Companion).
|
|
801
|
-
return this.
|
|
800
|
+
protoOf(Companion).e1n = function (pairs, equalityChecker) {
|
|
801
|
+
return this.d1n(asSequence_0(pairs), equalityChecker);
|
|
802
802
|
};
|
|
803
803
|
protoOf(Companion).fromIterable = function (pairs, equalityChecker, $super) {
|
|
804
804
|
var tmp;
|
|
@@ -808,10 +808,10 @@
|
|
|
808
808
|
tmp = equalityChecker;
|
|
809
809
|
}
|
|
810
810
|
equalityChecker = tmp;
|
|
811
|
-
return $super === VOID ? this.
|
|
811
|
+
return $super === VOID ? this.e1n(pairs, equalityChecker) : $super.e1n.call(this, pairs, equalityChecker);
|
|
812
812
|
};
|
|
813
|
-
protoOf(Companion).
|
|
814
|
-
return this.
|
|
813
|
+
protoOf(Companion).f1n = function (pairs, equalityChecker) {
|
|
814
|
+
return this.d1n(sequenceOf_0(pairs.slice()), equalityChecker);
|
|
815
815
|
};
|
|
816
816
|
protoOf(Companion).from = function (pairs, equalityChecker, $super) {
|
|
817
817
|
var tmp;
|
|
@@ -821,10 +821,10 @@
|
|
|
821
821
|
tmp = equalityChecker;
|
|
822
822
|
}
|
|
823
823
|
equalityChecker = tmp;
|
|
824
|
-
return $super === VOID ? this.
|
|
824
|
+
return $super === VOID ? this.f1n(pairs, equalityChecker) : $super.f1n.call(this, pairs, equalityChecker);
|
|
825
825
|
};
|
|
826
|
-
protoOf(Companion).
|
|
827
|
-
return this.
|
|
826
|
+
protoOf(Companion).k1l = function (pair, equalityChecker) {
|
|
827
|
+
return this.n1k(pair.first, pair.second, equalityChecker);
|
|
828
828
|
};
|
|
829
829
|
protoOf(Companion).allOfPair = function (pair, equalityChecker, $super) {
|
|
830
830
|
var tmp;
|
|
@@ -834,29 +834,29 @@
|
|
|
834
834
|
tmp = equalityChecker;
|
|
835
835
|
}
|
|
836
836
|
equalityChecker = tmp;
|
|
837
|
-
return $super === VOID ? this.
|
|
837
|
+
return $super === VOID ? this.k1l(pair, equalityChecker) : $super.k1l.call(this, pair, equalityChecker);
|
|
838
838
|
};
|
|
839
|
-
protoOf(Companion).
|
|
839
|
+
protoOf(Companion).n1k = function (lhs, rhs, equalityChecker) {
|
|
840
840
|
var tmp;
|
|
841
|
-
if (lhs.
|
|
842
|
-
tmp = sequenceOf(this.
|
|
843
|
-
} else if (lhs.
|
|
841
|
+
if (lhs.lw() && rhs.lw()) {
|
|
842
|
+
tmp = sequenceOf(this.f1l(lhs, rhs, equalityChecker));
|
|
843
|
+
} else if (lhs.cx() && rhs.cx()) {
|
|
844
844
|
tmp = allOfLists(this, lhs.castToList(), rhs.castToList(), equalityChecker);
|
|
845
|
-
} else if (lhs.
|
|
845
|
+
} else if (lhs.bx() && rhs.bx()) {
|
|
846
846
|
tmp = allOfTuples(this, lhs.castToTuple(), rhs.castToTuple(), equalityChecker);
|
|
847
|
-
} else if (lhs.
|
|
847
|
+
} else if (lhs.ww() && rhs.ww()) {
|
|
848
848
|
var lhsStruct = lhs.castToStruct();
|
|
849
849
|
var rhsStruct = rhs.castToStruct();
|
|
850
850
|
var tmp_0;
|
|
851
|
-
if (lhsStruct.
|
|
852
|
-
var tmp_1 = zip(lhsStruct.
|
|
851
|
+
if (lhsStruct.kw() === rhsStruct.kw() && lhsStruct.qw() === rhsStruct.qw()) {
|
|
852
|
+
var tmp_1 = zip(lhsStruct.jx(), rhsStruct.jx());
|
|
853
853
|
tmp_0 = flatMap(tmp_1, Equation$Companion$allOf$lambda(equalityChecker));
|
|
854
854
|
} else {
|
|
855
|
-
tmp_0 = sequenceOf(this.
|
|
855
|
+
tmp_0 = sequenceOf(this.f1l(lhs, rhs, equalityChecker));
|
|
856
856
|
}
|
|
857
857
|
tmp = tmp_0;
|
|
858
858
|
} else {
|
|
859
|
-
tmp = sequenceOf(this.
|
|
859
|
+
tmp = sequenceOf(this.f1l(lhs, rhs, equalityChecker));
|
|
860
860
|
}
|
|
861
861
|
return tmp;
|
|
862
862
|
};
|
|
@@ -868,23 +868,23 @@
|
|
|
868
868
|
tmp = equalityChecker;
|
|
869
869
|
}
|
|
870
870
|
equalityChecker = tmp;
|
|
871
|
-
return $super === VOID ? this.
|
|
871
|
+
return $super === VOID ? this.n1k(lhs, rhs, equalityChecker) : $super.n1k.call(this, lhs, rhs, equalityChecker);
|
|
872
872
|
};
|
|
873
873
|
var Companion_instance_0;
|
|
874
874
|
function Companion_getInstance_1() {
|
|
875
875
|
return Companion_instance_0;
|
|
876
876
|
}
|
|
877
877
|
function Equation(lhs, rhs) {
|
|
878
|
-
this.
|
|
879
|
-
this.
|
|
878
|
+
this.p1k_1 = lhs;
|
|
879
|
+
this.q1k_1 = rhs;
|
|
880
880
|
}
|
|
881
|
-
protoOf(Equation).
|
|
882
|
-
return this.
|
|
881
|
+
protoOf(Equation).r1k = function () {
|
|
882
|
+
return this.p1k_1;
|
|
883
883
|
};
|
|
884
|
-
protoOf(Equation).
|
|
885
|
-
return this.
|
|
884
|
+
protoOf(Equation).s1k = function () {
|
|
885
|
+
return this.q1k_1;
|
|
886
886
|
};
|
|
887
|
-
protoOf(Equation).
|
|
887
|
+
protoOf(Equation).u1k = function () {
|
|
888
888
|
return false;
|
|
889
889
|
};
|
|
890
890
|
protoOf(Equation).asIdentity = function () {
|
|
@@ -894,13 +894,13 @@
|
|
|
894
894
|
var tmp0_elvis_lhs = this.asIdentity();
|
|
895
895
|
var tmp;
|
|
896
896
|
if (tmp0_elvis_lhs == null) {
|
|
897
|
-
throw ClassCastException_init_$Create$('Cannot cast ' + toString(this) + ' to ' + getKClass(Identity).
|
|
897
|
+
throw ClassCastException_init_$Create$('Cannot cast ' + toString(this) + ' to ' + getKClass(Identity).j9());
|
|
898
898
|
} else {
|
|
899
899
|
tmp = tmp0_elvis_lhs;
|
|
900
900
|
}
|
|
901
901
|
return tmp;
|
|
902
902
|
};
|
|
903
|
-
protoOf(Equation).
|
|
903
|
+
protoOf(Equation).d1l = function () {
|
|
904
904
|
return false;
|
|
905
905
|
};
|
|
906
906
|
protoOf(Equation).asAssignment = function () {
|
|
@@ -910,13 +910,13 @@
|
|
|
910
910
|
var tmp0_elvis_lhs = this.asAssignment();
|
|
911
911
|
var tmp;
|
|
912
912
|
if (tmp0_elvis_lhs == null) {
|
|
913
|
-
throw ClassCastException_init_$Create$('Cannot cast ' + toString(this) + ' to ' + getKClass(Assignment).
|
|
913
|
+
throw ClassCastException_init_$Create$('Cannot cast ' + toString(this) + ' to ' + getKClass(Assignment).j9());
|
|
914
914
|
} else {
|
|
915
915
|
tmp = tmp0_elvis_lhs;
|
|
916
916
|
}
|
|
917
917
|
return tmp;
|
|
918
918
|
};
|
|
919
|
-
protoOf(Equation).
|
|
919
|
+
protoOf(Equation).s1l = function () {
|
|
920
920
|
return false;
|
|
921
921
|
};
|
|
922
922
|
protoOf(Equation).asLeftAssignment = function () {
|
|
@@ -926,13 +926,13 @@
|
|
|
926
926
|
var tmp0_elvis_lhs = this.asLeftAssignment();
|
|
927
927
|
var tmp;
|
|
928
928
|
if (tmp0_elvis_lhs == null) {
|
|
929
|
-
throw ClassCastException_init_$Create$('Cannot cast ' + toString(this) + ' to ' + getKClass(LeftAssignment).
|
|
929
|
+
throw ClassCastException_init_$Create$('Cannot cast ' + toString(this) + ' to ' + getKClass(LeftAssignment).j9());
|
|
930
930
|
} else {
|
|
931
931
|
tmp = tmp0_elvis_lhs;
|
|
932
932
|
}
|
|
933
933
|
return tmp;
|
|
934
934
|
};
|
|
935
|
-
protoOf(Equation).
|
|
935
|
+
protoOf(Equation).t1l = function () {
|
|
936
936
|
return false;
|
|
937
937
|
};
|
|
938
938
|
protoOf(Equation).asRightAssignment = function () {
|
|
@@ -942,13 +942,13 @@
|
|
|
942
942
|
var tmp0_elvis_lhs = this.asRightAssignment();
|
|
943
943
|
var tmp;
|
|
944
944
|
if (tmp0_elvis_lhs == null) {
|
|
945
|
-
throw ClassCastException_init_$Create$('Cannot cast ' + toString(this) + ' to ' + getKClass(RightAssignment).
|
|
945
|
+
throw ClassCastException_init_$Create$('Cannot cast ' + toString(this) + ' to ' + getKClass(RightAssignment).j9());
|
|
946
946
|
} else {
|
|
947
947
|
tmp = tmp0_elvis_lhs;
|
|
948
948
|
}
|
|
949
949
|
return tmp;
|
|
950
950
|
};
|
|
951
|
-
protoOf(Equation).
|
|
951
|
+
protoOf(Equation).v1k = function () {
|
|
952
952
|
return false;
|
|
953
953
|
};
|
|
954
954
|
protoOf(Equation).asComparison = function () {
|
|
@@ -958,13 +958,13 @@
|
|
|
958
958
|
var tmp0_elvis_lhs = this.asComparison();
|
|
959
959
|
var tmp;
|
|
960
960
|
if (tmp0_elvis_lhs == null) {
|
|
961
|
-
throw ClassCastException_init_$Create$('Cannot cast ' + toString(this) + ' to ' + getKClass(Comparison).
|
|
961
|
+
throw ClassCastException_init_$Create$('Cannot cast ' + toString(this) + ' to ' + getKClass(Comparison).j9());
|
|
962
962
|
} else {
|
|
963
963
|
tmp = tmp0_elvis_lhs;
|
|
964
964
|
}
|
|
965
965
|
return tmp;
|
|
966
966
|
};
|
|
967
|
-
protoOf(Equation).
|
|
967
|
+
protoOf(Equation).t1k = function () {
|
|
968
968
|
return false;
|
|
969
969
|
};
|
|
970
970
|
protoOf(Equation).asContradiction = function () {
|
|
@@ -974,26 +974,26 @@
|
|
|
974
974
|
var tmp0_elvis_lhs = this.asContradiction();
|
|
975
975
|
var tmp;
|
|
976
976
|
if (tmp0_elvis_lhs == null) {
|
|
977
|
-
throw ClassCastException_init_$Create$('Cannot cast ' + toString(this) + ' to ' + getKClass(Contradiction).
|
|
977
|
+
throw ClassCastException_init_$Create$('Cannot cast ' + toString(this) + ' to ' + getKClass(Contradiction).j9());
|
|
978
978
|
} else {
|
|
979
979
|
tmp = tmp0_elvis_lhs;
|
|
980
980
|
}
|
|
981
981
|
return tmp;
|
|
982
982
|
};
|
|
983
983
|
protoOf(Equation).clone = function (lhs, rhs, $super) {
|
|
984
|
-
lhs = lhs === VOID ? this.
|
|
985
|
-
rhs = rhs === VOID ? this.
|
|
986
|
-
return $super === VOID ? this.
|
|
984
|
+
lhs = lhs === VOID ? this.r1k() : lhs;
|
|
985
|
+
rhs = rhs === VOID ? this.s1k() : rhs;
|
|
986
|
+
return $super === VOID ? this.q1l(lhs, rhs) : $super.q1l.call(this, lhs, rhs);
|
|
987
987
|
};
|
|
988
988
|
protoOf(Equation).toContradiction = function () {
|
|
989
|
-
return new Contradiction(this.
|
|
989
|
+
return new Contradiction(this.r1k(), this.s1k());
|
|
990
990
|
};
|
|
991
991
|
protoOf(Equation).toAssignmentPair = function () {
|
|
992
992
|
var tmp;
|
|
993
|
-
if (this.
|
|
994
|
-
tmp = to(this.
|
|
995
|
-
} else if (this.
|
|
996
|
-
tmp = to(this.
|
|
993
|
+
if (this.r1k().mx()) {
|
|
994
|
+
tmp = to(this.r1k().castToVar(), this.s1k());
|
|
995
|
+
} else if (this.s1k().mx()) {
|
|
996
|
+
tmp = to(this.s1k().castToVar(), this.r1k());
|
|
997
997
|
} else {
|
|
998
998
|
throw IllegalArgumentException_init_$Create$('Equation contains no variables: ' + toString(this));
|
|
999
999
|
}
|
|
@@ -1001,29 +1001,29 @@
|
|
|
1001
1001
|
};
|
|
1002
1002
|
protoOf(Equation).toSubstitution = function () {
|
|
1003
1003
|
var tmp;
|
|
1004
|
-
if (this.
|
|
1005
|
-
tmp = Companion_getInstance().unifier(this.
|
|
1006
|
-
} else if (this.
|
|
1007
|
-
tmp = Companion_getInstance().unifier(this.
|
|
1004
|
+
if (this.r1k().mx()) {
|
|
1005
|
+
tmp = Companion_getInstance().unifier(this.r1k().castToVar(), this.s1k());
|
|
1006
|
+
} else if (this.s1k().mx()) {
|
|
1007
|
+
tmp = Companion_getInstance().unifier(this.s1k().castToVar(), this.r1k());
|
|
1008
1008
|
} else {
|
|
1009
1009
|
throw IllegalArgumentException_init_$Create$('Equation contains no variables: ' + toString(this));
|
|
1010
1010
|
}
|
|
1011
1011
|
return tmp;
|
|
1012
1012
|
};
|
|
1013
|
-
protoOf(Equation).
|
|
1014
|
-
return Companion_getInstance_0().of('=', [this.
|
|
1013
|
+
protoOf(Equation).n1j = function () {
|
|
1014
|
+
return Companion_getInstance_0().of('=', [this.r1k(), this.s1k()]);
|
|
1015
1015
|
};
|
|
1016
1016
|
protoOf(Equation).toTerm = function () {
|
|
1017
|
-
return this.
|
|
1017
|
+
return this.n1j();
|
|
1018
1018
|
};
|
|
1019
1019
|
protoOf(Equation).toPair = function () {
|
|
1020
|
-
return new Pair(this.
|
|
1020
|
+
return new Pair(this.r1k(), this.s1k());
|
|
1021
1021
|
};
|
|
1022
1022
|
protoOf(Equation).swap = function () {
|
|
1023
|
-
return Companion_instance_0.of(this.
|
|
1023
|
+
return Companion_instance_0.of(this.s1k(), this.r1k());
|
|
1024
1024
|
};
|
|
1025
|
-
protoOf(Equation).
|
|
1026
|
-
return Companion_instance_0.
|
|
1025
|
+
protoOf(Equation).u1l = function (substitution, equalityChecker) {
|
|
1026
|
+
return Companion_instance_0.f1l(this.r1k().getSubstituted(substitution, []), this.s1k().getSubstituted(substitution, []), equalityChecker);
|
|
1027
1027
|
};
|
|
1028
1028
|
protoOf(Equation).apply = function (substitution, equalityChecker, $super) {
|
|
1029
1029
|
var tmp;
|
|
@@ -1033,7 +1033,7 @@
|
|
|
1033
1033
|
tmp = equalityChecker;
|
|
1034
1034
|
}
|
|
1035
1035
|
equalityChecker = tmp;
|
|
1036
|
-
return $super === VOID ? this.
|
|
1036
|
+
return $super === VOID ? this.u1l(substitution, equalityChecker) : $super.u1l.call(this, substitution, equalityChecker);
|
|
1037
1037
|
};
|
|
1038
1038
|
function toEquations(_this__u8e3s4) {
|
|
1039
1039
|
// Inline function 'kotlin.collections.map' call
|
|
@@ -1065,18 +1065,18 @@
|
|
|
1065
1065
|
}
|
|
1066
1066
|
function Unificator$Companion$_get_default_$ref_8i2tx3() {
|
|
1067
1067
|
return constructCallableReference(function (p0) {
|
|
1068
|
-
return p0.
|
|
1069
|
-
}, 1, 0,
|
|
1068
|
+
return p0.i1n();
|
|
1069
|
+
}, 1, 0, 30);
|
|
1070
1070
|
}
|
|
1071
1071
|
function Unificator$Companion$naive$1($context) {
|
|
1072
1072
|
AbstractUnificator.call(this, $context);
|
|
1073
1073
|
}
|
|
1074
|
-
protoOf(Unificator$Companion$naive$1).
|
|
1074
|
+
protoOf(Unificator$Companion$naive$1).m1k = function (first, second) {
|
|
1075
1075
|
var tmp;
|
|
1076
|
-
if (first.
|
|
1077
|
-
tmp = first.castToInteger().f2().
|
|
1078
|
-
} else if (first.
|
|
1079
|
-
tmp = first.castToNumeric().
|
|
1076
|
+
if (first.rx() && second.rx()) {
|
|
1077
|
+
tmp = first.castToInteger().f2().al(second.castToInteger().f2()) === 0;
|
|
1078
|
+
} else if (first.qx() && second.qx()) {
|
|
1079
|
+
tmp = first.castToNumeric().g11().rk(second.castToNumeric().g11()) === 0;
|
|
1080
1080
|
} else {
|
|
1081
1081
|
tmp = first.equals(second);
|
|
1082
1082
|
}
|
|
@@ -1088,7 +1088,7 @@
|
|
|
1088
1088
|
function Unificator$Companion$strict$1($context) {
|
|
1089
1089
|
AbstractUnificator.call(this, $context);
|
|
1090
1090
|
}
|
|
1091
|
-
protoOf(Unificator$Companion$strict$1).
|
|
1091
|
+
protoOf(Unificator$Companion$strict$1).m1k = function (first, second) {
|
|
1092
1092
|
return first.equals(second);
|
|
1093
1093
|
};
|
|
1094
1094
|
protoOf(Unificator$Companion$strict$1).mguWithOccurCheck = function (term1, term2, occurCheckEnabled, $super) {
|
|
@@ -1097,27 +1097,27 @@
|
|
|
1097
1097
|
function Companion_0() {
|
|
1098
1098
|
Companion_instance_1 = this;
|
|
1099
1099
|
var tmp = this;
|
|
1100
|
-
tmp.
|
|
1101
|
-
this.
|
|
1100
|
+
tmp.g1n_1 = lazy(Unificator$Companion$default$delegate$lambda);
|
|
1101
|
+
this.h1n_1 = 32;
|
|
1102
1102
|
}
|
|
1103
|
-
protoOf(Companion_0).
|
|
1104
|
-
var tmp0 = this.
|
|
1103
|
+
protoOf(Companion_0).i1n = function () {
|
|
1104
|
+
var tmp0 = this.g1n_1;
|
|
1105
1105
|
var tmp = KProperty1;
|
|
1106
1106
|
// Inline function 'kotlin.getValue' call
|
|
1107
1107
|
/* dead property reference removed */
|
|
1108
1108
|
return tmp0.f2();
|
|
1109
1109
|
};
|
|
1110
1110
|
protoOf(Companion_0).mguWith = function (_this__u8e3s4, other) {
|
|
1111
|
-
return this.
|
|
1111
|
+
return this.i1n().mgu(_this__u8e3s4, other);
|
|
1112
1112
|
};
|
|
1113
1113
|
protoOf(Companion_0).matches = function (_this__u8e3s4, other) {
|
|
1114
|
-
return this.
|
|
1114
|
+
return this.i1n().match(_this__u8e3s4, other);
|
|
1115
1115
|
};
|
|
1116
1116
|
protoOf(Companion_0).unifyWith = function (_this__u8e3s4, other) {
|
|
1117
|
-
return this.
|
|
1117
|
+
return this.i1n().unify(_this__u8e3s4, other);
|
|
1118
1118
|
};
|
|
1119
1119
|
protoOf(Companion_0).mergeWith = function (_this__u8e3s4, other) {
|
|
1120
|
-
return this.
|
|
1120
|
+
return this.i1n().merge(_this__u8e3s4, other);
|
|
1121
1121
|
};
|
|
1122
1122
|
protoOf(Companion_0).naiveWithContext = function (context) {
|
|
1123
1123
|
return new Unificator$Companion$naive$1(context);
|
|
@@ -1131,10 +1131,10 @@
|
|
|
1131
1131
|
protoOf(Companion_0).strict = function () {
|
|
1132
1132
|
return this.strictWithContext(Companion_getInstance().empty());
|
|
1133
1133
|
};
|
|
1134
|
-
protoOf(Companion_0).
|
|
1134
|
+
protoOf(Companion_0).n1n = function (other, capacity) {
|
|
1135
1135
|
var tmp;
|
|
1136
1136
|
if (other instanceof CachedUnificator) {
|
|
1137
|
-
tmp = new CachedUnificator(other.
|
|
1137
|
+
tmp = new CachedUnificator(other.i1l_1, capacity);
|
|
1138
1138
|
} else {
|
|
1139
1139
|
tmp = new CachedUnificator(other, capacity);
|
|
1140
1140
|
}
|
|
@@ -1142,7 +1142,7 @@
|
|
|
1142
1142
|
};
|
|
1143
1143
|
protoOf(Companion_0).cached = function (other, capacity, $super) {
|
|
1144
1144
|
capacity = capacity === VOID ? 32 : capacity;
|
|
1145
|
-
return $super === VOID ? this.
|
|
1145
|
+
return $super === VOID ? this.n1n(other, capacity) : $super.n1n.call(this, other, capacity);
|
|
1146
1146
|
};
|
|
1147
1147
|
var Companion_instance_1;
|
|
1148
1148
|
function Companion_getInstance_2() {
|
|
@@ -1167,38 +1167,38 @@
|
|
|
1167
1167
|
protoOf(CachedUnificator).unifyWithOccurCheck = unifyWithOccurCheck;
|
|
1168
1168
|
protoOf(CachedUnificator).unify = unify;
|
|
1169
1169
|
protoOf(CachedUnificator).merge = merge;
|
|
1170
|
-
protoOf(Equation).
|
|
1170
|
+
protoOf(Equation).dr = castTo;
|
|
1171
1171
|
defineProp(protoOf(Equation), 'lhs', function () {
|
|
1172
|
-
return this.
|
|
1172
|
+
return this.r1k();
|
|
1173
1173
|
});
|
|
1174
1174
|
defineProp(protoOf(Equation), 'rhs', function () {
|
|
1175
|
-
return this.
|
|
1175
|
+
return this.s1k();
|
|
1176
1176
|
});
|
|
1177
1177
|
defineProp(protoOf(Equation), 'isIdentity', function () {
|
|
1178
|
-
return this.
|
|
1178
|
+
return this.u1k();
|
|
1179
1179
|
});
|
|
1180
1180
|
defineProp(protoOf(Equation), 'isAssignment', function () {
|
|
1181
|
-
return this.
|
|
1181
|
+
return this.d1l();
|
|
1182
1182
|
});
|
|
1183
1183
|
defineProp(protoOf(Equation), 'isLeftAssignment', function () {
|
|
1184
|
-
return this.
|
|
1184
|
+
return this.s1l();
|
|
1185
1185
|
});
|
|
1186
1186
|
defineProp(protoOf(Equation), 'isRightAssignment', function () {
|
|
1187
|
-
return this.
|
|
1187
|
+
return this.t1l();
|
|
1188
1188
|
});
|
|
1189
1189
|
defineProp(protoOf(Equation), 'isComparison', function () {
|
|
1190
|
-
return this.
|
|
1190
|
+
return this.v1k();
|
|
1191
1191
|
});
|
|
1192
1192
|
defineProp(protoOf(Equation), 'isContradiction', function () {
|
|
1193
|
-
return this.
|
|
1193
|
+
return this.t1k();
|
|
1194
1194
|
});
|
|
1195
1195
|
defineProp(protoOf(Assignment), 'variable', function () {
|
|
1196
|
-
return this.
|
|
1196
|
+
return this.b1l();
|
|
1197
1197
|
});
|
|
1198
1198
|
defineProp(protoOf(Assignment), 'term', function () {
|
|
1199
|
-
return this.
|
|
1199
|
+
return this.c1l();
|
|
1200
1200
|
});
|
|
1201
|
-
defineProp(protoOf(Companion_0), 'default', protoOf(Companion_0).
|
|
1201
|
+
defineProp(protoOf(Companion_0), 'default', protoOf(Companion_0).i1n);
|
|
1202
1202
|
//endregion
|
|
1203
1203
|
//region block: init
|
|
1204
1204
|
Companion_instance_0 = new Companion();
|