@glutinum/cli 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +3 -0
- package/cli.js +2 -0
- package/dist/Glutinum.Converter/FsharpAST.js +371 -0
- package/dist/Glutinum.Converter/FsharpAST.js.map +1 -0
- package/dist/Glutinum.Converter/Generate.js +28 -0
- package/dist/Glutinum.Converter/Generate.js.map +1 -0
- package/dist/Glutinum.Converter/GlueAST.js +403 -0
- package/dist/Glutinum.Converter/GlueAST.js.map +1 -0
- package/dist/Glutinum.Converter/Log.js +24 -0
- package/dist/Glutinum.Converter/Log.js.map +1 -0
- package/dist/Glutinum.Converter/Printer.js +452 -0
- package/dist/Glutinum.Converter/Printer.js.map +1 -0
- package/dist/Glutinum.Converter/Read.js +10 -0
- package/dist/Glutinum.Converter/Read.js.map +1 -0
- package/dist/Glutinum.Converter/Reader/ClassDeclaration.js +28 -0
- package/dist/Glutinum.Converter/Reader/ClassDeclaration.js.map +1 -0
- package/dist/Glutinum.Converter/Reader/EnumDeclaration.js +72 -0
- package/dist/Glutinum.Converter/Reader/EnumDeclaration.js.map +1 -0
- package/dist/Glutinum.Converter/Reader/FunctionDeclaration.js +11 -0
- package/dist/Glutinum.Converter/Reader/FunctionDeclaration.js.map +1 -0
- package/dist/Glutinum.Converter/Reader/IndexedAccessType.js +9 -0
- package/dist/Glutinum.Converter/Reader/IndexedAccessType.js.map +1 -0
- package/dist/Glutinum.Converter/Reader/InterfaceDeclaration.js +10 -0
- package/dist/Glutinum.Converter/Reader/InterfaceDeclaration.js.map +1 -0
- package/dist/Glutinum.Converter/Reader/ModuleDeclaration.js +23 -0
- package/dist/Glutinum.Converter/Reader/ModuleDeclaration.js.map +1 -0
- package/dist/Glutinum.Converter/Reader/NamedDeclaration.js +34 -0
- package/dist/Glutinum.Converter/Reader/NamedDeclaration.js.map +1 -0
- package/dist/Glutinum.Converter/Reader/Node.js +28 -0
- package/dist/Glutinum.Converter/Reader/Node.js.map +1 -0
- package/dist/Glutinum.Converter/Reader/Parameters.js +12 -0
- package/dist/Glutinum.Converter/Reader/Parameters.js.map +1 -0
- package/dist/Glutinum.Converter/Reader/TypeAliasDeclaration.js +28 -0
- package/dist/Glutinum.Converter/Reader/TypeAliasDeclaration.js.map +1 -0
- package/dist/Glutinum.Converter/Reader/TypeNode.js +126 -0
- package/dist/Glutinum.Converter/Reader/TypeNode.js.map +1 -0
- package/dist/Glutinum.Converter/Reader/TypeOperatorNode.js +34 -0
- package/dist/Glutinum.Converter/Reader/TypeOperatorNode.js.map +1 -0
- package/dist/Glutinum.Converter/Reader/TypeParameters.js +14 -0
- package/dist/Glutinum.Converter/Reader/TypeParameters.js.map +1 -0
- package/dist/Glutinum.Converter/Reader/TypeScriptReader.js +95 -0
- package/dist/Glutinum.Converter/Reader/TypeScriptReader.js.map +1 -0
- package/dist/Glutinum.Converter/Reader/Types.js +16 -0
- package/dist/Glutinum.Converter/Reader/Types.js.map +1 -0
- package/dist/Glutinum.Converter/Reader/UnionTypeNode.js +89 -0
- package/dist/Glutinum.Converter/Reader/UnionTypeNode.js.map +1 -0
- package/dist/Glutinum.Converter/Reader/Utils.js +79 -0
- package/dist/Glutinum.Converter/Reader/Utils.js.map +1 -0
- package/dist/Glutinum.Converter/Reader/VariableStatement.js +19 -0
- package/dist/Glutinum.Converter/Reader/VariableStatement.js.map +1 -0
- package/dist/Glutinum.Converter/Transform.js +538 -0
- package/dist/Glutinum.Converter/Transform.js.map +1 -0
- package/dist/Glutinum.Converter/TypeScript.js +12 -0
- package/dist/Glutinum.Converter/TypeScript.js.map +1 -0
- package/dist/Glutinum.Converter/Utils/Keywords.js +9 -0
- package/dist/Glutinum.Converter/Utils/Keywords.js.map +1 -0
- package/dist/Glutinum.Converter/Utils/Naming.js +25 -0
- package/dist/Glutinum.Converter/Utils/Naming.js.map +1 -0
- package/dist/Glutinum.Converter/Utils/String.js +23 -0
- package/dist/Glutinum.Converter/Utils/String.js.map +1 -0
- package/dist/Program.js +12 -0
- package/dist/Program.js.map +1 -0
- package/dist/fable_modules/fable-library.4.5.0/Array.d.ts +120 -0
- package/dist/fable_modules/fable-library.4.5.0/Array.js +1204 -0
- package/dist/fable_modules/fable-library.4.5.0/Async.d.ts +32 -0
- package/dist/fable_modules/fable-library.4.5.0/Async.js +158 -0
- package/dist/fable_modules/fable-library.4.5.0/AsyncBuilder.d.ts +59 -0
- package/dist/fable_modules/fable-library.4.5.0/AsyncBuilder.js +183 -0
- package/dist/fable_modules/fable-library.4.5.0/BigInt.d.ts +115 -0
- package/dist/fable_modules/fable-library.4.5.0/BigInt.js +282 -0
- package/dist/fable_modules/fable-library.4.5.0/BitConverter.d.ts +27 -0
- package/dist/fable_modules/fable-library.4.5.0/BitConverter.js +138 -0
- package/dist/fable_modules/fable-library.4.5.0/Boolean.d.ts +3 -0
- package/dist/fable_modules/fable-library.4.5.0/Boolean.js +21 -0
- package/dist/fable_modules/fable-library.4.5.0/CHANGELOG.md +11 -0
- package/dist/fable_modules/fable-library.4.5.0/Char.d.ts +65 -0
- package/dist/fable_modules/fable-library.4.5.0/Char.js +169 -0
- package/dist/fable_modules/fable-library.4.5.0/Choice.d.ts +138 -0
- package/dist/fable_modules/fable-library.4.5.0/Choice.js +227 -0
- package/dist/fable_modules/fable-library.4.5.0/Date.d.ts +70 -0
- package/dist/fable_modules/fable-library.4.5.0/Date.js +451 -0
- package/dist/fable_modules/fable-library.4.5.0/DateOffset.d.ts +63 -0
- package/dist/fable_modules/fable-library.4.5.0/DateOffset.js +268 -0
- package/dist/fable_modules/fable-library.4.5.0/DateOnly.d.ts +18 -0
- package/dist/fable_modules/fable-library.4.5.0/DateOnly.js +124 -0
- package/dist/fable_modules/fable-library.4.5.0/Decimal.d.ts +45 -0
- package/dist/fable_modules/fable-library.4.5.0/Decimal.js +212 -0
- package/dist/fable_modules/fable-library.4.5.0/Double.d.ts +11 -0
- package/dist/fable_modules/fable-library.4.5.0/Double.js +46 -0
- package/dist/fable_modules/fable-library.4.5.0/Encoding.d.ts +12 -0
- package/dist/fable_modules/fable-library.4.5.0/Encoding.js +173 -0
- package/dist/fable_modules/fable-library.4.5.0/Event.d.ts +31 -0
- package/dist/fable_modules/fable-library.4.5.0/Event.js +93 -0
- package/dist/fable_modules/fable-library.4.5.0/FSharp.Collections.d.ts +7 -0
- package/dist/fable_modules/fable-library.4.5.0/FSharp.Collections.js +27 -0
- package/dist/fable_modules/fable-library.4.5.0/FSharp.Core.d.ts +17 -0
- package/dist/fable_modules/fable-library.4.5.0/FSharp.Core.js +69 -0
- package/dist/fable_modules/fable-library.4.5.0/Global.d.ts +24 -0
- package/dist/fable_modules/fable-library.4.5.0/Global.js +8 -0
- package/dist/fable_modules/fable-library.4.5.0/Guid.d.ts +10 -0
- package/dist/fable_modules/fable-library.4.5.0/Guid.js +142 -0
- package/dist/fable_modules/fable-library.4.5.0/Int32.d.ts +28 -0
- package/dist/fable_modules/fable-library.4.5.0/Int32.js +135 -0
- package/dist/fable_modules/fable-library.4.5.0/List.d.ts +143 -0
- package/dist/fable_modules/fable-library.4.5.0/List.js +1273 -0
- package/dist/fable_modules/fable-library.4.5.0/Long.d.ts +3 -0
- package/dist/fable_modules/fable-library.4.5.0/Long.js +46 -0
- package/dist/fable_modules/fable-library.4.5.0/MailboxProcessor.d.ts +25 -0
- package/dist/fable_modules/fable-library.4.5.0/MailboxProcessor.js +93 -0
- package/dist/fable_modules/fable-library.4.5.0/Map.d.ts +178 -0
- package/dist/fable_modules/fable-library.4.5.0/Map.js +1396 -0
- package/dist/fable_modules/fable-library.4.5.0/MapUtil.d.ts +10 -0
- package/dist/fable_modules/fable-library.4.5.0/MapUtil.js +112 -0
- package/dist/fable_modules/fable-library.4.5.0/MutableMap.d.ts +52 -0
- package/dist/fable_modules/fable-library.4.5.0/MutableMap.js +326 -0
- package/dist/fable_modules/fable-library.4.5.0/MutableSet.d.ts +39 -0
- package/dist/fable_modules/fable-library.4.5.0/MutableSet.js +232 -0
- package/dist/fable_modules/fable-library.4.5.0/Native.d.ts +2 -0
- package/dist/fable_modules/fable-library.4.5.0/Native.js +8 -0
- package/dist/fable_modules/fable-library.4.5.0/Numeric.d.ts +19 -0
- package/dist/fable_modules/fable-library.4.5.0/Numeric.js +71 -0
- package/dist/fable_modules/fable-library.4.5.0/Observable.d.ts +32 -0
- package/dist/fable_modules/fable-library.4.5.0/Observable.js +113 -0
- package/dist/fable_modules/fable-library.4.5.0/Option.d.ts +28 -0
- package/dist/fable_modules/fable-library.4.5.0/Option.js +96 -0
- package/dist/fable_modules/fable-library.4.5.0/README.md +3 -0
- package/dist/fable_modules/fable-library.4.5.0/Random.d.ts +37 -0
- package/dist/fable_modules/fable-library.4.5.0/Random.js +170 -0
- package/dist/fable_modules/fable-library.4.5.0/Range.d.ts +12 -0
- package/dist/fable_modules/fable-library.4.5.0/Range.js +45 -0
- package/dist/fable_modules/fable-library.4.5.0/Reflection.d.ts +119 -0
- package/dist/fable_modules/fable-library.4.5.0/Reflection.js +461 -0
- package/dist/fable_modules/fable-library.4.5.0/RegExp.d.ts +10 -0
- package/dist/fable_modules/fable-library.4.5.0/RegExp.js +132 -0
- package/dist/fable_modules/fable-library.4.5.0/Seq.d.ts +165 -0
- package/dist/fable_modules/fable-library.4.5.0/Seq.js +1379 -0
- package/dist/fable_modules/fable-library.4.5.0/Seq2.d.ts +18 -0
- package/dist/fable_modules/fable-library.4.5.0/Seq2.js +111 -0
- package/dist/fable_modules/fable-library.4.5.0/Set.d.ts +190 -0
- package/dist/fable_modules/fable-library.4.5.0/Set.js +1789 -0
- package/dist/fable_modules/fable-library.4.5.0/String.d.ts +49 -0
- package/dist/fable_modules/fable-library.4.5.0/String.js +540 -0
- package/dist/fable_modules/fable-library.4.5.0/System.Collections.Generic.d.ts +71 -0
- package/dist/fable_modules/fable-library.4.5.0/System.Collections.Generic.js +307 -0
- package/dist/fable_modules/fable-library.4.5.0/System.Text.d.ts +30 -0
- package/dist/fable_modules/fable-library.4.5.0/System.Text.js +110 -0
- package/dist/fable_modules/fable-library.4.5.0/SystemException.d.ts +5 -0
- package/dist/fable_modules/fable-library.4.5.0/SystemException.js +5 -0
- package/dist/fable_modules/fable-library.4.5.0/TimeOnly.d.ts +15 -0
- package/dist/fable_modules/fable-library.4.5.0/TimeOnly.js +122 -0
- package/dist/fable_modules/fable-library.4.5.0/TimeSpan.d.ts +34 -0
- package/dist/fable_modules/fable-library.4.5.0/TimeSpan.js +177 -0
- package/dist/fable_modules/fable-library.4.5.0/Timer.d.ts +19 -0
- package/dist/fable_modules/fable-library.4.5.0/Timer.js +67 -0
- package/dist/fable_modules/fable-library.4.5.0/Types.d.ts +58 -0
- package/dist/fable_modules/fable-library.4.5.0/Types.js +208 -0
- package/dist/fable_modules/fable-library.4.5.0/Unicode.13.0.0.d.ts +2 -0
- package/dist/fable_modules/fable-library.4.5.0/Unicode.13.0.0.js +4 -0
- package/dist/fable_modules/fable-library.4.5.0/Uri.d.ts +29 -0
- package/dist/fable_modules/fable-library.4.5.0/Uri.js +142 -0
- package/dist/fable_modules/fable-library.4.5.0/Util.d.ts +207 -0
- package/dist/fable_modules/fable-library.4.5.0/Util.js +781 -0
- package/dist/fable_modules/fable-library.4.5.0/lib/big.d.ts +5 -0
- package/dist/fable_modules/fable-library.4.5.0/lib/big.js +826 -0
- package/dist/fable_modules/fable-library.4.5.0/package.json +23 -0
- package/dist/fable_modules/project_cracked.json +1 -0
- package/package.json +37 -0
|
@@ -0,0 +1,403 @@
|
|
|
1
|
+
import { toString, Union, Record } from "../fable_modules/fable-library.4.5.0/Types.js";
|
|
2
|
+
import { float64_type, int32_type, union_type, list_type, option_type, record_type, bool_type, string_type } from "../fable_modules/fable-library.4.5.0/Reflection.js";
|
|
3
|
+
import { int32ToString } from "../fable_modules/fable-library.4.5.0/Util.js";
|
|
4
|
+
|
|
5
|
+
export class GlueParameter extends Record {
|
|
6
|
+
constructor(Name, IsOptional, Type) {
|
|
7
|
+
super();
|
|
8
|
+
this.Name = Name;
|
|
9
|
+
this.IsOptional = IsOptional;
|
|
10
|
+
this.Type = Type;
|
|
11
|
+
}
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
export function GlueParameter_$reflection() {
|
|
15
|
+
return record_type("Glutinum.Converter.GlueAST.GlueParameter", [], GlueParameter, () => [["Name", string_type], ["IsOptional", bool_type], ["Type", GlueType_$reflection()]]);
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
export class GlueTypeParameter extends Record {
|
|
19
|
+
constructor(Name, Constraint, Default) {
|
|
20
|
+
super();
|
|
21
|
+
this.Name = Name;
|
|
22
|
+
this.Constraint = Constraint;
|
|
23
|
+
this.Default = Default;
|
|
24
|
+
}
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
export function GlueTypeParameter_$reflection() {
|
|
28
|
+
return record_type("Glutinum.Converter.GlueAST.GlueTypeParameter", [], GlueTypeParameter, () => [["Name", string_type], ["Constraint", option_type(GlueType_$reflection())], ["Default", option_type(GlueType_$reflection())]]);
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
export class GlueMethod extends Record {
|
|
32
|
+
constructor(Name, Parameters, Type, IsOptional, IsStatic) {
|
|
33
|
+
super();
|
|
34
|
+
this.Name = Name;
|
|
35
|
+
this.Parameters = Parameters;
|
|
36
|
+
this.Type = Type;
|
|
37
|
+
this.IsOptional = IsOptional;
|
|
38
|
+
this.IsStatic = IsStatic;
|
|
39
|
+
}
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
export function GlueMethod_$reflection() {
|
|
43
|
+
return record_type("Glutinum.Converter.GlueAST.GlueMethod", [], GlueMethod, () => [["Name", string_type], ["Parameters", list_type(GlueParameter_$reflection())], ["Type", GlueType_$reflection()], ["IsOptional", bool_type], ["IsStatic", bool_type]]);
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
export class GlueCallSignature extends Record {
|
|
47
|
+
constructor(Parameters, Type) {
|
|
48
|
+
super();
|
|
49
|
+
this.Parameters = Parameters;
|
|
50
|
+
this.Type = Type;
|
|
51
|
+
}
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
export function GlueCallSignature_$reflection() {
|
|
55
|
+
return record_type("Glutinum.Converter.GlueAST.GlueCallSignature", [], GlueCallSignature, () => [["Parameters", list_type(GlueParameter_$reflection())], ["Type", GlueType_$reflection()]]);
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
export class GlueAccessor extends Union {
|
|
59
|
+
constructor(tag, fields) {
|
|
60
|
+
super();
|
|
61
|
+
this.tag = tag;
|
|
62
|
+
this.fields = fields;
|
|
63
|
+
}
|
|
64
|
+
cases() {
|
|
65
|
+
return ["ReadOnly", "WriteOnly", "ReadWrite"];
|
|
66
|
+
}
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
export function GlueAccessor_$reflection() {
|
|
70
|
+
return union_type("Glutinum.Converter.GlueAST.GlueAccessor", [], GlueAccessor, () => [[], [], []]);
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
export class GlueProperty extends Record {
|
|
74
|
+
constructor(Name, Type, IsStatic, Accessor) {
|
|
75
|
+
super();
|
|
76
|
+
this.Name = Name;
|
|
77
|
+
this.Type = Type;
|
|
78
|
+
this.IsStatic = IsStatic;
|
|
79
|
+
this.Accessor = Accessor;
|
|
80
|
+
}
|
|
81
|
+
}
|
|
82
|
+
|
|
83
|
+
export function GlueProperty_$reflection() {
|
|
84
|
+
return record_type("Glutinum.Converter.GlueAST.GlueProperty", [], GlueProperty, () => [["Name", string_type], ["Type", GlueType_$reflection()], ["IsStatic", bool_type], ["Accessor", GlueAccessor_$reflection()]]);
|
|
85
|
+
}
|
|
86
|
+
|
|
87
|
+
export class GlueIndexSignature extends Record {
|
|
88
|
+
constructor(Parameters, Type) {
|
|
89
|
+
super();
|
|
90
|
+
this.Parameters = Parameters;
|
|
91
|
+
this.Type = Type;
|
|
92
|
+
}
|
|
93
|
+
}
|
|
94
|
+
|
|
95
|
+
export function GlueIndexSignature_$reflection() {
|
|
96
|
+
return record_type("Glutinum.Converter.GlueAST.GlueIndexSignature", [], GlueIndexSignature, () => [["Parameters", list_type(GlueParameter_$reflection())], ["Type", GlueType_$reflection()]]);
|
|
97
|
+
}
|
|
98
|
+
|
|
99
|
+
export class GlueMember extends Union {
|
|
100
|
+
constructor(tag, fields) {
|
|
101
|
+
super();
|
|
102
|
+
this.tag = tag;
|
|
103
|
+
this.fields = fields;
|
|
104
|
+
}
|
|
105
|
+
cases() {
|
|
106
|
+
return ["Method", "Property", "CallSignature", "IndexSignature"];
|
|
107
|
+
}
|
|
108
|
+
}
|
|
109
|
+
|
|
110
|
+
export function GlueMember_$reflection() {
|
|
111
|
+
return union_type("Glutinum.Converter.GlueAST.GlueMember", [], GlueMember, () => [[["Item", GlueMethod_$reflection()]], [["Item", GlueProperty_$reflection()]], [["Item", GlueCallSignature_$reflection()]], [["Item", GlueIndexSignature_$reflection()]]]);
|
|
112
|
+
}
|
|
113
|
+
|
|
114
|
+
export class GlueInterface extends Record {
|
|
115
|
+
constructor(Name, Members, TypeParameters) {
|
|
116
|
+
super();
|
|
117
|
+
this.Name = Name;
|
|
118
|
+
this.Members = Members;
|
|
119
|
+
this.TypeParameters = TypeParameters;
|
|
120
|
+
}
|
|
121
|
+
}
|
|
122
|
+
|
|
123
|
+
export function GlueInterface_$reflection() {
|
|
124
|
+
return record_type("Glutinum.Converter.GlueAST.GlueInterface", [], GlueInterface, () => [["Name", string_type], ["Members", list_type(GlueMember_$reflection())], ["TypeParameters", list_type(GlueTypeParameter_$reflection())]]);
|
|
125
|
+
}
|
|
126
|
+
|
|
127
|
+
export class GlueVariable extends Record {
|
|
128
|
+
constructor(Name, Type) {
|
|
129
|
+
super();
|
|
130
|
+
this.Name = Name;
|
|
131
|
+
this.Type = Type;
|
|
132
|
+
}
|
|
133
|
+
}
|
|
134
|
+
|
|
135
|
+
export function GlueVariable_$reflection() {
|
|
136
|
+
return record_type("Glutinum.Converter.GlueAST.GlueVariable", [], GlueVariable, () => [["Name", string_type], ["Type", GlueType_$reflection()]]);
|
|
137
|
+
}
|
|
138
|
+
|
|
139
|
+
export class GluePrimitive extends Union {
|
|
140
|
+
constructor(tag, fields) {
|
|
141
|
+
super();
|
|
142
|
+
this.tag = tag;
|
|
143
|
+
this.fields = fields;
|
|
144
|
+
}
|
|
145
|
+
cases() {
|
|
146
|
+
return ["String", "Int", "Float", "Bool", "Unit", "Number", "Any", "Null", "Undefined"];
|
|
147
|
+
}
|
|
148
|
+
}
|
|
149
|
+
|
|
150
|
+
export function GluePrimitive_$reflection() {
|
|
151
|
+
return union_type("Glutinum.Converter.GlueAST.GluePrimitive", [], GluePrimitive, () => [[], [], [], [], [], [], [], [], []]);
|
|
152
|
+
}
|
|
153
|
+
|
|
154
|
+
export class GlueLiteral extends Union {
|
|
155
|
+
constructor(tag, fields) {
|
|
156
|
+
super();
|
|
157
|
+
this.tag = tag;
|
|
158
|
+
this.fields = fields;
|
|
159
|
+
}
|
|
160
|
+
cases() {
|
|
161
|
+
return ["String", "Int", "Float", "Bool"];
|
|
162
|
+
}
|
|
163
|
+
}
|
|
164
|
+
|
|
165
|
+
export function GlueLiteral_$reflection() {
|
|
166
|
+
return union_type("Glutinum.Converter.GlueAST.GlueLiteral", [], GlueLiteral, () => [[["Item", string_type]], [["Item", int32_type]], [["Item", float64_type]], [["Item", bool_type]]]);
|
|
167
|
+
}
|
|
168
|
+
|
|
169
|
+
export class GlueEnumMember extends Record {
|
|
170
|
+
constructor(Name, Value) {
|
|
171
|
+
super();
|
|
172
|
+
this.Name = Name;
|
|
173
|
+
this.Value = Value;
|
|
174
|
+
}
|
|
175
|
+
}
|
|
176
|
+
|
|
177
|
+
export function GlueEnumMember_$reflection() {
|
|
178
|
+
return record_type("Glutinum.Converter.GlueAST.GlueEnumMember", [], GlueEnumMember, () => [["Name", string_type], ["Value", GlueLiteral_$reflection()]]);
|
|
179
|
+
}
|
|
180
|
+
|
|
181
|
+
export class GlueEnum extends Record {
|
|
182
|
+
constructor(Name, Members) {
|
|
183
|
+
super();
|
|
184
|
+
this.Name = Name;
|
|
185
|
+
this.Members = Members;
|
|
186
|
+
}
|
|
187
|
+
}
|
|
188
|
+
|
|
189
|
+
export function GlueEnum_$reflection() {
|
|
190
|
+
return record_type("Glutinum.Converter.GlueAST.GlueEnum", [], GlueEnum, () => [["Name", string_type], ["Members", list_type(GlueEnumMember_$reflection())]]);
|
|
191
|
+
}
|
|
192
|
+
|
|
193
|
+
export class GlueTypeAliasDeclaration extends Record {
|
|
194
|
+
constructor(Name, Type, TypeParameters) {
|
|
195
|
+
super();
|
|
196
|
+
this.Name = Name;
|
|
197
|
+
this.Type = Type;
|
|
198
|
+
this.TypeParameters = TypeParameters;
|
|
199
|
+
}
|
|
200
|
+
}
|
|
201
|
+
|
|
202
|
+
export function GlueTypeAliasDeclaration_$reflection() {
|
|
203
|
+
return record_type("Glutinum.Converter.GlueAST.GlueTypeAliasDeclaration", [], GlueTypeAliasDeclaration, () => [["Name", string_type], ["Type", GlueType_$reflection()], ["TypeParameters", list_type(GlueTypeParameter_$reflection())]]);
|
|
204
|
+
}
|
|
205
|
+
|
|
206
|
+
export class GlueFunctionDeclaration extends Record {
|
|
207
|
+
constructor(IsDeclared, Name, Type, Parameters) {
|
|
208
|
+
super();
|
|
209
|
+
this.IsDeclared = IsDeclared;
|
|
210
|
+
this.Name = Name;
|
|
211
|
+
this.Type = Type;
|
|
212
|
+
this.Parameters = Parameters;
|
|
213
|
+
}
|
|
214
|
+
}
|
|
215
|
+
|
|
216
|
+
export function GlueFunctionDeclaration_$reflection() {
|
|
217
|
+
return record_type("Glutinum.Converter.GlueAST.GlueFunctionDeclaration", [], GlueFunctionDeclaration, () => [["IsDeclared", bool_type], ["Name", string_type], ["Type", GlueType_$reflection()], ["Parameters", list_type(GlueParameter_$reflection())]]);
|
|
218
|
+
}
|
|
219
|
+
|
|
220
|
+
export class GlueModuleDeclaration extends Record {
|
|
221
|
+
constructor(Name, IsNamespace, IsRecursive, Types) {
|
|
222
|
+
super();
|
|
223
|
+
this.Name = Name;
|
|
224
|
+
this.IsNamespace = IsNamespace;
|
|
225
|
+
this.IsRecursive = IsRecursive;
|
|
226
|
+
this.Types = Types;
|
|
227
|
+
}
|
|
228
|
+
}
|
|
229
|
+
|
|
230
|
+
export function GlueModuleDeclaration_$reflection() {
|
|
231
|
+
return record_type("Glutinum.Converter.GlueAST.GlueModuleDeclaration", [], GlueModuleDeclaration, () => [["Name", string_type], ["IsNamespace", bool_type], ["IsRecursive", bool_type], ["Types", list_type(GlueType_$reflection())]]);
|
|
232
|
+
}
|
|
233
|
+
|
|
234
|
+
export class GlueConstructor extends Union {
|
|
235
|
+
constructor(Item) {
|
|
236
|
+
super();
|
|
237
|
+
this.tag = 0;
|
|
238
|
+
this.fields = [Item];
|
|
239
|
+
}
|
|
240
|
+
cases() {
|
|
241
|
+
return ["GlueConstructor"];
|
|
242
|
+
}
|
|
243
|
+
}
|
|
244
|
+
|
|
245
|
+
export function GlueConstructor_$reflection() {
|
|
246
|
+
return union_type("Glutinum.Converter.GlueAST.GlueConstructor", [], GlueConstructor, () => [[["Item", list_type(GlueParameter_$reflection())]]]);
|
|
247
|
+
}
|
|
248
|
+
|
|
249
|
+
export class GlueClassDeclaration extends Record {
|
|
250
|
+
constructor(Name, Constructors, Members, TypeParameters) {
|
|
251
|
+
super();
|
|
252
|
+
this.Name = Name;
|
|
253
|
+
this.Constructors = Constructors;
|
|
254
|
+
this.Members = Members;
|
|
255
|
+
this.TypeParameters = TypeParameters;
|
|
256
|
+
}
|
|
257
|
+
}
|
|
258
|
+
|
|
259
|
+
export function GlueClassDeclaration_$reflection() {
|
|
260
|
+
return record_type("Glutinum.Converter.GlueAST.GlueClassDeclaration", [], GlueClassDeclaration, () => [["Name", string_type], ["Constructors", list_type(GlueConstructor_$reflection())], ["Members", list_type(GlueMember_$reflection())], ["TypeParameters", list_type(GlueTypeParameter_$reflection())]]);
|
|
261
|
+
}
|
|
262
|
+
|
|
263
|
+
export class GlueTypeReference extends Record {
|
|
264
|
+
constructor(Name, FullName) {
|
|
265
|
+
super();
|
|
266
|
+
this.Name = Name;
|
|
267
|
+
this.FullName = FullName;
|
|
268
|
+
}
|
|
269
|
+
}
|
|
270
|
+
|
|
271
|
+
export function GlueTypeReference_$reflection() {
|
|
272
|
+
return record_type("Glutinum.Converter.GlueAST.GlueTypeReference", [], GlueTypeReference, () => [["Name", string_type], ["FullName", string_type]]);
|
|
273
|
+
}
|
|
274
|
+
|
|
275
|
+
export class GlueTypeUnion extends Union {
|
|
276
|
+
constructor(Item) {
|
|
277
|
+
super();
|
|
278
|
+
this.tag = 0;
|
|
279
|
+
this.fields = [Item];
|
|
280
|
+
}
|
|
281
|
+
cases() {
|
|
282
|
+
return ["GlueTypeUnion"];
|
|
283
|
+
}
|
|
284
|
+
}
|
|
285
|
+
|
|
286
|
+
export function GlueTypeUnion_$reflection() {
|
|
287
|
+
return union_type("Glutinum.Converter.GlueAST.GlueTypeUnion", [], GlueTypeUnion, () => [[["Item", list_type(GlueType_$reflection())]]]);
|
|
288
|
+
}
|
|
289
|
+
|
|
290
|
+
export class ExcludedMember extends Union {
|
|
291
|
+
constructor(Item) {
|
|
292
|
+
super();
|
|
293
|
+
this.tag = 0;
|
|
294
|
+
this.fields = [Item];
|
|
295
|
+
}
|
|
296
|
+
cases() {
|
|
297
|
+
return ["Literal"];
|
|
298
|
+
}
|
|
299
|
+
}
|
|
300
|
+
|
|
301
|
+
export function ExcludedMember_$reflection() {
|
|
302
|
+
return union_type("Glutinum.Converter.GlueAST.ExcludedMember", [], ExcludedMember, () => [[["Item", GlueLiteral_$reflection()]]]);
|
|
303
|
+
}
|
|
304
|
+
|
|
305
|
+
export class GlueFunctionType extends Record {
|
|
306
|
+
constructor(Type, Parameters) {
|
|
307
|
+
super();
|
|
308
|
+
this.Type = Type;
|
|
309
|
+
this.Parameters = Parameters;
|
|
310
|
+
}
|
|
311
|
+
}
|
|
312
|
+
|
|
313
|
+
export function GlueFunctionType_$reflection() {
|
|
314
|
+
return record_type("Glutinum.Converter.GlueAST.GlueFunctionType", [], GlueFunctionType, () => [["Type", GlueType_$reflection()], ["Parameters", list_type(GlueParameter_$reflection())]]);
|
|
315
|
+
}
|
|
316
|
+
|
|
317
|
+
export class GlueType extends Union {
|
|
318
|
+
constructor(tag, fields) {
|
|
319
|
+
super();
|
|
320
|
+
this.tag = tag;
|
|
321
|
+
this.fields = fields;
|
|
322
|
+
}
|
|
323
|
+
cases() {
|
|
324
|
+
return ["Discard", "Interface", "Variable", "Primitive", "Enum", "TypeAliasDeclaration", "FunctionDeclaration", "Union", "Literal", "KeyOf", "IndexedAccessType", "ModuleDeclaration", "ClassDeclaration", "TypeReference", "Partial", "Array", "FunctionType", "TypeParameter"];
|
|
325
|
+
}
|
|
326
|
+
}
|
|
327
|
+
|
|
328
|
+
export function GlueType_$reflection() {
|
|
329
|
+
return union_type("Glutinum.Converter.GlueAST.GlueType", [], GlueType, () => [[], [["Item", GlueInterface_$reflection()]], [["Item", GlueVariable_$reflection()]], [["Item", GluePrimitive_$reflection()]], [["Item", GlueEnum_$reflection()]], [["Item", GlueTypeAliasDeclaration_$reflection()]], [["Item", GlueFunctionDeclaration_$reflection()]], [["Item", GlueTypeUnion_$reflection()]], [["Item", GlueLiteral_$reflection()]], [["Item", GlueType_$reflection()]], [["Item", GlueType_$reflection()]], [["Item", GlueModuleDeclaration_$reflection()]], [["Item", GlueClassDeclaration_$reflection()]], [["Item", GlueTypeReference_$reflection()]], [["Item", GlueInterface_$reflection()]], [["Item", GlueType_$reflection()]], [["Item", GlueFunctionType_$reflection()]], [["Item", string_type]]]);
|
|
330
|
+
}
|
|
331
|
+
|
|
332
|
+
export function GlueLiteral__ToText(this$) {
|
|
333
|
+
switch (this$.tag) {
|
|
334
|
+
case 1:
|
|
335
|
+
return int32ToString(this$.fields[0]);
|
|
336
|
+
case 2:
|
|
337
|
+
return this$.fields[0].toString();
|
|
338
|
+
case 3:
|
|
339
|
+
return toString(this$.fields[0]);
|
|
340
|
+
default:
|
|
341
|
+
return this$.fields[0];
|
|
342
|
+
}
|
|
343
|
+
}
|
|
344
|
+
|
|
345
|
+
export function GlueType__get_Name(this$) {
|
|
346
|
+
switch (this$.tag) {
|
|
347
|
+
case 2:
|
|
348
|
+
return this$.fields[0].Name;
|
|
349
|
+
case 3: {
|
|
350
|
+
const info_2 = this$.fields[0];
|
|
351
|
+
switch (info_2.tag) {
|
|
352
|
+
case 1:
|
|
353
|
+
return "int";
|
|
354
|
+
case 2:
|
|
355
|
+
return "float";
|
|
356
|
+
case 3:
|
|
357
|
+
return "bool";
|
|
358
|
+
case 4:
|
|
359
|
+
return "unit";
|
|
360
|
+
case 5:
|
|
361
|
+
return "float";
|
|
362
|
+
case 6:
|
|
363
|
+
return "obj";
|
|
364
|
+
case 7:
|
|
365
|
+
return "obj option";
|
|
366
|
+
case 8:
|
|
367
|
+
return "obj";
|
|
368
|
+
default:
|
|
369
|
+
return "string";
|
|
370
|
+
}
|
|
371
|
+
}
|
|
372
|
+
case 4:
|
|
373
|
+
return this$.fields[0].Name;
|
|
374
|
+
case 5:
|
|
375
|
+
return this$.fields[0].Name;
|
|
376
|
+
case 17:
|
|
377
|
+
return this$.fields[0];
|
|
378
|
+
case 8:
|
|
379
|
+
return GlueLiteral__ToText(this$.fields[0]);
|
|
380
|
+
case 9:
|
|
381
|
+
return "string";
|
|
382
|
+
case 6:
|
|
383
|
+
return this$.fields[0].Name;
|
|
384
|
+
case 11:
|
|
385
|
+
return this$.fields[0].Name;
|
|
386
|
+
case 12:
|
|
387
|
+
return this$.fields[0].Name;
|
|
388
|
+
case 13:
|
|
389
|
+
return this$.fields[0].Name;
|
|
390
|
+
case 15:
|
|
391
|
+
return `ResizeArray<${GlueType__get_Name(this$.fields[0])}>`;
|
|
392
|
+
case 10:
|
|
393
|
+
case 7:
|
|
394
|
+
case 14:
|
|
395
|
+
case 16:
|
|
396
|
+
case 0:
|
|
397
|
+
return "obj";
|
|
398
|
+
default:
|
|
399
|
+
return this$.fields[0].Name;
|
|
400
|
+
}
|
|
401
|
+
}
|
|
402
|
+
|
|
403
|
+
//# sourceMappingURL=GlueAST.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../../src/Glutinum.Converter/GlueAST.fs"],"names":["this","value","info","ToText","Name"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;YAsGcA;;iCAES,AAAAA;;mBACSC,AAAP,AAAAD;;AACD,mBAAA,SAAA,AAAAA;;AAHE,mBAAA,AAAAA;;;;;YA0FZA;;AAEa,mBAAA,AAAAA;;AACPE,2BACF,AAAAF;oBAAAE;;2BAEiB;;2BACE;;2BACD;;2BACA;;2BACE;;2BACH;;2BACC;;2BACK;;2BARH;;;;AASf,mBAAA,AAAAF;;AACgB,mBAAA,AAAAA;;AACP,mBAAA,AAAAA;;AACN,mBAAA,AAAAG,oBAAA,AAAAH;;mBACL;;AACiB,mBAAA,AAAAA;;AACF,mBAAA,AAAAA;;AACD,mBAAA,AAAAA;;AACH,mBAAA,AAAAA;;mBACR,eAAe,AAAAI,mBAAf,AAAAJ;;;;;;mBAKH;;AA3BO,mBAAA,AAAAA","file":null,"sourcesContent":null,"sourceRoot":null}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import chalk from "chalk";
|
|
2
|
+
import { some } from "../fable_modules/fable-library.4.5.0/Option.js";
|
|
3
|
+
|
|
4
|
+
export function success(text) {
|
|
5
|
+
console.log(some(chalk.greenBright(text)));
|
|
6
|
+
}
|
|
7
|
+
|
|
8
|
+
export function info(text) {
|
|
9
|
+
console.log(some(chalk.blueBright(text)));
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
export function warn(text) {
|
|
13
|
+
console.log(some(chalk.yellowBright(text)));
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
export function error(text) {
|
|
17
|
+
console.log(some(chalk.redBright(text)));
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
export function debug(text) {
|
|
21
|
+
console.log(some(text));
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
//# sourceMappingURL=Log.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../../src/Glutinum.Converter/Log.fs"],"names":["text"],"mappings":";;;;AAMI,gBAAgB,KAAA,kBAAyBA;;;;AAGzC,gBAAgB,KAAA,iBAAwBA;;;;AAGxC,gBAAgB,KAAA,mBAA0BA;;;;AAG1C,gBAAgB,KAAA,gBAAuBA;;;;AAEhB,gBAAe,KAAAA","file":null,"sourcesContent":null,"sourceRoot":null}
|