firefly-compiler 0.4.4
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/.firefly-workspace +1 -0
- package/.vscode/settings.json +5 -0
- package/LICENSE.txt +21 -0
- package/README.md +96 -0
- package/bin/firefly.mjs +2 -0
- package/compiler/.firefly/package.ff +1 -0
- package/compiler/Builder.ff +218 -0
- package/compiler/Compiler.ff +241 -0
- package/compiler/Dependencies.ff +179 -0
- package/compiler/Deriver.ff +647 -0
- package/compiler/Dictionaries.ff +205 -0
- package/compiler/Environment.ff +166 -0
- package/compiler/Inference.ff +1117 -0
- package/compiler/JsEmitter.ff +861 -0
- package/compiler/JsImporter.ff +56 -0
- package/compiler/LspHook.ff +188 -0
- package/compiler/Main.ff +237 -0
- package/compiler/Parser.ff +1383 -0
- package/compiler/Patterns.ff +111 -0
- package/compiler/Resolver.ff +620 -0
- package/compiler/Substitution.ff +178 -0
- package/compiler/Syntax.ff +299 -0
- package/compiler/Token.ff +180 -0
- package/compiler/Tokenizer.ff +278 -0
- package/compiler/Unification.ff +220 -0
- package/compiler/Wildcards.ff +50 -0
- package/compiler/Workspace.ff +88 -0
- package/core/.firefly/package.ff +2 -0
- package/core/Any.ff +30 -0
- package/core/Array.ff +249 -0
- package/core/AssetSystem.ff +61 -0
- package/core/Atomic.ff +64 -0
- package/core/Bool.ff +13 -0
- package/core/BrowserSystem.ff +14 -0
- package/core/Buffer.ff +211 -0
- package/core/BuildSystem.ff +144 -0
- package/core/Channel.ff +131 -0
- package/core/Char.ff +18 -0
- package/core/Core.ff +58 -0
- package/core/Duration.ff +15 -0
- package/core/Equal.ff +52 -0
- package/core/Error.ff +20 -0
- package/core/FileHandle.ff +41 -0
- package/core/Float.ff +41 -0
- package/core/HttpClient.ff +84 -0
- package/core/Instant.ff +9 -0
- package/core/Int.ff +61 -0
- package/core/IntMap.ff +85 -0
- package/core/JsSystem.ff +66 -0
- package/core/JsValue.ff +240 -0
- package/core/List.ff +440 -0
- package/core/Lock.ff +144 -0
- package/core/Log.ff +24 -0
- package/core/Map.ff +126 -0
- package/core/NodeSystem.ff +88 -0
- package/core/Nothing.ff +1 -0
- package/core/Option.ff +133 -0
- package/core/Ordering.ff +157 -0
- package/core/Pair.ff +55 -0
- package/core/Path.ff +393 -0
- package/core/RbMap.ff +216 -0
- package/core/Serializable.ff +173 -0
- package/core/Set.ff +38 -0
- package/core/Show.ff +43 -0
- package/core/Stack.ff +263 -0
- package/core/Stream.ff +406 -0
- package/core/String.ff +175 -0
- package/core/StringMap.ff +85 -0
- package/core/Task.ff +138 -0
- package/core/Try.ff +81 -0
- package/core/Unit.ff +3 -0
- package/experimental/random/AltGeneric.ff +44 -0
- package/experimental/random/Async.ff +68 -0
- package/experimental/random/Buffer2.ff +77 -0
- package/experimental/random/Cat.ff +12 -0
- package/experimental/random/Dictionary.ff +52 -0
- package/experimental/random/Example.ff +46 -0
- package/experimental/random/Generic.ff +102 -0
- package/experimental/random/HappyEyeballs.ff +40 -0
- package/experimental/random/HashMap.ff +72 -0
- package/experimental/random/IfElseUnit.ff +9 -0
- package/experimental/random/InputOutput.ff +23 -0
- package/experimental/random/ListVsArray.ff +45 -0
- package/experimental/random/Main.ff +44 -0
- package/experimental/random/MapTest.ff +67 -0
- package/experimental/random/OldTaskSystem.ff +210 -0
- package/experimental/random/PatternTest.ff +39 -0
- package/experimental/random/Patterns.ff +226 -0
- package/experimental/random/ReadBytesTest.ff +10 -0
- package/experimental/random/RunLength.ff +65 -0
- package/experimental/random/Scrape.ff +51 -0
- package/experimental/random/Serialization.ff +217 -0
- package/experimental/random/SerializationTest.ff +46 -0
- package/experimental/random/Serializer.ff +36 -0
- package/experimental/random/StdInOutErr.ff +4 -0
- package/experimental/random/Symbols.ff +74 -0
- package/experimental/random/Tag.ff +49 -0
- package/experimental/random/Tensor.ff +52 -0
- package/experimental/random/Try.ff +56 -0
- package/experimental/random/Tsv.ff +9 -0
- package/experimental/random/TypesAreModules.ff +87 -0
- package/experimental/random/blueprints/Blueprint.ff +52 -0
- package/experimental/random/blueprints/Main.ff +11 -0
- package/experimental/random/blueprints/Pretty.ff +58 -0
- package/experimental/random/blueprints/User.ff +64 -0
- package/experimental/random/blueprintsystem/BlueprintSystem.ff +48 -0
- package/experimental/random/blueprintsystem/Deserialize.ff +53 -0
- package/experimental/random/blueprintsystem/ReadJs.ff +13 -0
- package/experimental/random/blueprintsystem/User.ff +2 -0
- package/experimental/random/kahrs/Kahrs.ff +112 -0
- package/experimental/random/kahrs/TestKahrs.ff +22 -0
- package/experimental/random/kahrs/TestMap.ff +18 -0
- package/experimental/random/streaming/Gzip.ff +3 -0
- package/experimental/random/streaming/Main.ff +34 -0
- package/experimental/random/streaming/S3Bucket.ff +11 -0
- package/experimental/random/streaming/Tar.ff +5 -0
- package/experimental/rhymeapp/Main.ff +81 -0
- package/experimental/rhymeapp/index.html +14 -0
- package/firefly.sh +5 -0
- package/fireflysite/Main.ff +13 -0
- package/httpserver/.firefly/package.ff +1 -0
- package/httpserver/HttpServer.ff +184 -0
- package/lsp/.firefly/package.ff +1 -0
- package/lsp/CompletionHandler.ff +814 -0
- package/lsp/Handler.ff +551 -0
- package/lsp/HoverHandler.ff +82 -0
- package/lsp/LanguageServer.ff +229 -0
- package/lsp/SignatureHelpHandler.ff +55 -0
- package/lsp/SymbolHandler.ff +167 -0
- package/output/js/ff/compiler/Builder.mjs +483 -0
- package/output/js/ff/compiler/Compiler.mjs +410 -0
- package/output/js/ff/compiler/Dependencies.mjs +388 -0
- package/output/js/ff/compiler/Deriver.mjs +1166 -0
- package/output/js/ff/compiler/Dictionaries.mjs +1305 -0
- package/output/js/ff/compiler/Environment.mjs +1005 -0
- package/output/js/ff/compiler/Inference.mjs +4264 -0
- package/output/js/ff/compiler/JsEmitter.mjs +5353 -0
- package/output/js/ff/compiler/JsImporter.mjs +262 -0
- package/output/js/ff/compiler/LspHook.mjs +789 -0
- package/output/js/ff/compiler/Main.mjs +1695 -0
- package/output/js/ff/compiler/Parser.mjs +4004 -0
- package/output/js/ff/compiler/Patterns.mjs +923 -0
- package/output/js/ff/compiler/Resolver.mjs +2303 -0
- package/output/js/ff/compiler/Substitution.mjs +1146 -0
- package/output/js/ff/compiler/Syntax.mjs +12430 -0
- package/output/js/ff/compiler/Token.mjs +3092 -0
- package/output/js/ff/compiler/Tokenizer.mjs +589 -0
- package/output/js/ff/compiler/Unification.mjs +1748 -0
- package/output/js/ff/compiler/Wildcards.mjs +604 -0
- package/output/js/ff/compiler/Workspace.mjs +683 -0
- package/output/js/ff/core/Any.mjs +139 -0
- package/output/js/ff/core/Array.mjs +594 -0
- package/output/js/ff/core/AssetSystem.mjs +270 -0
- package/output/js/ff/core/Atomic.mjs +186 -0
- package/output/js/ff/core/Bool.mjs +141 -0
- package/output/js/ff/core/BrowserSystem.mjs +122 -0
- package/output/js/ff/core/Buffer.mjs +467 -0
- package/output/js/ff/core/BuildSystem.mjs +320 -0
- package/output/js/ff/core/Channel.mjs +268 -0
- package/output/js/ff/core/Char.mjs +145 -0
- package/output/js/ff/core/Core.mjs +300 -0
- package/output/js/ff/core/Duration.mjs +112 -0
- package/output/js/ff/core/Equal.mjs +175 -0
- package/output/js/ff/core/Error.mjs +138 -0
- package/output/js/ff/core/FileHandle.mjs +164 -0
- package/output/js/ff/core/Float.mjs +214 -0
- package/output/js/ff/core/HttpClient.mjs +210 -0
- package/output/js/ff/core/Instant.mjs +105 -0
- package/output/js/ff/core/Int.mjs +254 -0
- package/output/js/ff/core/IntMap.mjs +282 -0
- package/output/js/ff/core/JsSystem.mjs +234 -0
- package/output/js/ff/core/JsValue.mjs +678 -0
- package/output/js/ff/core/List.mjs +2335 -0
- package/output/js/ff/core/Lock.mjs +322 -0
- package/output/js/ff/core/Log.mjs +159 -0
- package/output/js/ff/core/Map.mjs +358 -0
- package/output/js/ff/core/NodeSystem.mjs +288 -0
- package/output/js/ff/core/Nothing.mjs +100 -0
- package/output/js/ff/core/Option.mjs +1002 -0
- package/output/js/ff/core/Ordering.mjs +734 -0
- package/output/js/ff/core/Pair.mjs +318 -0
- package/output/js/ff/core/Path.mjs +768 -0
- package/output/js/ff/core/RbMap.mjs +1936 -0
- package/output/js/ff/core/Serializable.mjs +434 -0
- package/output/js/ff/core/Set.mjs +250 -0
- package/output/js/ff/core/Show.mjs +201 -0
- package/output/js/ff/core/Stack.mjs +595 -0
- package/output/js/ff/core/Stream.mjs +1300 -0
- package/output/js/ff/core/String.mjs +433 -0
- package/output/js/ff/core/StringMap.mjs +282 -0
- package/output/js/ff/core/Task.mjs +345 -0
- package/output/js/ff/core/Try.mjs +503 -0
- package/output/js/ff/core/Unit.mjs +103 -0
- package/package.json +29 -0
- package/postgresql/.firefly/include/package-lock.json +250 -0
- package/postgresql/.firefly/include/package.json +5 -0
- package/postgresql/.firefly/include/prepare.sh +2 -0
- package/postgresql/.firefly/package.ff +3 -0
- package/postgresql/Pg.ff +530 -0
- package/unsafejs/.firefly/package.ff +1 -0
- package/unsafejs/UnsafeJs.ff +19 -0
- package/vscode/.vscode/launch.json +18 -0
- package/vscode/.vscode/tasks.json +33 -0
- package/vscode/LICENSE.txt +21 -0
- package/vscode/Prepublish.ff +15 -0
- package/vscode/README.md +17 -0
- package/vscode/client/package-lock.json +544 -0
- package/vscode/client/package.json +22 -0
- package/vscode/client/src/extension.ts +64 -0
- package/vscode/client/tsconfig.json +12 -0
- package/vscode/icons/firefly-icon.png +0 -0
- package/vscode/icons/firefly-icon.svg +10 -0
- package/vscode/icons/firefly-logo-notext.png +0 -0
- package/vscode/icons/firefly-logo.png +0 -0
- package/vscode/language-configuration.json +39 -0
- package/vscode/package-lock.json +3623 -0
- package/vscode/package.json +144 -0
- package/vscode/snippets-none.json +1 -0
- package/vscode/snippets.json +241 -0
- package/vscode/syntaxes/firefly.tmLanguage.json +294 -0
- package/vscode/tsconfig.json +20 -0
|
@@ -0,0 +1,1005 @@
|
|
|
1
|
+
|
|
2
|
+
|
|
3
|
+
import * as ff_compiler_Environment from "../../ff/compiler/Environment.mjs"
|
|
4
|
+
|
|
5
|
+
import * as ff_compiler_Syntax from "../../ff/compiler/Syntax.mjs"
|
|
6
|
+
|
|
7
|
+
import * as ff_core_Any from "../../ff/core/Any.mjs"
|
|
8
|
+
|
|
9
|
+
import * as ff_core_Array from "../../ff/core/Array.mjs"
|
|
10
|
+
|
|
11
|
+
import * as ff_core_AssetSystem from "../../ff/core/AssetSystem.mjs"
|
|
12
|
+
|
|
13
|
+
import * as ff_core_Atomic from "../../ff/core/Atomic.mjs"
|
|
14
|
+
|
|
15
|
+
import * as ff_core_Bool from "../../ff/core/Bool.mjs"
|
|
16
|
+
|
|
17
|
+
import * as ff_core_BrowserSystem from "../../ff/core/BrowserSystem.mjs"
|
|
18
|
+
|
|
19
|
+
import * as ff_core_Buffer from "../../ff/core/Buffer.mjs"
|
|
20
|
+
|
|
21
|
+
import * as ff_core_BuildSystem from "../../ff/core/BuildSystem.mjs"
|
|
22
|
+
|
|
23
|
+
import * as ff_core_Channel from "../../ff/core/Channel.mjs"
|
|
24
|
+
|
|
25
|
+
import * as ff_core_Char from "../../ff/core/Char.mjs"
|
|
26
|
+
|
|
27
|
+
import * as ff_core_Core from "../../ff/core/Core.mjs"
|
|
28
|
+
|
|
29
|
+
import * as ff_core_Duration from "../../ff/core/Duration.mjs"
|
|
30
|
+
|
|
31
|
+
import * as ff_core_Equal from "../../ff/core/Equal.mjs"
|
|
32
|
+
|
|
33
|
+
import * as ff_core_Error from "../../ff/core/Error.mjs"
|
|
34
|
+
|
|
35
|
+
import * as ff_core_FileHandle from "../../ff/core/FileHandle.mjs"
|
|
36
|
+
|
|
37
|
+
import * as ff_core_Float from "../../ff/core/Float.mjs"
|
|
38
|
+
|
|
39
|
+
import * as ff_core_HttpClient from "../../ff/core/HttpClient.mjs"
|
|
40
|
+
|
|
41
|
+
import * as ff_core_Instant from "../../ff/core/Instant.mjs"
|
|
42
|
+
|
|
43
|
+
import * as ff_core_Int from "../../ff/core/Int.mjs"
|
|
44
|
+
|
|
45
|
+
import * as ff_core_IntMap from "../../ff/core/IntMap.mjs"
|
|
46
|
+
|
|
47
|
+
import * as ff_core_JsSystem from "../../ff/core/JsSystem.mjs"
|
|
48
|
+
|
|
49
|
+
import * as ff_core_JsValue from "../../ff/core/JsValue.mjs"
|
|
50
|
+
|
|
51
|
+
import * as ff_core_List from "../../ff/core/List.mjs"
|
|
52
|
+
|
|
53
|
+
import * as ff_core_Lock from "../../ff/core/Lock.mjs"
|
|
54
|
+
|
|
55
|
+
import * as ff_core_Log from "../../ff/core/Log.mjs"
|
|
56
|
+
|
|
57
|
+
import * as ff_core_Map from "../../ff/core/Map.mjs"
|
|
58
|
+
|
|
59
|
+
import * as ff_core_NodeSystem from "../../ff/core/NodeSystem.mjs"
|
|
60
|
+
|
|
61
|
+
import * as ff_core_Nothing from "../../ff/core/Nothing.mjs"
|
|
62
|
+
|
|
63
|
+
import * as ff_core_Option from "../../ff/core/Option.mjs"
|
|
64
|
+
|
|
65
|
+
import * as ff_core_Ordering from "../../ff/core/Ordering.mjs"
|
|
66
|
+
|
|
67
|
+
import * as ff_core_Pair from "../../ff/core/Pair.mjs"
|
|
68
|
+
|
|
69
|
+
import * as ff_core_Path from "../../ff/core/Path.mjs"
|
|
70
|
+
|
|
71
|
+
import * as ff_core_Serializable from "../../ff/core/Serializable.mjs"
|
|
72
|
+
|
|
73
|
+
import * as ff_core_Set from "../../ff/core/Set.mjs"
|
|
74
|
+
|
|
75
|
+
import * as ff_core_Show from "../../ff/core/Show.mjs"
|
|
76
|
+
|
|
77
|
+
import * as ff_core_Stack from "../../ff/core/Stack.mjs"
|
|
78
|
+
|
|
79
|
+
import * as ff_core_Stream from "../../ff/core/Stream.mjs"
|
|
80
|
+
|
|
81
|
+
import * as ff_core_String from "../../ff/core/String.mjs"
|
|
82
|
+
|
|
83
|
+
import * as ff_core_StringMap from "../../ff/core/StringMap.mjs"
|
|
84
|
+
|
|
85
|
+
import * as ff_core_Task from "../../ff/core/Task.mjs"
|
|
86
|
+
|
|
87
|
+
import * as ff_core_Try from "../../ff/core/Try.mjs"
|
|
88
|
+
|
|
89
|
+
import * as ff_core_Unit from "../../ff/core/Unit.mjs"
|
|
90
|
+
|
|
91
|
+
// type Environment
|
|
92
|
+
export function Environment(modulePrefix_, symbols_, traits_, imports_, effect_, selfVariable_) {
|
|
93
|
+
return {modulePrefix_, symbols_, traits_, imports_, effect_, selfVariable_};
|
|
94
|
+
}
|
|
95
|
+
|
|
96
|
+
// type Scheme
|
|
97
|
+
export function Scheme(isVariable_, isMutable_, isNewtype_, isTraitMethod_, signature_) {
|
|
98
|
+
return {isVariable_, isMutable_, isNewtype_, isTraitMethod_, signature_};
|
|
99
|
+
}
|
|
100
|
+
|
|
101
|
+
// type Instantiated
|
|
102
|
+
export function Instantiated(typeArguments_, scheme_) {
|
|
103
|
+
return {typeArguments_, scheme_};
|
|
104
|
+
}
|
|
105
|
+
|
|
106
|
+
|
|
107
|
+
|
|
108
|
+
export function make_(module_, otherModules_, alreadyFlat_) {
|
|
109
|
+
const processed_ = ff_compiler_Environment.processModule_(module_, true, alreadyFlat_);
|
|
110
|
+
const otherProcessed_ = ff_core_List.List_map(otherModules_, ((_w1) => {
|
|
111
|
+
return ff_compiler_Environment.processModule_(_w1, false, false)
|
|
112
|
+
}));
|
|
113
|
+
return ff_compiler_Environment.Environment(ff_compiler_Environment.fullName_(module_, ""), ff_core_Map.Map_addAll(processed_.symbols_, ff_core_List.List_foldLeft(ff_core_List.List_map(otherProcessed_, ((_w1) => {
|
|
114
|
+
return _w1.symbols_
|
|
115
|
+
})), ff_core_Map.empty_(), ((_w1, _w2) => {
|
|
116
|
+
return ff_core_Map.Map_addAll(_w1, _w2, ff_core_Ordering.ff_core_Ordering_Order$ff_core_String_String)
|
|
117
|
+
})), ff_core_Ordering.ff_core_Ordering_Order$ff_core_String_String), ff_core_Map.Map_addAll(processed_.traits_, ff_core_List.List_foldLeft(ff_core_List.List_map(otherProcessed_, ((_w1) => {
|
|
118
|
+
return _w1.traits_
|
|
119
|
+
})), ff_core_Map.empty_(), ((_w1, _w2) => {
|
|
120
|
+
return ff_core_Map.Map_addAll(_w1, _w2, ff_core_Ordering.ff_core_Ordering_Order$ff_core_String_String)
|
|
121
|
+
})), ff_core_Ordering.ff_core_Ordering_Order$ff_core_String_String), ff_core_List.List_toMap(ff_core_List.List_map(module_.imports_, ((i_) => {
|
|
122
|
+
return ff_core_Pair.Pair(i_.alias_, i_)
|
|
123
|
+
})), ff_core_Ordering.ff_core_Ordering_Order$ff_core_String_String), ff_compiler_Syntax.TConstructor(ff_compiler_Syntax.Location(module_.file_, 0, 0), "ff:core/Nothing.Nothing", ff_core_List.Empty()), ff_core_Option.None())
|
|
124
|
+
}
|
|
125
|
+
|
|
126
|
+
export function fullName_(module_, name_) {
|
|
127
|
+
return ((((ff_compiler_Syntax.PackagePair_groupName(module_.packagePair_, ":") + "/") + ff_core_String.String_dropLast(module_.file_, 3)) + ".") + name_)
|
|
128
|
+
}
|
|
129
|
+
|
|
130
|
+
export function fail_(at_, message_) {
|
|
131
|
+
return ff_core_Core.panic_(((message_ + " ") + ff_compiler_Syntax.Location_show(at_)))
|
|
132
|
+
}
|
|
133
|
+
|
|
134
|
+
export function processModule_(module_, isCurrentModule_, alreadyFlat_) {
|
|
135
|
+
const functions_ = ff_core_List.List_map(module_.functions_, ((d_) => {
|
|
136
|
+
return ff_core_Pair.Pair(ff_compiler_Environment.fullName_(module_, d_.signature_.name_), ff_compiler_Environment.Scheme(false, false, false, false, d_.signature_))
|
|
137
|
+
}));
|
|
138
|
+
const lets_ = ff_core_List.List_map(module_.lets_, ((d_) => {
|
|
139
|
+
const noEffect_ = ff_compiler_Syntax.TConstructor(d_.at_, "ff:core/Nothing.Nothing", ff_core_List.Empty());
|
|
140
|
+
return ff_core_Pair.Pair(ff_compiler_Environment.fullName_(module_, d_.name_), ff_compiler_Environment.Scheme(true, false, false, false, ff_compiler_Syntax.Signature(d_.at_, d_.name_, false, ff_core_List.Empty(), ff_core_List.Empty(), ff_core_List.Empty(), d_.variableType_, noEffect_)))
|
|
141
|
+
}));
|
|
142
|
+
const traitMethods_ = ff_core_List.List_flatMap(module_.traits_, ((definition_) => {
|
|
143
|
+
const generics_ = ff_core_List.List_map(definition_.generics_, ((name_) => {
|
|
144
|
+
return ff_compiler_Syntax.TConstructor(definition_.at_, name_, ff_core_List.Empty())
|
|
145
|
+
}));
|
|
146
|
+
const constraint_ = ff_compiler_Syntax.Constraint(definition_.at_, ff_compiler_Environment.fullName_(module_, definition_.name_), generics_);
|
|
147
|
+
const outerConstraints_ = (alreadyFlat_
|
|
148
|
+
? ff_core_List.Empty()
|
|
149
|
+
: definition_.constraints_);
|
|
150
|
+
return ff_core_List.List_map(definition_.methods_, ((methodSignature_) => {
|
|
151
|
+
const generics_ = ff_core_List.List_partition(ff_core_List.List_addAll(definition_.generics_, methodSignature_.generics_), ((_w1) => {
|
|
152
|
+
return (_w1 === "Q$")
|
|
153
|
+
}));
|
|
154
|
+
const signature_ = (((_c) => {
|
|
155
|
+
return ff_compiler_Syntax.Signature(_c.at_, _c.name_, _c.member_, ff_core_List.List_addAll(ff_core_List.List_takeFirst(generics_.first_, 1), generics_.second_), ff_core_List.Link(constraint_, ff_core_List.List_addAll(outerConstraints_, methodSignature_.constraints_)), _c.parameters_, _c.returnType_, _c.effect_)
|
|
156
|
+
}))(methodSignature_);
|
|
157
|
+
return ff_core_Pair.Pair(ff_compiler_Environment.fullName_(module_, signature_.name_), ff_compiler_Environment.Scheme(false, false, false, true, signature_))
|
|
158
|
+
}))
|
|
159
|
+
}));
|
|
160
|
+
const extends_ = ff_core_List.List_flatMap(module_.extends_, ((d_) => {
|
|
161
|
+
{
|
|
162
|
+
const _1 = d_.type_;
|
|
163
|
+
{
|
|
164
|
+
if(_1.TVariable) {
|
|
165
|
+
const t_ = _1;
|
|
166
|
+
return ff_compiler_Environment.fail_(t_.at_, ("Unexpected type variable: $" + t_.index_))
|
|
167
|
+
return
|
|
168
|
+
}
|
|
169
|
+
}
|
|
170
|
+
{
|
|
171
|
+
if(_1.TConstructor) {
|
|
172
|
+
const t_ = _1;
|
|
173
|
+
const prefix_ = (t_.name_ + "_");
|
|
174
|
+
const selfParameter_ = ff_compiler_Syntax.Parameter(d_.at_, false, d_.name_, d_.type_, ff_core_Option.None());
|
|
175
|
+
return ff_core_List.List_map(d_.methods_, ((method_) => {
|
|
176
|
+
const effect_ = ff_core_List.List_filter(method_.signature_.generics_, ((_w1) => {
|
|
177
|
+
return (_w1 === "Q$")
|
|
178
|
+
}));
|
|
179
|
+
const normalGenerics_ = ff_core_List.List_filter(method_.signature_.generics_, ((_w1) => {
|
|
180
|
+
return (_w1 !== "Q$")
|
|
181
|
+
}));
|
|
182
|
+
const outerGenerics_ = (alreadyFlat_
|
|
183
|
+
? ff_core_List.Empty()
|
|
184
|
+
: d_.generics_);
|
|
185
|
+
return ff_core_Pair.Pair((prefix_ + method_.signature_.name_), ff_compiler_Environment.Scheme(false, false, false, false, (((_c) => {
|
|
186
|
+
return ff_compiler_Syntax.Signature(_c.at_, _c.name_, _c.member_, ff_core_List.List_addAll(effect_, ff_core_List.List_addAll(outerGenerics_, normalGenerics_)), ff_core_List.List_addAll(d_.constraints_, method_.signature_.constraints_), ff_core_List.Link(selfParameter_, method_.signature_.parameters_), _c.returnType_, _c.effect_)
|
|
187
|
+
}))(method_.signature_)))
|
|
188
|
+
}))
|
|
189
|
+
return
|
|
190
|
+
}
|
|
191
|
+
}
|
|
192
|
+
}
|
|
193
|
+
}));
|
|
194
|
+
const fields_ = ff_core_List.List_flatMap(module_.types_, ((d_) => {
|
|
195
|
+
const prefix_ = (d_.name_ + "_");
|
|
196
|
+
const t_ = ff_compiler_Syntax.TConstructor(d_.at_, d_.name_, ff_core_List.List_map(d_.generics_, ((g_) => {
|
|
197
|
+
return ff_compiler_Syntax.TConstructor(d_.at_, g_, ff_core_List.Empty())
|
|
198
|
+
})));
|
|
199
|
+
const selfParameter_ = ff_compiler_Syntax.Parameter(d_.at_, false, d_.name_, t_, ff_core_Option.None());
|
|
200
|
+
return ff_core_List.List_map(d_.commonFields_, ((f_) => {
|
|
201
|
+
const noEffect_ = ff_compiler_Syntax.TConstructor(d_.at_, "ff:core/Nothing.Nothing", ff_core_List.Empty());
|
|
202
|
+
return ff_core_Pair.Pair(ff_compiler_Environment.fullName_(module_, (prefix_ + f_.name_)), ff_compiler_Environment.Scheme(true, f_.mutable_, d_.newtype_, false, ff_compiler_Syntax.Signature(f_.at_, f_.name_, true, d_.generics_, d_.constraints_, ff_core_List.Link(selfParameter_, ff_core_List.Empty()), f_.valueType_, noEffect_)))
|
|
203
|
+
}))
|
|
204
|
+
}));
|
|
205
|
+
const variants_ = ff_core_List.List_flatMap(module_.types_, ((d_) => {
|
|
206
|
+
const returnType_ = ff_compiler_Syntax.TConstructor(d_.at_, ff_compiler_Environment.fullName_(module_, d_.name_), ff_core_List.List_map(d_.generics_, ((typeParameter_) => {
|
|
207
|
+
return ff_compiler_Syntax.TConstructor(d_.at_, typeParameter_, ff_core_List.Empty())
|
|
208
|
+
})));
|
|
209
|
+
return ff_core_List.List_map(d_.variants_, ((variant_) => {
|
|
210
|
+
const noEffect_ = ff_compiler_Syntax.TConstructor(d_.at_, "ff:core/Nothing.Nothing", ff_core_List.Empty());
|
|
211
|
+
return ff_core_Pair.Pair(ff_compiler_Environment.fullName_(module_, variant_.name_), ff_compiler_Environment.Scheme(false, false, d_.newtype_, false, ff_compiler_Syntax.Signature(variant_.at_, variant_.name_, false, d_.generics_, d_.constraints_, ff_core_List.List_addAll(d_.commonFields_, variant_.fields_), returnType_, noEffect_)))
|
|
212
|
+
}))
|
|
213
|
+
}));
|
|
214
|
+
const traits_ = ff_core_List.List_map(module_.traits_, ((d_) => {
|
|
215
|
+
return ff_core_Pair.Pair(ff_compiler_Environment.fullName_(module_, d_.name_), d_)
|
|
216
|
+
}));
|
|
217
|
+
const effect_ = ff_compiler_Syntax.TConstructor(ff_compiler_Syntax.Location(module_.file_, 0, 0), "ff:core/Nothing.Nothing", ff_core_List.Empty());
|
|
218
|
+
return ff_compiler_Environment.Environment("", ff_core_List.List_toMap(ff_core_List.List_addAll(functions_, ff_core_List.List_addAll(lets_, ff_core_List.List_addAll(fields_, ff_core_List.List_addAll(extends_, ff_core_List.List_addAll(variants_, traitMethods_))))), ff_core_Ordering.ff_core_Ordering_Order$ff_core_String_String), ff_core_List.List_toMap(traits_, ff_core_Ordering.ff_core_Ordering_Order$ff_core_String_String), ff_core_List.List_toMap(ff_core_List.Empty(), ff_core_Ordering.ff_core_Ordering_Order$ff_core_String_String), effect_, ff_core_Option.None())
|
|
219
|
+
}
|
|
220
|
+
|
|
221
|
+
export async function make_$(module_, otherModules_, alreadyFlat_, $task) {
|
|
222
|
+
const processed_ = ff_compiler_Environment.processModule_(module_, true, alreadyFlat_);
|
|
223
|
+
const otherProcessed_ = ff_core_List.List_map(otherModules_, ((_w1) => {
|
|
224
|
+
return ff_compiler_Environment.processModule_(_w1, false, false)
|
|
225
|
+
}));
|
|
226
|
+
return ff_compiler_Environment.Environment(ff_compiler_Environment.fullName_(module_, ""), ff_core_Map.Map_addAll(processed_.symbols_, ff_core_List.List_foldLeft(ff_core_List.List_map(otherProcessed_, ((_w1) => {
|
|
227
|
+
return _w1.symbols_
|
|
228
|
+
})), ff_core_Map.empty_(), ((_w1, _w2) => {
|
|
229
|
+
return ff_core_Map.Map_addAll(_w1, _w2, ff_core_Ordering.ff_core_Ordering_Order$ff_core_String_String)
|
|
230
|
+
})), ff_core_Ordering.ff_core_Ordering_Order$ff_core_String_String), ff_core_Map.Map_addAll(processed_.traits_, ff_core_List.List_foldLeft(ff_core_List.List_map(otherProcessed_, ((_w1) => {
|
|
231
|
+
return _w1.traits_
|
|
232
|
+
})), ff_core_Map.empty_(), ((_w1, _w2) => {
|
|
233
|
+
return ff_core_Map.Map_addAll(_w1, _w2, ff_core_Ordering.ff_core_Ordering_Order$ff_core_String_String)
|
|
234
|
+
})), ff_core_Ordering.ff_core_Ordering_Order$ff_core_String_String), ff_core_List.List_toMap(ff_core_List.List_map(module_.imports_, ((i_) => {
|
|
235
|
+
return ff_core_Pair.Pair(i_.alias_, i_)
|
|
236
|
+
})), ff_core_Ordering.ff_core_Ordering_Order$ff_core_String_String), ff_compiler_Syntax.TConstructor(ff_compiler_Syntax.Location(module_.file_, 0, 0), "ff:core/Nothing.Nothing", ff_core_List.Empty()), ff_core_Option.None())
|
|
237
|
+
}
|
|
238
|
+
|
|
239
|
+
export async function fullName_$(module_, name_, $task) {
|
|
240
|
+
return ((((ff_compiler_Syntax.PackagePair_groupName(module_.packagePair_, ":") + "/") + ff_core_String.String_dropLast(module_.file_, 3)) + ".") + name_)
|
|
241
|
+
}
|
|
242
|
+
|
|
243
|
+
export async function fail_$(at_, message_, $task) {
|
|
244
|
+
return ff_core_Core.panic_(((message_ + " ") + ff_compiler_Syntax.Location_show(at_)))
|
|
245
|
+
}
|
|
246
|
+
|
|
247
|
+
export async function processModule_$(module_, isCurrentModule_, alreadyFlat_, $task) {
|
|
248
|
+
const functions_ = ff_core_List.List_map(module_.functions_, ((d_) => {
|
|
249
|
+
return ff_core_Pair.Pair(ff_compiler_Environment.fullName_(module_, d_.signature_.name_), ff_compiler_Environment.Scheme(false, false, false, false, d_.signature_))
|
|
250
|
+
}));
|
|
251
|
+
const lets_ = ff_core_List.List_map(module_.lets_, ((d_) => {
|
|
252
|
+
const noEffect_ = ff_compiler_Syntax.TConstructor(d_.at_, "ff:core/Nothing.Nothing", ff_core_List.Empty());
|
|
253
|
+
return ff_core_Pair.Pair(ff_compiler_Environment.fullName_(module_, d_.name_), ff_compiler_Environment.Scheme(true, false, false, false, ff_compiler_Syntax.Signature(d_.at_, d_.name_, false, ff_core_List.Empty(), ff_core_List.Empty(), ff_core_List.Empty(), d_.variableType_, noEffect_)))
|
|
254
|
+
}));
|
|
255
|
+
const traitMethods_ = ff_core_List.List_flatMap(module_.traits_, ((definition_) => {
|
|
256
|
+
const generics_ = ff_core_List.List_map(definition_.generics_, ((name_) => {
|
|
257
|
+
return ff_compiler_Syntax.TConstructor(definition_.at_, name_, ff_core_List.Empty())
|
|
258
|
+
}));
|
|
259
|
+
const constraint_ = ff_compiler_Syntax.Constraint(definition_.at_, ff_compiler_Environment.fullName_(module_, definition_.name_), generics_);
|
|
260
|
+
const outerConstraints_ = (alreadyFlat_
|
|
261
|
+
? ff_core_List.Empty()
|
|
262
|
+
: definition_.constraints_);
|
|
263
|
+
return ff_core_List.List_map(definition_.methods_, ((methodSignature_) => {
|
|
264
|
+
const generics_ = ff_core_List.List_partition(ff_core_List.List_addAll(definition_.generics_, methodSignature_.generics_), ((_w1) => {
|
|
265
|
+
return (_w1 === "Q$")
|
|
266
|
+
}));
|
|
267
|
+
const signature_ = (((_c) => {
|
|
268
|
+
return ff_compiler_Syntax.Signature(_c.at_, _c.name_, _c.member_, ff_core_List.List_addAll(ff_core_List.List_takeFirst(generics_.first_, 1), generics_.second_), ff_core_List.Link(constraint_, ff_core_List.List_addAll(outerConstraints_, methodSignature_.constraints_)), _c.parameters_, _c.returnType_, _c.effect_)
|
|
269
|
+
}))(methodSignature_);
|
|
270
|
+
return ff_core_Pair.Pair(ff_compiler_Environment.fullName_(module_, signature_.name_), ff_compiler_Environment.Scheme(false, false, false, true, signature_))
|
|
271
|
+
}))
|
|
272
|
+
}));
|
|
273
|
+
const extends_ = ff_core_List.List_flatMap(module_.extends_, ((d_) => {
|
|
274
|
+
{
|
|
275
|
+
const _1 = d_.type_;
|
|
276
|
+
{
|
|
277
|
+
if(_1.TVariable) {
|
|
278
|
+
const t_ = _1;
|
|
279
|
+
return ff_compiler_Environment.fail_(t_.at_, ("Unexpected type variable: $" + t_.index_))
|
|
280
|
+
return
|
|
281
|
+
}
|
|
282
|
+
}
|
|
283
|
+
{
|
|
284
|
+
if(_1.TConstructor) {
|
|
285
|
+
const t_ = _1;
|
|
286
|
+
const prefix_ = (t_.name_ + "_");
|
|
287
|
+
const selfParameter_ = ff_compiler_Syntax.Parameter(d_.at_, false, d_.name_, d_.type_, ff_core_Option.None());
|
|
288
|
+
return ff_core_List.List_map(d_.methods_, ((method_) => {
|
|
289
|
+
const effect_ = ff_core_List.List_filter(method_.signature_.generics_, ((_w1) => {
|
|
290
|
+
return (_w1 === "Q$")
|
|
291
|
+
}));
|
|
292
|
+
const normalGenerics_ = ff_core_List.List_filter(method_.signature_.generics_, ((_w1) => {
|
|
293
|
+
return (_w1 !== "Q$")
|
|
294
|
+
}));
|
|
295
|
+
const outerGenerics_ = (alreadyFlat_
|
|
296
|
+
? ff_core_List.Empty()
|
|
297
|
+
: d_.generics_);
|
|
298
|
+
return ff_core_Pair.Pair((prefix_ + method_.signature_.name_), ff_compiler_Environment.Scheme(false, false, false, false, (((_c) => {
|
|
299
|
+
return ff_compiler_Syntax.Signature(_c.at_, _c.name_, _c.member_, ff_core_List.List_addAll(effect_, ff_core_List.List_addAll(outerGenerics_, normalGenerics_)), ff_core_List.List_addAll(d_.constraints_, method_.signature_.constraints_), ff_core_List.Link(selfParameter_, method_.signature_.parameters_), _c.returnType_, _c.effect_)
|
|
300
|
+
}))(method_.signature_)))
|
|
301
|
+
}))
|
|
302
|
+
return
|
|
303
|
+
}
|
|
304
|
+
}
|
|
305
|
+
}
|
|
306
|
+
}));
|
|
307
|
+
const fields_ = ff_core_List.List_flatMap(module_.types_, ((d_) => {
|
|
308
|
+
const prefix_ = (d_.name_ + "_");
|
|
309
|
+
const t_ = ff_compiler_Syntax.TConstructor(d_.at_, d_.name_, ff_core_List.List_map(d_.generics_, ((g_) => {
|
|
310
|
+
return ff_compiler_Syntax.TConstructor(d_.at_, g_, ff_core_List.Empty())
|
|
311
|
+
})));
|
|
312
|
+
const selfParameter_ = ff_compiler_Syntax.Parameter(d_.at_, false, d_.name_, t_, ff_core_Option.None());
|
|
313
|
+
return ff_core_List.List_map(d_.commonFields_, ((f_) => {
|
|
314
|
+
const noEffect_ = ff_compiler_Syntax.TConstructor(d_.at_, "ff:core/Nothing.Nothing", ff_core_List.Empty());
|
|
315
|
+
return ff_core_Pair.Pair(ff_compiler_Environment.fullName_(module_, (prefix_ + f_.name_)), ff_compiler_Environment.Scheme(true, f_.mutable_, d_.newtype_, false, ff_compiler_Syntax.Signature(f_.at_, f_.name_, true, d_.generics_, d_.constraints_, ff_core_List.Link(selfParameter_, ff_core_List.Empty()), f_.valueType_, noEffect_)))
|
|
316
|
+
}))
|
|
317
|
+
}));
|
|
318
|
+
const variants_ = ff_core_List.List_flatMap(module_.types_, ((d_) => {
|
|
319
|
+
const returnType_ = ff_compiler_Syntax.TConstructor(d_.at_, ff_compiler_Environment.fullName_(module_, d_.name_), ff_core_List.List_map(d_.generics_, ((typeParameter_) => {
|
|
320
|
+
return ff_compiler_Syntax.TConstructor(d_.at_, typeParameter_, ff_core_List.Empty())
|
|
321
|
+
})));
|
|
322
|
+
return ff_core_List.List_map(d_.variants_, ((variant_) => {
|
|
323
|
+
const noEffect_ = ff_compiler_Syntax.TConstructor(d_.at_, "ff:core/Nothing.Nothing", ff_core_List.Empty());
|
|
324
|
+
return ff_core_Pair.Pair(ff_compiler_Environment.fullName_(module_, variant_.name_), ff_compiler_Environment.Scheme(false, false, d_.newtype_, false, ff_compiler_Syntax.Signature(variant_.at_, variant_.name_, false, d_.generics_, d_.constraints_, ff_core_List.List_addAll(d_.commonFields_, variant_.fields_), returnType_, noEffect_)))
|
|
325
|
+
}))
|
|
326
|
+
}));
|
|
327
|
+
const traits_ = ff_core_List.List_map(module_.traits_, ((d_) => {
|
|
328
|
+
return ff_core_Pair.Pair(ff_compiler_Environment.fullName_(module_, d_.name_), d_)
|
|
329
|
+
}));
|
|
330
|
+
const effect_ = ff_compiler_Syntax.TConstructor(ff_compiler_Syntax.Location(module_.file_, 0, 0), "ff:core/Nothing.Nothing", ff_core_List.Empty());
|
|
331
|
+
return ff_compiler_Environment.Environment("", ff_core_List.List_toMap(ff_core_List.List_addAll(functions_, ff_core_List.List_addAll(lets_, ff_core_List.List_addAll(fields_, ff_core_List.List_addAll(extends_, ff_core_List.List_addAll(variants_, traitMethods_))))), ff_core_Ordering.ff_core_Ordering_Order$ff_core_String_String), ff_core_List.List_toMap(traits_, ff_core_Ordering.ff_core_Ordering_Order$ff_core_String_String), ff_core_List.List_toMap(ff_core_List.Empty(), ff_core_Ordering.ff_core_Ordering_Order$ff_core_String_String), effect_, ff_core_Option.None())
|
|
332
|
+
}
|
|
333
|
+
|
|
334
|
+
|
|
335
|
+
|
|
336
|
+
export const ff_core_Any_HasAnyTag$ff_compiler_Environment_Environment = {
|
|
337
|
+
anyTag_() {
|
|
338
|
+
return ff_core_Any.internalAnyTag_((("ff:compiler/Environment.Environment" + "[") + "]"))
|
|
339
|
+
},
|
|
340
|
+
async anyTag_$($task) {
|
|
341
|
+
return ff_core_Any.internalAnyTag_((("ff:compiler/Environment.Environment" + "[") + "]"))
|
|
342
|
+
}
|
|
343
|
+
};
|
|
344
|
+
|
|
345
|
+
export const ff_core_Any_HasAnyTag$ff_compiler_Environment_Scheme = {
|
|
346
|
+
anyTag_() {
|
|
347
|
+
return ff_core_Any.internalAnyTag_((("ff:compiler/Environment.Scheme" + "[") + "]"))
|
|
348
|
+
},
|
|
349
|
+
async anyTag_$($task) {
|
|
350
|
+
return ff_core_Any.internalAnyTag_((("ff:compiler/Environment.Scheme" + "[") + "]"))
|
|
351
|
+
}
|
|
352
|
+
};
|
|
353
|
+
|
|
354
|
+
export const ff_core_Any_HasAnyTag$ff_compiler_Environment_Instantiated = {
|
|
355
|
+
anyTag_() {
|
|
356
|
+
return ff_core_Any.internalAnyTag_((("ff:compiler/Environment.Instantiated" + "[") + "]"))
|
|
357
|
+
},
|
|
358
|
+
async anyTag_$($task) {
|
|
359
|
+
return ff_core_Any.internalAnyTag_((("ff:compiler/Environment.Instantiated" + "[") + "]"))
|
|
360
|
+
}
|
|
361
|
+
};
|
|
362
|
+
|
|
363
|
+
export const ff_core_Show_Show$ff_compiler_Environment_Environment = {
|
|
364
|
+
show_(value_) {
|
|
365
|
+
{
|
|
366
|
+
const value_a = value_;
|
|
367
|
+
{
|
|
368
|
+
const z_ = value_a;
|
|
369
|
+
return ((((((((((((("Environment" + "(") + ff_core_Show.ff_core_Show_Show$ff_core_String_String.show_(z_.modulePrefix_)) + ", ") + ff_core_Map.ff_core_Show_Show$ff_core_Map_Map(ff_core_Show.ff_core_Show_Show$ff_core_String_String, ff_core_Ordering.ff_core_Ordering_Order$ff_core_String_String, ff_compiler_Environment.ff_core_Show_Show$ff_compiler_Environment_Scheme).show_(z_.symbols_)) + ", ") + ff_core_Map.ff_core_Show_Show$ff_core_Map_Map(ff_core_Show.ff_core_Show_Show$ff_core_String_String, ff_core_Ordering.ff_core_Ordering_Order$ff_core_String_String, ff_compiler_Syntax.ff_core_Show_Show$ff_compiler_Syntax_DTrait).show_(z_.traits_)) + ", ") + ff_core_Map.ff_core_Show_Show$ff_core_Map_Map(ff_core_Show.ff_core_Show_Show$ff_core_String_String, ff_core_Ordering.ff_core_Ordering_Order$ff_core_String_String, ff_compiler_Syntax.ff_core_Show_Show$ff_compiler_Syntax_DImport).show_(z_.imports_)) + ", ") + ff_compiler_Syntax.ff_core_Show_Show$ff_compiler_Syntax_Type.show_(z_.effect_)) + ", ") + ff_core_Option.ff_core_Show_Show$ff_core_Option_Option(ff_core_Show.ff_core_Show_Show$ff_core_String_String).show_(z_.selfVariable_)) + ")")
|
|
370
|
+
return
|
|
371
|
+
}
|
|
372
|
+
}
|
|
373
|
+
},
|
|
374
|
+
async show_$(value_, $task) {
|
|
375
|
+
{
|
|
376
|
+
const value_a = value_;
|
|
377
|
+
{
|
|
378
|
+
const z_ = value_a;
|
|
379
|
+
return ((((((((((((("Environment" + "(") + ff_core_Show.ff_core_Show_Show$ff_core_String_String.show_(z_.modulePrefix_)) + ", ") + ff_core_Map.ff_core_Show_Show$ff_core_Map_Map(ff_core_Show.ff_core_Show_Show$ff_core_String_String, ff_core_Ordering.ff_core_Ordering_Order$ff_core_String_String, ff_compiler_Environment.ff_core_Show_Show$ff_compiler_Environment_Scheme).show_(z_.symbols_)) + ", ") + ff_core_Map.ff_core_Show_Show$ff_core_Map_Map(ff_core_Show.ff_core_Show_Show$ff_core_String_String, ff_core_Ordering.ff_core_Ordering_Order$ff_core_String_String, ff_compiler_Syntax.ff_core_Show_Show$ff_compiler_Syntax_DTrait).show_(z_.traits_)) + ", ") + ff_core_Map.ff_core_Show_Show$ff_core_Map_Map(ff_core_Show.ff_core_Show_Show$ff_core_String_String, ff_core_Ordering.ff_core_Ordering_Order$ff_core_String_String, ff_compiler_Syntax.ff_core_Show_Show$ff_compiler_Syntax_DImport).show_(z_.imports_)) + ", ") + ff_compiler_Syntax.ff_core_Show_Show$ff_compiler_Syntax_Type.show_(z_.effect_)) + ", ") + ff_core_Option.ff_core_Show_Show$ff_core_Option_Option(ff_core_Show.ff_core_Show_Show$ff_core_String_String).show_(z_.selfVariable_)) + ")")
|
|
380
|
+
return
|
|
381
|
+
}
|
|
382
|
+
}
|
|
383
|
+
}
|
|
384
|
+
};
|
|
385
|
+
|
|
386
|
+
export const ff_core_Show_Show$ff_compiler_Environment_Scheme = {
|
|
387
|
+
show_(value_) {
|
|
388
|
+
{
|
|
389
|
+
const value_a = value_;
|
|
390
|
+
{
|
|
391
|
+
const z_ = value_a;
|
|
392
|
+
return ((((((((((("Scheme" + "(") + ff_core_Show.ff_core_Show_Show$ff_core_Bool_Bool.show_(z_.isVariable_)) + ", ") + ff_core_Show.ff_core_Show_Show$ff_core_Bool_Bool.show_(z_.isMutable_)) + ", ") + ff_core_Show.ff_core_Show_Show$ff_core_Bool_Bool.show_(z_.isNewtype_)) + ", ") + ff_core_Show.ff_core_Show_Show$ff_core_Bool_Bool.show_(z_.isTraitMethod_)) + ", ") + ff_compiler_Syntax.ff_core_Show_Show$ff_compiler_Syntax_Signature.show_(z_.signature_)) + ")")
|
|
393
|
+
return
|
|
394
|
+
}
|
|
395
|
+
}
|
|
396
|
+
},
|
|
397
|
+
async show_$(value_, $task) {
|
|
398
|
+
{
|
|
399
|
+
const value_a = value_;
|
|
400
|
+
{
|
|
401
|
+
const z_ = value_a;
|
|
402
|
+
return ((((((((((("Scheme" + "(") + ff_core_Show.ff_core_Show_Show$ff_core_Bool_Bool.show_(z_.isVariable_)) + ", ") + ff_core_Show.ff_core_Show_Show$ff_core_Bool_Bool.show_(z_.isMutable_)) + ", ") + ff_core_Show.ff_core_Show_Show$ff_core_Bool_Bool.show_(z_.isNewtype_)) + ", ") + ff_core_Show.ff_core_Show_Show$ff_core_Bool_Bool.show_(z_.isTraitMethod_)) + ", ") + ff_compiler_Syntax.ff_core_Show_Show$ff_compiler_Syntax_Signature.show_(z_.signature_)) + ")")
|
|
403
|
+
return
|
|
404
|
+
}
|
|
405
|
+
}
|
|
406
|
+
}
|
|
407
|
+
};
|
|
408
|
+
|
|
409
|
+
export const ff_core_Show_Show$ff_compiler_Environment_Instantiated = {
|
|
410
|
+
show_(value_) {
|
|
411
|
+
{
|
|
412
|
+
const value_a = value_;
|
|
413
|
+
{
|
|
414
|
+
const z_ = value_a;
|
|
415
|
+
return ((((("Instantiated" + "(") + ff_core_Show.ff_core_Show_Show$ff_core_List_List(ff_core_Show.ff_core_Show_Show$ff_core_Pair_Pair(ff_core_Show.ff_core_Show_Show$ff_core_String_String, ff_compiler_Syntax.ff_core_Show_Show$ff_compiler_Syntax_Type)).show_(z_.typeArguments_)) + ", ") + ff_compiler_Environment.ff_core_Show_Show$ff_compiler_Environment_Scheme.show_(z_.scheme_)) + ")")
|
|
416
|
+
return
|
|
417
|
+
}
|
|
418
|
+
}
|
|
419
|
+
},
|
|
420
|
+
async show_$(value_, $task) {
|
|
421
|
+
{
|
|
422
|
+
const value_a = value_;
|
|
423
|
+
{
|
|
424
|
+
const z_ = value_a;
|
|
425
|
+
return ((((("Instantiated" + "(") + ff_core_Show.ff_core_Show_Show$ff_core_List_List(ff_core_Show.ff_core_Show_Show$ff_core_Pair_Pair(ff_core_Show.ff_core_Show_Show$ff_core_String_String, ff_compiler_Syntax.ff_core_Show_Show$ff_compiler_Syntax_Type)).show_(z_.typeArguments_)) + ", ") + ff_compiler_Environment.ff_core_Show_Show$ff_compiler_Environment_Scheme.show_(z_.scheme_)) + ")")
|
|
426
|
+
return
|
|
427
|
+
}
|
|
428
|
+
}
|
|
429
|
+
}
|
|
430
|
+
};
|
|
431
|
+
|
|
432
|
+
export const ff_core_Equal_Equal$ff_compiler_Environment_Environment = {
|
|
433
|
+
equals_(x_, y_) {
|
|
434
|
+
{
|
|
435
|
+
const x_a = x_;
|
|
436
|
+
const y_a = y_;
|
|
437
|
+
{
|
|
438
|
+
const _guard1 = (x_ === y_);
|
|
439
|
+
if(_guard1) {
|
|
440
|
+
return true
|
|
441
|
+
return
|
|
442
|
+
}
|
|
443
|
+
}
|
|
444
|
+
{
|
|
445
|
+
return ((x_.modulePrefix_ === y_.modulePrefix_) && (ff_core_Map.ff_core_Equal_Equal$ff_core_Map_Map(ff_core_Equal.ff_core_Equal_Equal$ff_core_String_String, ff_core_Ordering.ff_core_Ordering_Order$ff_core_String_String, ff_compiler_Environment.ff_core_Equal_Equal$ff_compiler_Environment_Scheme).equals_(x_.symbols_, y_.symbols_) && (ff_core_Map.ff_core_Equal_Equal$ff_core_Map_Map(ff_core_Equal.ff_core_Equal_Equal$ff_core_String_String, ff_core_Ordering.ff_core_Ordering_Order$ff_core_String_String, ff_compiler_Syntax.ff_core_Equal_Equal$ff_compiler_Syntax_DTrait).equals_(x_.traits_, y_.traits_) && (ff_core_Map.ff_core_Equal_Equal$ff_core_Map_Map(ff_core_Equal.ff_core_Equal_Equal$ff_core_String_String, ff_core_Ordering.ff_core_Ordering_Order$ff_core_String_String, ff_compiler_Syntax.ff_core_Equal_Equal$ff_compiler_Syntax_DImport).equals_(x_.imports_, y_.imports_) && (ff_compiler_Syntax.ff_core_Equal_Equal$ff_compiler_Syntax_Type.equals_(x_.effect_, y_.effect_) && ff_core_Option.ff_core_Equal_Equal$ff_core_Option_Option(ff_core_Equal.ff_core_Equal_Equal$ff_core_String_String).equals_(x_.selfVariable_, y_.selfVariable_))))))
|
|
446
|
+
return
|
|
447
|
+
}
|
|
448
|
+
}
|
|
449
|
+
},
|
|
450
|
+
async equals_$(x_, y_, $task) {
|
|
451
|
+
{
|
|
452
|
+
const x_a = x_;
|
|
453
|
+
const y_a = y_;
|
|
454
|
+
{
|
|
455
|
+
const _guard1 = (x_ === y_);
|
|
456
|
+
if(_guard1) {
|
|
457
|
+
return true
|
|
458
|
+
return
|
|
459
|
+
}
|
|
460
|
+
}
|
|
461
|
+
{
|
|
462
|
+
return ((x_.modulePrefix_ === y_.modulePrefix_) && (ff_core_Map.ff_core_Equal_Equal$ff_core_Map_Map(ff_core_Equal.ff_core_Equal_Equal$ff_core_String_String, ff_core_Ordering.ff_core_Ordering_Order$ff_core_String_String, ff_compiler_Environment.ff_core_Equal_Equal$ff_compiler_Environment_Scheme).equals_(x_.symbols_, y_.symbols_) && (ff_core_Map.ff_core_Equal_Equal$ff_core_Map_Map(ff_core_Equal.ff_core_Equal_Equal$ff_core_String_String, ff_core_Ordering.ff_core_Ordering_Order$ff_core_String_String, ff_compiler_Syntax.ff_core_Equal_Equal$ff_compiler_Syntax_DTrait).equals_(x_.traits_, y_.traits_) && (ff_core_Map.ff_core_Equal_Equal$ff_core_Map_Map(ff_core_Equal.ff_core_Equal_Equal$ff_core_String_String, ff_core_Ordering.ff_core_Ordering_Order$ff_core_String_String, ff_compiler_Syntax.ff_core_Equal_Equal$ff_compiler_Syntax_DImport).equals_(x_.imports_, y_.imports_) && (ff_compiler_Syntax.ff_core_Equal_Equal$ff_compiler_Syntax_Type.equals_(x_.effect_, y_.effect_) && ff_core_Option.ff_core_Equal_Equal$ff_core_Option_Option(ff_core_Equal.ff_core_Equal_Equal$ff_core_String_String).equals_(x_.selfVariable_, y_.selfVariable_))))))
|
|
463
|
+
return
|
|
464
|
+
}
|
|
465
|
+
}
|
|
466
|
+
}
|
|
467
|
+
};
|
|
468
|
+
|
|
469
|
+
export const ff_core_Equal_Equal$ff_compiler_Environment_Scheme = {
|
|
470
|
+
equals_(x_, y_) {
|
|
471
|
+
{
|
|
472
|
+
const x_a = x_;
|
|
473
|
+
const y_a = y_;
|
|
474
|
+
{
|
|
475
|
+
const _guard1 = (x_ === y_);
|
|
476
|
+
if(_guard1) {
|
|
477
|
+
return true
|
|
478
|
+
return
|
|
479
|
+
}
|
|
480
|
+
}
|
|
481
|
+
{
|
|
482
|
+
return ((x_.isVariable_ === y_.isVariable_) && ((x_.isMutable_ === y_.isMutable_) && ((x_.isNewtype_ === y_.isNewtype_) && ((x_.isTraitMethod_ === y_.isTraitMethod_) && ff_compiler_Syntax.ff_core_Equal_Equal$ff_compiler_Syntax_Signature.equals_(x_.signature_, y_.signature_)))))
|
|
483
|
+
return
|
|
484
|
+
}
|
|
485
|
+
}
|
|
486
|
+
},
|
|
487
|
+
async equals_$(x_, y_, $task) {
|
|
488
|
+
{
|
|
489
|
+
const x_a = x_;
|
|
490
|
+
const y_a = y_;
|
|
491
|
+
{
|
|
492
|
+
const _guard1 = (x_ === y_);
|
|
493
|
+
if(_guard1) {
|
|
494
|
+
return true
|
|
495
|
+
return
|
|
496
|
+
}
|
|
497
|
+
}
|
|
498
|
+
{
|
|
499
|
+
return ((x_.isVariable_ === y_.isVariable_) && ((x_.isMutable_ === y_.isMutable_) && ((x_.isNewtype_ === y_.isNewtype_) && ((x_.isTraitMethod_ === y_.isTraitMethod_) && ff_compiler_Syntax.ff_core_Equal_Equal$ff_compiler_Syntax_Signature.equals_(x_.signature_, y_.signature_)))))
|
|
500
|
+
return
|
|
501
|
+
}
|
|
502
|
+
}
|
|
503
|
+
}
|
|
504
|
+
};
|
|
505
|
+
|
|
506
|
+
export const ff_core_Equal_Equal$ff_compiler_Environment_Instantiated = {
|
|
507
|
+
equals_(x_, y_) {
|
|
508
|
+
{
|
|
509
|
+
const x_a = x_;
|
|
510
|
+
const y_a = y_;
|
|
511
|
+
{
|
|
512
|
+
const _guard1 = (x_ === y_);
|
|
513
|
+
if(_guard1) {
|
|
514
|
+
return true
|
|
515
|
+
return
|
|
516
|
+
}
|
|
517
|
+
}
|
|
518
|
+
{
|
|
519
|
+
return (ff_core_List.ff_core_Equal_Equal$ff_core_List_List(ff_core_Pair.ff_core_Equal_Equal$ff_core_Pair_Pair(ff_core_Equal.ff_core_Equal_Equal$ff_core_String_String, ff_compiler_Syntax.ff_core_Equal_Equal$ff_compiler_Syntax_Type)).equals_(x_.typeArguments_, y_.typeArguments_) && ff_compiler_Environment.ff_core_Equal_Equal$ff_compiler_Environment_Scheme.equals_(x_.scheme_, y_.scheme_))
|
|
520
|
+
return
|
|
521
|
+
}
|
|
522
|
+
}
|
|
523
|
+
},
|
|
524
|
+
async equals_$(x_, y_, $task) {
|
|
525
|
+
{
|
|
526
|
+
const x_a = x_;
|
|
527
|
+
const y_a = y_;
|
|
528
|
+
{
|
|
529
|
+
const _guard1 = (x_ === y_);
|
|
530
|
+
if(_guard1) {
|
|
531
|
+
return true
|
|
532
|
+
return
|
|
533
|
+
}
|
|
534
|
+
}
|
|
535
|
+
{
|
|
536
|
+
return (ff_core_List.ff_core_Equal_Equal$ff_core_List_List(ff_core_Pair.ff_core_Equal_Equal$ff_core_Pair_Pair(ff_core_Equal.ff_core_Equal_Equal$ff_core_String_String, ff_compiler_Syntax.ff_core_Equal_Equal$ff_compiler_Syntax_Type)).equals_(x_.typeArguments_, y_.typeArguments_) && ff_compiler_Environment.ff_core_Equal_Equal$ff_compiler_Environment_Scheme.equals_(x_.scheme_, y_.scheme_))
|
|
537
|
+
return
|
|
538
|
+
}
|
|
539
|
+
}
|
|
540
|
+
}
|
|
541
|
+
};
|
|
542
|
+
|
|
543
|
+
export const ff_core_Ordering_Order$ff_compiler_Environment_Environment = {
|
|
544
|
+
compare_(x_, y_) {
|
|
545
|
+
{
|
|
546
|
+
const x_a = x_;
|
|
547
|
+
const y_a = y_;
|
|
548
|
+
{
|
|
549
|
+
const _guard1 = (x_ === y_);
|
|
550
|
+
if(_guard1) {
|
|
551
|
+
return ff_core_Ordering.OrderingSame()
|
|
552
|
+
return
|
|
553
|
+
}
|
|
554
|
+
}
|
|
555
|
+
{
|
|
556
|
+
const modulePrefixOrdering_ = ff_core_Ordering.ff_core_Ordering_Order$ff_core_String_String.compare_(x_.modulePrefix_, y_.modulePrefix_);
|
|
557
|
+
if((modulePrefixOrdering_ !== ff_core_Ordering.OrderingSame())) {
|
|
558
|
+
return modulePrefixOrdering_
|
|
559
|
+
} else {
|
|
560
|
+
const symbolsOrdering_ = ff_core_Map.ff_core_Ordering_Order$ff_core_Map_Map(ff_core_Ordering.ff_core_Ordering_Order$ff_core_String_String, ff_compiler_Environment.ff_core_Ordering_Order$ff_compiler_Environment_Scheme).compare_(x_.symbols_, y_.symbols_);
|
|
561
|
+
if((symbolsOrdering_ !== ff_core_Ordering.OrderingSame())) {
|
|
562
|
+
return symbolsOrdering_
|
|
563
|
+
} else {
|
|
564
|
+
const traitsOrdering_ = ff_core_Map.ff_core_Ordering_Order$ff_core_Map_Map(ff_core_Ordering.ff_core_Ordering_Order$ff_core_String_String, ff_compiler_Syntax.ff_core_Ordering_Order$ff_compiler_Syntax_DTrait).compare_(x_.traits_, y_.traits_);
|
|
565
|
+
if((traitsOrdering_ !== ff_core_Ordering.OrderingSame())) {
|
|
566
|
+
return traitsOrdering_
|
|
567
|
+
} else {
|
|
568
|
+
const importsOrdering_ = ff_core_Map.ff_core_Ordering_Order$ff_core_Map_Map(ff_core_Ordering.ff_core_Ordering_Order$ff_core_String_String, ff_compiler_Syntax.ff_core_Ordering_Order$ff_compiler_Syntax_DImport).compare_(x_.imports_, y_.imports_);
|
|
569
|
+
if((importsOrdering_ !== ff_core_Ordering.OrderingSame())) {
|
|
570
|
+
return importsOrdering_
|
|
571
|
+
} else {
|
|
572
|
+
const effectOrdering_ = ff_compiler_Syntax.ff_core_Ordering_Order$ff_compiler_Syntax_Type.compare_(x_.effect_, y_.effect_);
|
|
573
|
+
if((effectOrdering_ !== ff_core_Ordering.OrderingSame())) {
|
|
574
|
+
return effectOrdering_
|
|
575
|
+
} else {
|
|
576
|
+
const selfVariableOrdering_ = ff_core_Option.ff_core_Ordering_Order$ff_core_Option_Option(ff_core_Ordering.ff_core_Ordering_Order$ff_core_String_String).compare_(x_.selfVariable_, y_.selfVariable_);
|
|
577
|
+
if((selfVariableOrdering_ !== ff_core_Ordering.OrderingSame())) {
|
|
578
|
+
return selfVariableOrdering_
|
|
579
|
+
} else {
|
|
580
|
+
return ff_core_Ordering.OrderingSame()
|
|
581
|
+
}
|
|
582
|
+
}
|
|
583
|
+
}
|
|
584
|
+
}
|
|
585
|
+
}
|
|
586
|
+
}
|
|
587
|
+
return
|
|
588
|
+
}
|
|
589
|
+
}
|
|
590
|
+
},
|
|
591
|
+
async compare_$(x_, y_, $task) {
|
|
592
|
+
{
|
|
593
|
+
const x_a = x_;
|
|
594
|
+
const y_a = y_;
|
|
595
|
+
{
|
|
596
|
+
const _guard1 = (x_ === y_);
|
|
597
|
+
if(_guard1) {
|
|
598
|
+
return ff_core_Ordering.OrderingSame()
|
|
599
|
+
return
|
|
600
|
+
}
|
|
601
|
+
}
|
|
602
|
+
{
|
|
603
|
+
const modulePrefixOrdering_ = ff_core_Ordering.ff_core_Ordering_Order$ff_core_String_String.compare_(x_.modulePrefix_, y_.modulePrefix_);
|
|
604
|
+
if((modulePrefixOrdering_ !== ff_core_Ordering.OrderingSame())) {
|
|
605
|
+
return modulePrefixOrdering_
|
|
606
|
+
} else {
|
|
607
|
+
const symbolsOrdering_ = ff_core_Map.ff_core_Ordering_Order$ff_core_Map_Map(ff_core_Ordering.ff_core_Ordering_Order$ff_core_String_String, ff_compiler_Environment.ff_core_Ordering_Order$ff_compiler_Environment_Scheme).compare_(x_.symbols_, y_.symbols_);
|
|
608
|
+
if((symbolsOrdering_ !== ff_core_Ordering.OrderingSame())) {
|
|
609
|
+
return symbolsOrdering_
|
|
610
|
+
} else {
|
|
611
|
+
const traitsOrdering_ = ff_core_Map.ff_core_Ordering_Order$ff_core_Map_Map(ff_core_Ordering.ff_core_Ordering_Order$ff_core_String_String, ff_compiler_Syntax.ff_core_Ordering_Order$ff_compiler_Syntax_DTrait).compare_(x_.traits_, y_.traits_);
|
|
612
|
+
if((traitsOrdering_ !== ff_core_Ordering.OrderingSame())) {
|
|
613
|
+
return traitsOrdering_
|
|
614
|
+
} else {
|
|
615
|
+
const importsOrdering_ = ff_core_Map.ff_core_Ordering_Order$ff_core_Map_Map(ff_core_Ordering.ff_core_Ordering_Order$ff_core_String_String, ff_compiler_Syntax.ff_core_Ordering_Order$ff_compiler_Syntax_DImport).compare_(x_.imports_, y_.imports_);
|
|
616
|
+
if((importsOrdering_ !== ff_core_Ordering.OrderingSame())) {
|
|
617
|
+
return importsOrdering_
|
|
618
|
+
} else {
|
|
619
|
+
const effectOrdering_ = ff_compiler_Syntax.ff_core_Ordering_Order$ff_compiler_Syntax_Type.compare_(x_.effect_, y_.effect_);
|
|
620
|
+
if((effectOrdering_ !== ff_core_Ordering.OrderingSame())) {
|
|
621
|
+
return effectOrdering_
|
|
622
|
+
} else {
|
|
623
|
+
const selfVariableOrdering_ = ff_core_Option.ff_core_Ordering_Order$ff_core_Option_Option(ff_core_Ordering.ff_core_Ordering_Order$ff_core_String_String).compare_(x_.selfVariable_, y_.selfVariable_);
|
|
624
|
+
if((selfVariableOrdering_ !== ff_core_Ordering.OrderingSame())) {
|
|
625
|
+
return selfVariableOrdering_
|
|
626
|
+
} else {
|
|
627
|
+
return ff_core_Ordering.OrderingSame()
|
|
628
|
+
}
|
|
629
|
+
}
|
|
630
|
+
}
|
|
631
|
+
}
|
|
632
|
+
}
|
|
633
|
+
}
|
|
634
|
+
return
|
|
635
|
+
}
|
|
636
|
+
}
|
|
637
|
+
}
|
|
638
|
+
};
|
|
639
|
+
|
|
640
|
+
export const ff_core_Ordering_Order$ff_compiler_Environment_Scheme = {
|
|
641
|
+
compare_(x_, y_) {
|
|
642
|
+
{
|
|
643
|
+
const x_a = x_;
|
|
644
|
+
const y_a = y_;
|
|
645
|
+
{
|
|
646
|
+
const _guard1 = (x_ === y_);
|
|
647
|
+
if(_guard1) {
|
|
648
|
+
return ff_core_Ordering.OrderingSame()
|
|
649
|
+
return
|
|
650
|
+
}
|
|
651
|
+
}
|
|
652
|
+
{
|
|
653
|
+
const isVariableOrdering_ = ff_core_Ordering.ff_core_Ordering_Order$ff_core_Bool_Bool.compare_(x_.isVariable_, y_.isVariable_);
|
|
654
|
+
if((isVariableOrdering_ !== ff_core_Ordering.OrderingSame())) {
|
|
655
|
+
return isVariableOrdering_
|
|
656
|
+
} else {
|
|
657
|
+
const isMutableOrdering_ = ff_core_Ordering.ff_core_Ordering_Order$ff_core_Bool_Bool.compare_(x_.isMutable_, y_.isMutable_);
|
|
658
|
+
if((isMutableOrdering_ !== ff_core_Ordering.OrderingSame())) {
|
|
659
|
+
return isMutableOrdering_
|
|
660
|
+
} else {
|
|
661
|
+
const isNewtypeOrdering_ = ff_core_Ordering.ff_core_Ordering_Order$ff_core_Bool_Bool.compare_(x_.isNewtype_, y_.isNewtype_);
|
|
662
|
+
if((isNewtypeOrdering_ !== ff_core_Ordering.OrderingSame())) {
|
|
663
|
+
return isNewtypeOrdering_
|
|
664
|
+
} else {
|
|
665
|
+
const isTraitMethodOrdering_ = ff_core_Ordering.ff_core_Ordering_Order$ff_core_Bool_Bool.compare_(x_.isTraitMethod_, y_.isTraitMethod_);
|
|
666
|
+
if((isTraitMethodOrdering_ !== ff_core_Ordering.OrderingSame())) {
|
|
667
|
+
return isTraitMethodOrdering_
|
|
668
|
+
} else {
|
|
669
|
+
const signatureOrdering_ = ff_compiler_Syntax.ff_core_Ordering_Order$ff_compiler_Syntax_Signature.compare_(x_.signature_, y_.signature_);
|
|
670
|
+
if((signatureOrdering_ !== ff_core_Ordering.OrderingSame())) {
|
|
671
|
+
return signatureOrdering_
|
|
672
|
+
} else {
|
|
673
|
+
return ff_core_Ordering.OrderingSame()
|
|
674
|
+
}
|
|
675
|
+
}
|
|
676
|
+
}
|
|
677
|
+
}
|
|
678
|
+
}
|
|
679
|
+
return
|
|
680
|
+
}
|
|
681
|
+
}
|
|
682
|
+
},
|
|
683
|
+
async compare_$(x_, y_, $task) {
|
|
684
|
+
{
|
|
685
|
+
const x_a = x_;
|
|
686
|
+
const y_a = y_;
|
|
687
|
+
{
|
|
688
|
+
const _guard1 = (x_ === y_);
|
|
689
|
+
if(_guard1) {
|
|
690
|
+
return ff_core_Ordering.OrderingSame()
|
|
691
|
+
return
|
|
692
|
+
}
|
|
693
|
+
}
|
|
694
|
+
{
|
|
695
|
+
const isVariableOrdering_ = ff_core_Ordering.ff_core_Ordering_Order$ff_core_Bool_Bool.compare_(x_.isVariable_, y_.isVariable_);
|
|
696
|
+
if((isVariableOrdering_ !== ff_core_Ordering.OrderingSame())) {
|
|
697
|
+
return isVariableOrdering_
|
|
698
|
+
} else {
|
|
699
|
+
const isMutableOrdering_ = ff_core_Ordering.ff_core_Ordering_Order$ff_core_Bool_Bool.compare_(x_.isMutable_, y_.isMutable_);
|
|
700
|
+
if((isMutableOrdering_ !== ff_core_Ordering.OrderingSame())) {
|
|
701
|
+
return isMutableOrdering_
|
|
702
|
+
} else {
|
|
703
|
+
const isNewtypeOrdering_ = ff_core_Ordering.ff_core_Ordering_Order$ff_core_Bool_Bool.compare_(x_.isNewtype_, y_.isNewtype_);
|
|
704
|
+
if((isNewtypeOrdering_ !== ff_core_Ordering.OrderingSame())) {
|
|
705
|
+
return isNewtypeOrdering_
|
|
706
|
+
} else {
|
|
707
|
+
const isTraitMethodOrdering_ = ff_core_Ordering.ff_core_Ordering_Order$ff_core_Bool_Bool.compare_(x_.isTraitMethod_, y_.isTraitMethod_);
|
|
708
|
+
if((isTraitMethodOrdering_ !== ff_core_Ordering.OrderingSame())) {
|
|
709
|
+
return isTraitMethodOrdering_
|
|
710
|
+
} else {
|
|
711
|
+
const signatureOrdering_ = ff_compiler_Syntax.ff_core_Ordering_Order$ff_compiler_Syntax_Signature.compare_(x_.signature_, y_.signature_);
|
|
712
|
+
if((signatureOrdering_ !== ff_core_Ordering.OrderingSame())) {
|
|
713
|
+
return signatureOrdering_
|
|
714
|
+
} else {
|
|
715
|
+
return ff_core_Ordering.OrderingSame()
|
|
716
|
+
}
|
|
717
|
+
}
|
|
718
|
+
}
|
|
719
|
+
}
|
|
720
|
+
}
|
|
721
|
+
return
|
|
722
|
+
}
|
|
723
|
+
}
|
|
724
|
+
}
|
|
725
|
+
};
|
|
726
|
+
|
|
727
|
+
export const ff_core_Ordering_Order$ff_compiler_Environment_Instantiated = {
|
|
728
|
+
compare_(x_, y_) {
|
|
729
|
+
{
|
|
730
|
+
const x_a = x_;
|
|
731
|
+
const y_a = y_;
|
|
732
|
+
{
|
|
733
|
+
const _guard1 = (x_ === y_);
|
|
734
|
+
if(_guard1) {
|
|
735
|
+
return ff_core_Ordering.OrderingSame()
|
|
736
|
+
return
|
|
737
|
+
}
|
|
738
|
+
}
|
|
739
|
+
{
|
|
740
|
+
const typeArgumentsOrdering_ = ff_core_Ordering.ff_core_Ordering_Order$ff_core_List_List(ff_core_Ordering.ff_core_Ordering_Order$ff_core_Pair_Pair(ff_core_Ordering.ff_core_Ordering_Order$ff_core_String_String, ff_compiler_Syntax.ff_core_Ordering_Order$ff_compiler_Syntax_Type)).compare_(x_.typeArguments_, y_.typeArguments_);
|
|
741
|
+
if((typeArgumentsOrdering_ !== ff_core_Ordering.OrderingSame())) {
|
|
742
|
+
return typeArgumentsOrdering_
|
|
743
|
+
} else {
|
|
744
|
+
const schemeOrdering_ = ff_compiler_Environment.ff_core_Ordering_Order$ff_compiler_Environment_Scheme.compare_(x_.scheme_, y_.scheme_);
|
|
745
|
+
if((schemeOrdering_ !== ff_core_Ordering.OrderingSame())) {
|
|
746
|
+
return schemeOrdering_
|
|
747
|
+
} else {
|
|
748
|
+
return ff_core_Ordering.OrderingSame()
|
|
749
|
+
}
|
|
750
|
+
}
|
|
751
|
+
return
|
|
752
|
+
}
|
|
753
|
+
}
|
|
754
|
+
},
|
|
755
|
+
async compare_$(x_, y_, $task) {
|
|
756
|
+
{
|
|
757
|
+
const x_a = x_;
|
|
758
|
+
const y_a = y_;
|
|
759
|
+
{
|
|
760
|
+
const _guard1 = (x_ === y_);
|
|
761
|
+
if(_guard1) {
|
|
762
|
+
return ff_core_Ordering.OrderingSame()
|
|
763
|
+
return
|
|
764
|
+
}
|
|
765
|
+
}
|
|
766
|
+
{
|
|
767
|
+
const typeArgumentsOrdering_ = ff_core_Ordering.ff_core_Ordering_Order$ff_core_List_List(ff_core_Ordering.ff_core_Ordering_Order$ff_core_Pair_Pair(ff_core_Ordering.ff_core_Ordering_Order$ff_core_String_String, ff_compiler_Syntax.ff_core_Ordering_Order$ff_compiler_Syntax_Type)).compare_(x_.typeArguments_, y_.typeArguments_);
|
|
768
|
+
if((typeArgumentsOrdering_ !== ff_core_Ordering.OrderingSame())) {
|
|
769
|
+
return typeArgumentsOrdering_
|
|
770
|
+
} else {
|
|
771
|
+
const schemeOrdering_ = ff_compiler_Environment.ff_core_Ordering_Order$ff_compiler_Environment_Scheme.compare_(x_.scheme_, y_.scheme_);
|
|
772
|
+
if((schemeOrdering_ !== ff_core_Ordering.OrderingSame())) {
|
|
773
|
+
return schemeOrdering_
|
|
774
|
+
} else {
|
|
775
|
+
return ff_core_Ordering.OrderingSame()
|
|
776
|
+
}
|
|
777
|
+
}
|
|
778
|
+
return
|
|
779
|
+
}
|
|
780
|
+
}
|
|
781
|
+
}
|
|
782
|
+
};
|
|
783
|
+
|
|
784
|
+
export const ff_core_Serializable_Serializable$ff_compiler_Environment_Environment = {
|
|
785
|
+
serializeUsing_(serialization_, value_) {
|
|
786
|
+
{
|
|
787
|
+
const serialization_a = serialization_;
|
|
788
|
+
const value_a = value_;
|
|
789
|
+
{
|
|
790
|
+
const v_ = value_a;
|
|
791
|
+
serialization_.checksum_ = ff_core_Int.Int_bitOr(((31 * serialization_.checksum_) + 35), 0);
|
|
792
|
+
ff_core_Buffer.Buffer_setUint8(serialization_.buffer_, serialization_.offset_, 0);
|
|
793
|
+
serialization_.offset_ += 1;
|
|
794
|
+
ff_core_Serializable.ff_core_Serializable_Serializable$ff_core_String_String.serializeUsing_(serialization_, v_.modulePrefix_);
|
|
795
|
+
ff_core_Serializable.ff_core_Serializable_Serializable$ff_core_Map_Map(ff_core_Serializable.ff_core_Serializable_Serializable$ff_core_String_String, ff_core_Ordering.ff_core_Ordering_Order$ff_core_String_String, ff_compiler_Environment.ff_core_Serializable_Serializable$ff_compiler_Environment_Scheme).serializeUsing_(serialization_, v_.symbols_);
|
|
796
|
+
ff_core_Serializable.ff_core_Serializable_Serializable$ff_core_Map_Map(ff_core_Serializable.ff_core_Serializable_Serializable$ff_core_String_String, ff_core_Ordering.ff_core_Ordering_Order$ff_core_String_String, ff_compiler_Syntax.ff_core_Serializable_Serializable$ff_compiler_Syntax_DTrait).serializeUsing_(serialization_, v_.traits_);
|
|
797
|
+
ff_core_Serializable.ff_core_Serializable_Serializable$ff_core_Map_Map(ff_core_Serializable.ff_core_Serializable_Serializable$ff_core_String_String, ff_core_Ordering.ff_core_Ordering_Order$ff_core_String_String, ff_compiler_Syntax.ff_core_Serializable_Serializable$ff_compiler_Syntax_DImport).serializeUsing_(serialization_, v_.imports_);
|
|
798
|
+
ff_compiler_Syntax.ff_core_Serializable_Serializable$ff_compiler_Syntax_Type.serializeUsing_(serialization_, v_.effect_);
|
|
799
|
+
ff_core_Option.ff_core_Serializable_Serializable$ff_core_Option_Option(ff_core_Serializable.ff_core_Serializable_Serializable$ff_core_String_String).serializeUsing_(serialization_, v_.selfVariable_)
|
|
800
|
+
return
|
|
801
|
+
}
|
|
802
|
+
}
|
|
803
|
+
},
|
|
804
|
+
deserializeUsing_(serialization_) {
|
|
805
|
+
const variantIndex_ = ff_core_Buffer.Buffer_grabUint8(serialization_.buffer_, serialization_.offset_);
|
|
806
|
+
serialization_.offset_ += 1;
|
|
807
|
+
{
|
|
808
|
+
const _1 = variantIndex_;
|
|
809
|
+
{
|
|
810
|
+
if(_1 == 0) {
|
|
811
|
+
serialization_.checksum_ = ff_core_Int.Int_bitOr(((31 * serialization_.checksum_) + 35), 0);
|
|
812
|
+
return ff_compiler_Environment.Environment(ff_core_Serializable.ff_core_Serializable_Serializable$ff_core_String_String.deserializeUsing_(serialization_), ff_core_Serializable.ff_core_Serializable_Serializable$ff_core_Map_Map(ff_core_Serializable.ff_core_Serializable_Serializable$ff_core_String_String, ff_core_Ordering.ff_core_Ordering_Order$ff_core_String_String, ff_compiler_Environment.ff_core_Serializable_Serializable$ff_compiler_Environment_Scheme).deserializeUsing_(serialization_), ff_core_Serializable.ff_core_Serializable_Serializable$ff_core_Map_Map(ff_core_Serializable.ff_core_Serializable_Serializable$ff_core_String_String, ff_core_Ordering.ff_core_Ordering_Order$ff_core_String_String, ff_compiler_Syntax.ff_core_Serializable_Serializable$ff_compiler_Syntax_DTrait).deserializeUsing_(serialization_), ff_core_Serializable.ff_core_Serializable_Serializable$ff_core_Map_Map(ff_core_Serializable.ff_core_Serializable_Serializable$ff_core_String_String, ff_core_Ordering.ff_core_Ordering_Order$ff_core_String_String, ff_compiler_Syntax.ff_core_Serializable_Serializable$ff_compiler_Syntax_DImport).deserializeUsing_(serialization_), ff_compiler_Syntax.ff_core_Serializable_Serializable$ff_compiler_Syntax_Type.deserializeUsing_(serialization_), ff_core_Option.ff_core_Serializable_Serializable$ff_core_Option_Option(ff_core_Serializable.ff_core_Serializable_Serializable$ff_core_String_String).deserializeUsing_(serialization_))
|
|
813
|
+
return
|
|
814
|
+
}
|
|
815
|
+
}
|
|
816
|
+
{
|
|
817
|
+
throw Object.assign(new Error(), {ffException: ff_core_Any.toAny_(ff_core_Serializable.DeserializationChecksumException(), ff_core_Serializable.ff_core_Any_HasAnyTag$ff_core_Serializable_DeserializationChecksumException)})
|
|
818
|
+
return
|
|
819
|
+
}
|
|
820
|
+
}
|
|
821
|
+
},
|
|
822
|
+
async serializeUsing_$(serialization_, value_, $task) {
|
|
823
|
+
{
|
|
824
|
+
const serialization_a = serialization_;
|
|
825
|
+
const value_a = value_;
|
|
826
|
+
{
|
|
827
|
+
const v_ = value_a;
|
|
828
|
+
serialization_.checksum_ = ff_core_Int.Int_bitOr(((31 * serialization_.checksum_) + 35), 0);
|
|
829
|
+
ff_core_Buffer.Buffer_setUint8(serialization_.buffer_, serialization_.offset_, 0);
|
|
830
|
+
serialization_.offset_ += 1;
|
|
831
|
+
ff_core_Serializable.ff_core_Serializable_Serializable$ff_core_String_String.serializeUsing_(serialization_, v_.modulePrefix_);
|
|
832
|
+
ff_core_Serializable.ff_core_Serializable_Serializable$ff_core_Map_Map(ff_core_Serializable.ff_core_Serializable_Serializable$ff_core_String_String, ff_core_Ordering.ff_core_Ordering_Order$ff_core_String_String, ff_compiler_Environment.ff_core_Serializable_Serializable$ff_compiler_Environment_Scheme).serializeUsing_(serialization_, v_.symbols_);
|
|
833
|
+
ff_core_Serializable.ff_core_Serializable_Serializable$ff_core_Map_Map(ff_core_Serializable.ff_core_Serializable_Serializable$ff_core_String_String, ff_core_Ordering.ff_core_Ordering_Order$ff_core_String_String, ff_compiler_Syntax.ff_core_Serializable_Serializable$ff_compiler_Syntax_DTrait).serializeUsing_(serialization_, v_.traits_);
|
|
834
|
+
ff_core_Serializable.ff_core_Serializable_Serializable$ff_core_Map_Map(ff_core_Serializable.ff_core_Serializable_Serializable$ff_core_String_String, ff_core_Ordering.ff_core_Ordering_Order$ff_core_String_String, ff_compiler_Syntax.ff_core_Serializable_Serializable$ff_compiler_Syntax_DImport).serializeUsing_(serialization_, v_.imports_);
|
|
835
|
+
ff_compiler_Syntax.ff_core_Serializable_Serializable$ff_compiler_Syntax_Type.serializeUsing_(serialization_, v_.effect_);
|
|
836
|
+
ff_core_Option.ff_core_Serializable_Serializable$ff_core_Option_Option(ff_core_Serializable.ff_core_Serializable_Serializable$ff_core_String_String).serializeUsing_(serialization_, v_.selfVariable_)
|
|
837
|
+
return
|
|
838
|
+
}
|
|
839
|
+
}
|
|
840
|
+
},
|
|
841
|
+
async deserializeUsing_$(serialization_, $task) {
|
|
842
|
+
const variantIndex_ = ff_core_Buffer.Buffer_grabUint8(serialization_.buffer_, serialization_.offset_);
|
|
843
|
+
serialization_.offset_ += 1;
|
|
844
|
+
{
|
|
845
|
+
const _1 = variantIndex_;
|
|
846
|
+
{
|
|
847
|
+
if(_1 == 0) {
|
|
848
|
+
serialization_.checksum_ = ff_core_Int.Int_bitOr(((31 * serialization_.checksum_) + 35), 0);
|
|
849
|
+
return ff_compiler_Environment.Environment(ff_core_Serializable.ff_core_Serializable_Serializable$ff_core_String_String.deserializeUsing_(serialization_), ff_core_Serializable.ff_core_Serializable_Serializable$ff_core_Map_Map(ff_core_Serializable.ff_core_Serializable_Serializable$ff_core_String_String, ff_core_Ordering.ff_core_Ordering_Order$ff_core_String_String, ff_compiler_Environment.ff_core_Serializable_Serializable$ff_compiler_Environment_Scheme).deserializeUsing_(serialization_), ff_core_Serializable.ff_core_Serializable_Serializable$ff_core_Map_Map(ff_core_Serializable.ff_core_Serializable_Serializable$ff_core_String_String, ff_core_Ordering.ff_core_Ordering_Order$ff_core_String_String, ff_compiler_Syntax.ff_core_Serializable_Serializable$ff_compiler_Syntax_DTrait).deserializeUsing_(serialization_), ff_core_Serializable.ff_core_Serializable_Serializable$ff_core_Map_Map(ff_core_Serializable.ff_core_Serializable_Serializable$ff_core_String_String, ff_core_Ordering.ff_core_Ordering_Order$ff_core_String_String, ff_compiler_Syntax.ff_core_Serializable_Serializable$ff_compiler_Syntax_DImport).deserializeUsing_(serialization_), ff_compiler_Syntax.ff_core_Serializable_Serializable$ff_compiler_Syntax_Type.deserializeUsing_(serialization_), ff_core_Option.ff_core_Serializable_Serializable$ff_core_Option_Option(ff_core_Serializable.ff_core_Serializable_Serializable$ff_core_String_String).deserializeUsing_(serialization_))
|
|
850
|
+
return
|
|
851
|
+
}
|
|
852
|
+
}
|
|
853
|
+
{
|
|
854
|
+
throw Object.assign(new Error(), {ffException: ff_core_Any.toAny_(ff_core_Serializable.DeserializationChecksumException(), ff_core_Serializable.ff_core_Any_HasAnyTag$ff_core_Serializable_DeserializationChecksumException)})
|
|
855
|
+
return
|
|
856
|
+
}
|
|
857
|
+
}
|
|
858
|
+
}
|
|
859
|
+
};
|
|
860
|
+
|
|
861
|
+
export const ff_core_Serializable_Serializable$ff_compiler_Environment_Scheme = {
|
|
862
|
+
serializeUsing_(serialization_, value_) {
|
|
863
|
+
{
|
|
864
|
+
const serialization_a = serialization_;
|
|
865
|
+
const value_a = value_;
|
|
866
|
+
{
|
|
867
|
+
const v_ = value_a;
|
|
868
|
+
serialization_.checksum_ = ff_core_Int.Int_bitOr(((31 * serialization_.checksum_) + 30), 0);
|
|
869
|
+
ff_core_Buffer.Buffer_setUint8(serialization_.buffer_, serialization_.offset_, 0);
|
|
870
|
+
serialization_.offset_ += 1;
|
|
871
|
+
ff_core_Serializable.ff_core_Serializable_Serializable$ff_core_Bool_Bool.serializeUsing_(serialization_, v_.isVariable_);
|
|
872
|
+
ff_core_Serializable.ff_core_Serializable_Serializable$ff_core_Bool_Bool.serializeUsing_(serialization_, v_.isMutable_);
|
|
873
|
+
ff_core_Serializable.ff_core_Serializable_Serializable$ff_core_Bool_Bool.serializeUsing_(serialization_, v_.isNewtype_);
|
|
874
|
+
ff_core_Serializable.ff_core_Serializable_Serializable$ff_core_Bool_Bool.serializeUsing_(serialization_, v_.isTraitMethod_);
|
|
875
|
+
ff_compiler_Syntax.ff_core_Serializable_Serializable$ff_compiler_Syntax_Signature.serializeUsing_(serialization_, v_.signature_)
|
|
876
|
+
return
|
|
877
|
+
}
|
|
878
|
+
}
|
|
879
|
+
},
|
|
880
|
+
deserializeUsing_(serialization_) {
|
|
881
|
+
const variantIndex_ = ff_core_Buffer.Buffer_grabUint8(serialization_.buffer_, serialization_.offset_);
|
|
882
|
+
serialization_.offset_ += 1;
|
|
883
|
+
{
|
|
884
|
+
const _1 = variantIndex_;
|
|
885
|
+
{
|
|
886
|
+
if(_1 == 0) {
|
|
887
|
+
serialization_.checksum_ = ff_core_Int.Int_bitOr(((31 * serialization_.checksum_) + 30), 0);
|
|
888
|
+
return ff_compiler_Environment.Scheme(ff_core_Serializable.ff_core_Serializable_Serializable$ff_core_Bool_Bool.deserializeUsing_(serialization_), ff_core_Serializable.ff_core_Serializable_Serializable$ff_core_Bool_Bool.deserializeUsing_(serialization_), ff_core_Serializable.ff_core_Serializable_Serializable$ff_core_Bool_Bool.deserializeUsing_(serialization_), ff_core_Serializable.ff_core_Serializable_Serializable$ff_core_Bool_Bool.deserializeUsing_(serialization_), ff_compiler_Syntax.ff_core_Serializable_Serializable$ff_compiler_Syntax_Signature.deserializeUsing_(serialization_))
|
|
889
|
+
return
|
|
890
|
+
}
|
|
891
|
+
}
|
|
892
|
+
{
|
|
893
|
+
throw Object.assign(new Error(), {ffException: ff_core_Any.toAny_(ff_core_Serializable.DeserializationChecksumException(), ff_core_Serializable.ff_core_Any_HasAnyTag$ff_core_Serializable_DeserializationChecksumException)})
|
|
894
|
+
return
|
|
895
|
+
}
|
|
896
|
+
}
|
|
897
|
+
},
|
|
898
|
+
async serializeUsing_$(serialization_, value_, $task) {
|
|
899
|
+
{
|
|
900
|
+
const serialization_a = serialization_;
|
|
901
|
+
const value_a = value_;
|
|
902
|
+
{
|
|
903
|
+
const v_ = value_a;
|
|
904
|
+
serialization_.checksum_ = ff_core_Int.Int_bitOr(((31 * serialization_.checksum_) + 30), 0);
|
|
905
|
+
ff_core_Buffer.Buffer_setUint8(serialization_.buffer_, serialization_.offset_, 0);
|
|
906
|
+
serialization_.offset_ += 1;
|
|
907
|
+
ff_core_Serializable.ff_core_Serializable_Serializable$ff_core_Bool_Bool.serializeUsing_(serialization_, v_.isVariable_);
|
|
908
|
+
ff_core_Serializable.ff_core_Serializable_Serializable$ff_core_Bool_Bool.serializeUsing_(serialization_, v_.isMutable_);
|
|
909
|
+
ff_core_Serializable.ff_core_Serializable_Serializable$ff_core_Bool_Bool.serializeUsing_(serialization_, v_.isNewtype_);
|
|
910
|
+
ff_core_Serializable.ff_core_Serializable_Serializable$ff_core_Bool_Bool.serializeUsing_(serialization_, v_.isTraitMethod_);
|
|
911
|
+
ff_compiler_Syntax.ff_core_Serializable_Serializable$ff_compiler_Syntax_Signature.serializeUsing_(serialization_, v_.signature_)
|
|
912
|
+
return
|
|
913
|
+
}
|
|
914
|
+
}
|
|
915
|
+
},
|
|
916
|
+
async deserializeUsing_$(serialization_, $task) {
|
|
917
|
+
const variantIndex_ = ff_core_Buffer.Buffer_grabUint8(serialization_.buffer_, serialization_.offset_);
|
|
918
|
+
serialization_.offset_ += 1;
|
|
919
|
+
{
|
|
920
|
+
const _1 = variantIndex_;
|
|
921
|
+
{
|
|
922
|
+
if(_1 == 0) {
|
|
923
|
+
serialization_.checksum_ = ff_core_Int.Int_bitOr(((31 * serialization_.checksum_) + 30), 0);
|
|
924
|
+
return ff_compiler_Environment.Scheme(ff_core_Serializable.ff_core_Serializable_Serializable$ff_core_Bool_Bool.deserializeUsing_(serialization_), ff_core_Serializable.ff_core_Serializable_Serializable$ff_core_Bool_Bool.deserializeUsing_(serialization_), ff_core_Serializable.ff_core_Serializable_Serializable$ff_core_Bool_Bool.deserializeUsing_(serialization_), ff_core_Serializable.ff_core_Serializable_Serializable$ff_core_Bool_Bool.deserializeUsing_(serialization_), ff_compiler_Syntax.ff_core_Serializable_Serializable$ff_compiler_Syntax_Signature.deserializeUsing_(serialization_))
|
|
925
|
+
return
|
|
926
|
+
}
|
|
927
|
+
}
|
|
928
|
+
{
|
|
929
|
+
throw Object.assign(new Error(), {ffException: ff_core_Any.toAny_(ff_core_Serializable.DeserializationChecksumException(), ff_core_Serializable.ff_core_Any_HasAnyTag$ff_core_Serializable_DeserializationChecksumException)})
|
|
930
|
+
return
|
|
931
|
+
}
|
|
932
|
+
}
|
|
933
|
+
}
|
|
934
|
+
};
|
|
935
|
+
|
|
936
|
+
export const ff_core_Serializable_Serializable$ff_compiler_Environment_Instantiated = {
|
|
937
|
+
serializeUsing_(serialization_, value_) {
|
|
938
|
+
{
|
|
939
|
+
const serialization_a = serialization_;
|
|
940
|
+
const value_a = value_;
|
|
941
|
+
{
|
|
942
|
+
const v_ = value_a;
|
|
943
|
+
serialization_.checksum_ = ff_core_Int.Int_bitOr(((31 * serialization_.checksum_) + 36), 0);
|
|
944
|
+
ff_core_Buffer.Buffer_setUint8(serialization_.buffer_, serialization_.offset_, 0);
|
|
945
|
+
serialization_.offset_ += 1;
|
|
946
|
+
ff_core_Serializable.ff_core_Serializable_Serializable$ff_core_List_List(ff_core_Pair.ff_core_Serializable_Serializable$ff_core_Pair_Pair(ff_core_Serializable.ff_core_Serializable_Serializable$ff_core_String_String, ff_compiler_Syntax.ff_core_Serializable_Serializable$ff_compiler_Syntax_Type)).serializeUsing_(serialization_, v_.typeArguments_);
|
|
947
|
+
ff_compiler_Environment.ff_core_Serializable_Serializable$ff_compiler_Environment_Scheme.serializeUsing_(serialization_, v_.scheme_)
|
|
948
|
+
return
|
|
949
|
+
}
|
|
950
|
+
}
|
|
951
|
+
},
|
|
952
|
+
deserializeUsing_(serialization_) {
|
|
953
|
+
const variantIndex_ = ff_core_Buffer.Buffer_grabUint8(serialization_.buffer_, serialization_.offset_);
|
|
954
|
+
serialization_.offset_ += 1;
|
|
955
|
+
{
|
|
956
|
+
const _1 = variantIndex_;
|
|
957
|
+
{
|
|
958
|
+
if(_1 == 0) {
|
|
959
|
+
serialization_.checksum_ = ff_core_Int.Int_bitOr(((31 * serialization_.checksum_) + 36), 0);
|
|
960
|
+
return ff_compiler_Environment.Instantiated(ff_core_Serializable.ff_core_Serializable_Serializable$ff_core_List_List(ff_core_Pair.ff_core_Serializable_Serializable$ff_core_Pair_Pair(ff_core_Serializable.ff_core_Serializable_Serializable$ff_core_String_String, ff_compiler_Syntax.ff_core_Serializable_Serializable$ff_compiler_Syntax_Type)).deserializeUsing_(serialization_), ff_compiler_Environment.ff_core_Serializable_Serializable$ff_compiler_Environment_Scheme.deserializeUsing_(serialization_))
|
|
961
|
+
return
|
|
962
|
+
}
|
|
963
|
+
}
|
|
964
|
+
{
|
|
965
|
+
throw Object.assign(new Error(), {ffException: ff_core_Any.toAny_(ff_core_Serializable.DeserializationChecksumException(), ff_core_Serializable.ff_core_Any_HasAnyTag$ff_core_Serializable_DeserializationChecksumException)})
|
|
966
|
+
return
|
|
967
|
+
}
|
|
968
|
+
}
|
|
969
|
+
},
|
|
970
|
+
async serializeUsing_$(serialization_, value_, $task) {
|
|
971
|
+
{
|
|
972
|
+
const serialization_a = serialization_;
|
|
973
|
+
const value_a = value_;
|
|
974
|
+
{
|
|
975
|
+
const v_ = value_a;
|
|
976
|
+
serialization_.checksum_ = ff_core_Int.Int_bitOr(((31 * serialization_.checksum_) + 36), 0);
|
|
977
|
+
ff_core_Buffer.Buffer_setUint8(serialization_.buffer_, serialization_.offset_, 0);
|
|
978
|
+
serialization_.offset_ += 1;
|
|
979
|
+
ff_core_Serializable.ff_core_Serializable_Serializable$ff_core_List_List(ff_core_Pair.ff_core_Serializable_Serializable$ff_core_Pair_Pair(ff_core_Serializable.ff_core_Serializable_Serializable$ff_core_String_String, ff_compiler_Syntax.ff_core_Serializable_Serializable$ff_compiler_Syntax_Type)).serializeUsing_(serialization_, v_.typeArguments_);
|
|
980
|
+
ff_compiler_Environment.ff_core_Serializable_Serializable$ff_compiler_Environment_Scheme.serializeUsing_(serialization_, v_.scheme_)
|
|
981
|
+
return
|
|
982
|
+
}
|
|
983
|
+
}
|
|
984
|
+
},
|
|
985
|
+
async deserializeUsing_$(serialization_, $task) {
|
|
986
|
+
const variantIndex_ = ff_core_Buffer.Buffer_grabUint8(serialization_.buffer_, serialization_.offset_);
|
|
987
|
+
serialization_.offset_ += 1;
|
|
988
|
+
{
|
|
989
|
+
const _1 = variantIndex_;
|
|
990
|
+
{
|
|
991
|
+
if(_1 == 0) {
|
|
992
|
+
serialization_.checksum_ = ff_core_Int.Int_bitOr(((31 * serialization_.checksum_) + 36), 0);
|
|
993
|
+
return ff_compiler_Environment.Instantiated(ff_core_Serializable.ff_core_Serializable_Serializable$ff_core_List_List(ff_core_Pair.ff_core_Serializable_Serializable$ff_core_Pair_Pair(ff_core_Serializable.ff_core_Serializable_Serializable$ff_core_String_String, ff_compiler_Syntax.ff_core_Serializable_Serializable$ff_compiler_Syntax_Type)).deserializeUsing_(serialization_), ff_compiler_Environment.ff_core_Serializable_Serializable$ff_compiler_Environment_Scheme.deserializeUsing_(serialization_))
|
|
994
|
+
return
|
|
995
|
+
}
|
|
996
|
+
}
|
|
997
|
+
{
|
|
998
|
+
throw Object.assign(new Error(), {ffException: ff_core_Any.toAny_(ff_core_Serializable.DeserializationChecksumException(), ff_core_Serializable.ff_core_Any_HasAnyTag$ff_core_Serializable_DeserializationChecksumException)})
|
|
999
|
+
return
|
|
1000
|
+
}
|
|
1001
|
+
}
|
|
1002
|
+
}
|
|
1003
|
+
};
|
|
1004
|
+
|
|
1005
|
+
|