@glutinum/cli 0.11.0 → 0.13.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 +64 -2
- package/dist/Glutinum.Converter/FsharpAST.js +34 -14
- package/dist/Glutinum.Converter/FsharpAST.js.map +1 -1
- package/dist/Glutinum.Converter/Generate.js.map +1 -1
- package/dist/Glutinum.Converter/GlueAST.js +144 -9
- package/dist/Glutinum.Converter/GlueAST.js.map +1 -1
- package/dist/Glutinum.Converter/Merge.js +1 -1
- package/dist/Glutinum.Converter/Merge.js.map +1 -1
- package/dist/Glutinum.Converter/Printer.js +104 -62
- package/dist/Glutinum.Converter/Printer.js.map +1 -1
- package/dist/Glutinum.Converter/Read.js.map +1 -1
- package/dist/Glutinum.Converter/Reader/ClassDeclaration.js +1 -1
- package/dist/Glutinum.Converter/Reader/ClassDeclaration.js.map +1 -1
- package/dist/Glutinum.Converter/Reader/Declaration.js +2 -2
- package/dist/Glutinum.Converter/Reader/Declaration.js.map +1 -1
- package/dist/Glutinum.Converter/Reader/Documentation.js.map +1 -1
- package/dist/Glutinum.Converter/Reader/EnumDeclaration.js +2 -2
- package/dist/Glutinum.Converter/Reader/EnumDeclaration.js.map +1 -1
- package/dist/Glutinum.Converter/Reader/ExportAssignment.js.map +1 -1
- package/dist/Glutinum.Converter/Reader/FunctionDeclaration.js +1 -1
- package/dist/Glutinum.Converter/Reader/FunctionDeclaration.js.map +1 -1
- package/dist/Glutinum.Converter/Reader/IndexedAccessType.js +1 -1
- package/dist/Glutinum.Converter/Reader/IndexedAccessType.js.map +1 -1
- package/dist/Glutinum.Converter/Reader/InterfaceDeclaration.js.map +1 -1
- package/dist/Glutinum.Converter/Reader/MappedTypeNode.js +1 -1
- package/dist/Glutinum.Converter/Reader/MappedTypeNode.js.map +1 -1
- package/dist/Glutinum.Converter/Reader/ModuleDeclaration.js +2 -1
- package/dist/Glutinum.Converter/Reader/ModuleDeclaration.js.map +1 -1
- package/dist/Glutinum.Converter/Reader/NamedTupleMember.js.map +1 -1
- package/dist/Glutinum.Converter/Reader/Node.js +1 -1
- package/dist/Glutinum.Converter/Reader/Node.js.map +1 -1
- package/dist/Glutinum.Converter/Reader/Parameters.js +1 -1
- package/dist/Glutinum.Converter/Reader/Parameters.js.map +1 -1
- package/dist/Glutinum.Converter/Reader/Report.js.map +1 -1
- package/dist/Glutinum.Converter/Reader/TypeNode.js +192 -73
- package/dist/Glutinum.Converter/Reader/TypeNode.js.map +1 -1
- package/dist/Glutinum.Converter/Reader/TypeOperatorNode.js +5 -5
- package/dist/Glutinum.Converter/Reader/TypeOperatorNode.js.map +1 -1
- package/dist/Glutinum.Converter/Reader/TypeParameters.js +1 -1
- package/dist/Glutinum.Converter/Reader/TypeParameters.js.map +1 -1
- package/dist/Glutinum.Converter/Reader/TypeQueryNode.js +8 -8
- package/dist/Glutinum.Converter/Reader/TypeQueryNode.js.map +1 -1
- package/dist/Glutinum.Converter/Reader/TypeScriptReader.js.map +1 -1
- package/dist/Glutinum.Converter/Reader/UnionTypeNode.js +2 -2
- package/dist/Glutinum.Converter/Reader/UnionTypeNode.js.map +1 -1
- package/dist/Glutinum.Converter/Reader/Utils.js +34 -2
- package/dist/Glutinum.Converter/Reader/Utils.js.map +1 -1
- package/dist/Glutinum.Converter/Reader/VariableStatement.js +1 -1
- package/dist/Glutinum.Converter/Reader/VariableStatement.js.map +1 -1
- package/dist/Glutinum.Converter/Transform.js +886 -256
- package/dist/Glutinum.Converter/Transform.js.map +1 -1
- package/dist/Glutinum.Converter/TypeScript.Extensions.js +10 -0
- package/dist/Glutinum.Converter/TypeScript.Extensions.js.map +1 -1
- package/dist/Glutinum.Converter/Utils/Naming.js +18 -5
- package/dist/Glutinum.Converter/Utils/Naming.js.map +1 -1
- package/dist/fable_modules/project_cracked.json +1 -1
- package/package.json +2 -2
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../../src/Glutinum.Converter/Reader/TypeParameters.fs"],"names":["typeParameters","typeParameter","reader","typNode"],"mappings":";;;;;;AAWU,QAAA,AAAAA;AAKC,eAAA,wBACC,sBACW,AAAAC,
|
|
1
|
+
{"version":3,"sources":["../../../src/Glutinum.Converter/Reader/TypeParameters.fs"],"names":["typeParameters","typeParameter","reader","typNode"],"mappings":";;;;;;AAWU,QAAA,AAAAA;AAKC,eAAA,wBACC,sBACW,AAAAC,8BACsC,mBAAW,AAAAC,iFAAAC,UAA3C,AAAAF,2BAC0B,qBAAW,AAAAC,iFAAAC,YAAxC,AAAAF,0BALf,OADHD;;;AAFM,eAAA","file":null,"sourcesContent":null,"sourceRoot":null}
|
|
@@ -24,7 +24,7 @@ export function readTypeQueryNode(reader, typeQueryNode) {
|
|
|
24
24
|
const matchValue_6 = declaration_1.kind | 0;
|
|
25
25
|
switch (matchValue_6) {
|
|
26
26
|
case 263:
|
|
27
|
-
return new GlueType(12, [new GlueClassDeclaration(symbol.name, empty(), empty(), empty(), empty())]);
|
|
27
|
+
return new GlueType(12, [new GlueClassDeclaration(empty(), symbol.name, empty(), empty(), empty(), empty())]);
|
|
28
28
|
case 267:
|
|
29
29
|
return new GlueType(0, []);
|
|
30
30
|
default:
|
|
@@ -37,7 +37,7 @@ export function readTypeQueryNode(reader, typeQueryNode) {
|
|
|
37
37
|
let _arg_5;
|
|
38
38
|
let input_9;
|
|
39
39
|
const option = checker.getSymbolAtLocation(exprName);
|
|
40
|
-
const error = Report_readerError_Z19516DCE("type node (TypeQuery)", "Missing symbol", typeQueryNode, "/
|
|
40
|
+
const error = Report_readerError_Z19516DCE("type node (TypeQuery)", "Missing symbol", typeQueryNode, "/home/mmangel/Workspaces/Github/glutinum-org/cli/main/src/Glutinum.Converter/Reader/TypeQueryNode.fs", 29);
|
|
41
41
|
const option_1 = option;
|
|
42
42
|
input_9 = ((option_1 == null) ? (new FSharpResult$2(1, [error])) : (new FSharpResult$2(0, [option_1])));
|
|
43
43
|
if (input_9.tag === 1) {
|
|
@@ -46,7 +46,7 @@ export function readTypeQueryNode(reader, typeQueryNode) {
|
|
|
46
46
|
else {
|
|
47
47
|
let input_7;
|
|
48
48
|
const option_2 = input_9.fields[0].declarations;
|
|
49
|
-
const error_2 = Report_readerError_Z19516DCE("type node (TypeQuery)", "Missing declarations", typeQueryNode, "/
|
|
49
|
+
const error_2 = Report_readerError_Z19516DCE("type node (TypeQuery)", "Missing declarations", typeQueryNode, "/home/mmangel/Workspaces/Github/glutinum-org/cli/main/src/Glutinum.Converter/Reader/TypeQueryNode.fs", 39);
|
|
50
50
|
const option_3 = option_2;
|
|
51
51
|
input_7 = ((option_3 == null) ? (new FSharpResult$2(1, [error_2])) : (new FSharpResult$2(0, [option_3])));
|
|
52
52
|
if (input_7.tag === 1) {
|
|
@@ -54,7 +54,7 @@ export function readTypeQueryNode(reader, typeQueryNode) {
|
|
|
54
54
|
}
|
|
55
55
|
else {
|
|
56
56
|
const declarations = input_7.fields[0];
|
|
57
|
-
const input_5 = (declarations.length !== 1) ? (new FSharpResult$2(1, [Report_readerError_Z19516DCE("type node (TypeQuery)", "Expected exactly one declaration", typeQueryNode, "/
|
|
57
|
+
const input_5 = (declarations.length !== 1) ? (new FSharpResult$2(1, [Report_readerError_Z19516DCE("type node (TypeQuery)", "Expected exactly one declaration", typeQueryNode, "/home/mmangel/Workspaces/Github/glutinum-org/cli/main/src/Glutinum.Converter/Reader/TypeQueryNode.fs", 48)])) : (new FSharpResult$2(0, [declarations[0]]));
|
|
58
58
|
if (input_5.tag === 1) {
|
|
59
59
|
_arg_5 = (new FSharpResult$2(1, [input_5.fields[0]]));
|
|
60
60
|
}
|
|
@@ -62,14 +62,14 @@ export function readTypeQueryNode(reader, typeQueryNode) {
|
|
|
62
62
|
const declaration = input_5.fields[0];
|
|
63
63
|
let input_3;
|
|
64
64
|
const matchValue_3 = declaration.kind | 0;
|
|
65
|
-
input_3 = ((matchValue_3 === 260) ? (new FSharpResult$2(0, [declaration])) : (new FSharpResult$2(1, [Report_readerError_Z19516DCE("type node (TypeQuery)", `Unsupported declaration kind ${TypeScript_Ts_SyntaxKind__SyntaxKind_get_Name(matchValue_3)}`, typeQueryNode, "/
|
|
65
|
+
input_3 = ((matchValue_3 === 260) ? (new FSharpResult$2(0, [declaration])) : (new FSharpResult$2(1, [Report_readerError_Z19516DCE("type node (TypeQuery)", `Unsupported declaration kind ${TypeScript_Ts_SyntaxKind__SyntaxKind_get_Name(matchValue_3)}`, typeQueryNode, "/home/mmangel/Workspaces/Github/glutinum-org/cli/main/src/Glutinum.Converter/Reader/TypeQueryNode.fs", 64)])));
|
|
66
66
|
if (input_3.tag === 1) {
|
|
67
67
|
_arg_5 = (new FSharpResult$2(1, [input_3.fields[0]]));
|
|
68
68
|
}
|
|
69
69
|
else {
|
|
70
70
|
let input_1;
|
|
71
71
|
const option_4 = input_3.fields[0].type;
|
|
72
|
-
const error_4 = Report_readerError_Z19516DCE("type node (TypeQuery)", "Missing type", typeQueryNode, "/
|
|
72
|
+
const error_4 = Report_readerError_Z19516DCE("type node (TypeQuery)", "Missing type", typeQueryNode, "/home/mmangel/Workspaces/Github/glutinum-org/cli/main/src/Glutinum.Converter/Reader/TypeQueryNode.fs", 74);
|
|
73
73
|
const option_5 = option_4;
|
|
74
74
|
input_1 = ((option_5 == null) ? (new FSharpResult$2(1, [error_4])) : (new FSharpResult$2(0, [option_5])));
|
|
75
75
|
if (input_1.tag === 1) {
|
|
@@ -83,7 +83,7 @@ export function readTypeQueryNode(reader, typeQueryNode) {
|
|
|
83
83
|
_arg_5 = (new FSharpResult$2(0, [reader["Glutinum.Converter.Reader.Types.ITypeScriptReader.ReadTypeOperatorNodeZ6830FC33"](typeOperatorNode)]));
|
|
84
84
|
}
|
|
85
85
|
else {
|
|
86
|
-
_arg_5 = (new FSharpResult$2(1, [Report_readerError_Z19516DCE("type node (TypeQuery)", `Unsupported declaration kind ${TypeScript_Ts_SyntaxKind__SyntaxKind_get_Name(matchValue_4)}`, typeQueryNode, "/
|
|
86
|
+
_arg_5 = (new FSharpResult$2(1, [Report_readerError_Z19516DCE("type node (TypeQuery)", `Unsupported declaration kind ${TypeScript_Ts_SyntaxKind__SyntaxKind_get_Name(matchValue_4)}`, typeQueryNode, "/home/mmangel/Workspaces/Github/glutinum-org/cli/main/src/Glutinum.Converter/Reader/TypeQueryNode.fs", 84)]));
|
|
87
87
|
}
|
|
88
88
|
}
|
|
89
89
|
}
|
|
@@ -99,7 +99,7 @@ export function readTypeQueryNode(reader, typeQueryNode) {
|
|
|
99
99
|
}
|
|
100
100
|
}
|
|
101
101
|
else {
|
|
102
|
-
const warning_1 = Report_readerError_Z19516DCE("type node (TypeQuery)", "Expected an Identifier", typeQueryNode, "/
|
|
102
|
+
const warning_1 = Report_readerError_Z19516DCE("type node (TypeQuery)", "Expected an Identifier", typeQueryNode, "/home/mmangel/Workspaces/Github/glutinum-org/cli/main/src/Glutinum.Converter/Reader/TypeQueryNode.fs", 100);
|
|
103
103
|
void (reader["Glutinum.Converter.Reader.Types.ITypeScriptReader.get_Warnings"]().push(warning_1));
|
|
104
104
|
return new GlueType(3, [new GluePrimitive(6, [])]);
|
|
105
105
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../../src/Glutinum.Converter/Reader/TypeQueryNode.fs","../../fable_modules/FsToolkit.ErrorHandling.4.16.0/Result.fs","../../fable_modules/FsToolkit.ErrorHandling.4.16.0/ResultCE.fs"],"names":["checker","reader","typ","typeQueryNode","matchValue","exprNameKind","symbol","declarations","declaration","exprName","_arg6","input","option","error","typeNode","typeOperatorNode","warning"],"mappings":";;;;;;;;
|
|
1
|
+
{"version":3,"sources":["../../../src/Glutinum.Converter/Reader/TypeQueryNode.fs","../../fable_modules/FsToolkit.ErrorHandling.4.16.0/Result.fs","../../fable_modules/FsToolkit.ErrorHandling.4.16.0/ResultCE.fs"],"names":["checker","reader","typ","typeQueryNode","matchValue","exprNameKind","symbol","declarations","declaration","exprName","_arg6","input","option","error","typeNode","typeOperatorNode","warning"],"mappings":";;;;;;;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
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../../src/Glutinum.Converter/Reader/TypeScriptReader.fs"],"names":["checker","_","this","classDeclaration","enumDeclaration","functionDeclaration","interfaceDeclaration","moduleDeclaration","typ","node","typeAliasDeclaration","typNode","variableStatement","declaration","parameters","unionType","typeParametersOpt","exportAssignment","namedTupleMember"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;AAyBsB,6BAAAA;AAClB;AAKA;;;AAIaC,kBAAAA;AAA4B,eAAA,AAAAA;;;AAE9BA,kBAAAA;AAAa,eAAA,AAAAA;;;AAEbA,kBAAAA;AAAe,eAAA,AAAAA;;;AAEfC,sBAAAA;
|
|
1
|
+
{"version":3,"sources":["../../../src/Glutinum.Converter/Reader/TypeScriptReader.fs"],"names":["checker","_","this","classDeclaration","enumDeclaration","functionDeclaration","interfaceDeclaration","moduleDeclaration","typ","node","typeAliasDeclaration","typNode","variableStatement","declaration","parameters","unionType","typeParametersOpt","exportAssignment","namedTupleMember"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;AAyBsB,6BAAAA;AAClB;AAKA;;;AAIaC,kBAAAA;AAA4B,eAAA,AAAAA;;;AAE9BA,kBAAAA;AAAa,eAAA,AAAAA;;;AAEbA,kBAAAA;AAAe,eAAA,AAAAA;;;AAEfC,sBAAAA;AACH,eAAA,qBAAqBA,OAAKC;;;AAEvBD,sBAAAA;AACyC,eAAA,iBAA5C,oBAAoBA,OAAKE;;;AAEtBF,sBAAAA;AAIiD,eAAA,iBAApD,wBAAwBA,OAAKG;;;AAE1BH,sBAAAA;AAImD,eAAA,iBAAtD,yBAAyBA,OAAKI;;;AAE3BJ,sBAAAA;AAC6C,eAAA,kBAAhD,sBAAsBA,OAAKK;;;AAExBL,sBAAAA;AACCM,oBAAM,SAASN,OAAKO;AACxB,cAAA,AAAAP,sBAAeM;eACfA;;;AAEGN,sBAAAA;AAIH,eAAA,yBAAyBA,OAAKQ;;;AAE3BR,sBAAAA;AACH,eAAA,AAACA,iFAA6CS;;;AAE3CT,sBAAAA;AACG,eAAA,CAAA,AAAAS,oBAEI,iBAAmB,8BADX,aAAaT,OAAbS;;;AAGfT,sBAAAA;AACH,eAAA,sBAAsBA,OAAKU;;;AAExBV,sBAAAA;AACH,eAAA,gBAAgBA,OAAKW;;;AAElBX,sBAAAA;AAIH,eAAA,eAAeA,OAAKY;;;AAEjBZ,sBAAAA;AACH,eAAA,kBAAkBA,OAAKa;;;AAEpBb,sBAAAA;AACH,eAAA,qBAAqBA,OAAKO;;;AAEvBP,sBAAAA;AACH,eAAA,sBAAsBA,OAAKW;;;AAExBX,sBAAAA;AAIH,eAAA,mBAAmBA,OAAKc;;;AAErBd,sBAAAA;AACH,eAAA,qBAAqBA,OAAKe;;;AAEvBf,sBAAAA;AACH,eAAA,8BAA8BA,OAAKW;;;AAEhCX,sBAAAA;AACH,eAAA,yBAAyBA,OAAKO;;;AAE3BP,sBAAAA;AACH,eAAA,qBAAqBA,OAAKgB;;;AAEvBhB,sBAAAA;AACH,eAAA,mBAAmBA,OAAKW","file":null,"sourcesContent":null,"sourceRoot":null}
|
|
@@ -47,7 +47,7 @@ function readUnionTypeCases(reader, unionTypeNode) {
|
|
|
47
47
|
const typeReferenceNode = node_1;
|
|
48
48
|
const symbolOpt = checker.getSymbolAtLocation(typeReferenceNode.typeName);
|
|
49
49
|
const symbol = defaultArgWith(symbolOpt, () => {
|
|
50
|
-
throw new Error(Report_readerError_Z19516DCE("union type cases", "Missing symbol", typeReferenceNode, "/
|
|
50
|
+
throw new Error(Report_readerError_Z19516DCE("union type cases", "Missing symbol", typeReferenceNode, "/home/mmangel/Workspaces/Github/glutinum-org/cli/main/src/Glutinum.Converter/Reader/UnionTypeNode.fs", 58));
|
|
51
51
|
});
|
|
52
52
|
const matchValue_1 = symbol.declarations;
|
|
53
53
|
if (matchValue_1 == null) {
|
|
@@ -57,7 +57,7 @@ function readUnionTypeCases(reader, unionTypeNode) {
|
|
|
57
57
|
return singleton(new GlueType(3, [new GluePrimitive(6, [])]));
|
|
58
58
|
}
|
|
59
59
|
else {
|
|
60
|
-
throw new Error(Report_readerError_Z19516DCE("union type cases", "Unsupported type reference reach a point where it was expected to have flags like Any", typeReferenceNode, "/
|
|
60
|
+
throw new Error(Report_readerError_Z19516DCE("union type cases", "Unsupported type reference reach a point where it was expected to have flags like Any", typeReferenceNode, "/home/mmangel/Workspaces/Github/glutinum-org/cli/main/src/Glutinum.Converter/Reader/UnionTypeNode.fs", 93));
|
|
61
61
|
}
|
|
62
62
|
}
|
|
63
63
|
else {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../../src/Glutinum.Converter/Reader/UnionTypeNode.fs"],"names":["checker","reader","removeParenthesizedType","node","parenthesizedTypeNode","literalTypeNode","literalExpression","matchValue","typeReferenceNode","symbolOpt","symbol","typ","declarations","declaration","readUnionTypeCases","unionTypeNode"],"mappings":";;;;;;;;;AAaQA,oBAAU,AAAAC;AAMNC;;;kBAAyBC;AAC7B,gBAAG,mCAA2BA;AACtBC,8CAAwBD;2BAEJ,AAAAC;AAAxB;;;uBAEAD;;;;;
|
|
1
|
+
{"version":3,"sources":["../../../src/Glutinum.Converter/Reader/UnionTypeNode.fs"],"names":["checker","reader","removeParenthesizedType","node","parenthesizedTypeNode","literalTypeNode","literalExpression","matchValue","typeReferenceNode","symbolOpt","symbol","typ","declarations","declaration","readUnionTypeCases","unionTypeNode"],"mappings":";;;;;;;;;AAaQA,oBAAU,AAAAC;AAMNC;;;kBAAyBC;AAC7B,gBAAG,mCAA2BA;AACtBC,8CAAwBD;2BAEJ,AAAAC;AAAxB;;;uBAEAD;;;;;AAuFL,WAAA,kBADA,OAhFA;AACC,YAAG,6BAAqBA;AAChBE,oCAAkBF;AAElBG,sCAAgD,AAAAD;AAEpD,gBAAG,2BAAmBC,qBAAnB,OAAwC,4BAAoBA;AAI5C,uBAAA,UADZ,iBADA,eADH,eAAeA;AACkB,oCAAS;;;;AAKpCC,mCAAA,AAAAD;wBAAAC;yBAAA;yBAAA;AAGuC,\u002BBAAA,UAAzC,iBAAmB;;AAChB,\u002BBAAA;;;;aACV,IAAG,\u002BBAAuBJ;AACvBK,sCAAoBL;AAEpBM,8BAAY,AAAAT,4BAA8B,AAAAQ;AAE1CE,2BACA,eASID;AAFO,gCALH,6BACI,oBACA,kBACAD,mBAHJ,wGAAA;;AAWND,iCAAA,AAAAG;AAAA,gBAAA,AAAAH;AAkBEI,4BAAM,AAAAX,wBAAwBU;AAE5BH,qCAAA,AAAAI;AACJ,oBADI,AACJ,6BAAa,GADTJ;AAEsC,2BAAA,UAAxC,iBAAmB;;;AAOhB,oCALH,6BACI,oBACA,yFACAC,mBAHJ,wGAAA;;;;AAvBDI,qCACHL;AAAA,oBAAG,AAAAK,wBAAqB;AACpB,2BAAA;;qBACC,IAAG,aAAaH;AACwB,2BAAA,UAAzC,AAAAR,iFAAoBO;;;AAGhBK,wCAAc,AAAAD,aAAc;AAG1B,wBAAA,AAAAC,qBAAA;AAE6B,\u002BBAAA,UAA/B,AAAAZ,6EAAgBY;;;AAE4B,\u002BBAAA,UAAzC,AAAAZ,iFAAoBO;;;;;aAiB7B,IAAA,AAAAL,gBAAA;AAIE,mBAAA,AAAwB,AAAAW,mBAAmBb,QAF3BE;;;AAOyB,mBAAA,UAA7C,AAAAF,iFAAoBE;;OA/E7B,IAASD,yBAFT,OADH,AAAAa;;;;WAwF2C,iBAA3C,AAAAD,mBAAmBb,QAAOc","file":null,"sourcesContent":null,"sourceRoot":null}
|
|
@@ -5,8 +5,10 @@ import { GlueAccessor, GlueLiteral } from "../GlueAST.js";
|
|
|
5
5
|
import { tryParse as tryParse_1 } from "../../fable_modules/fable-library-js.4.14.0/Double.js";
|
|
6
6
|
import { class_type } from "../../fable_modules/fable-library-js.4.14.0/Reflection.js";
|
|
7
7
|
import { toList, exists } from "../../fable_modules/fable-library-js.4.14.0/Seq.js";
|
|
8
|
-
import { collect, empty, map } from "../../fable_modules/fable-library-js.4.14.0/List.js";
|
|
8
|
+
import { ofArray, contains, collect, empty, map } from "../../fable_modules/fable-library-js.4.14.0/List.js";
|
|
9
9
|
import { endsWith } from "../../fable_modules/fable-library-js.4.14.0/String.js";
|
|
10
|
+
import { stringHash } from "../../fable_modules/fable-library-js.4.14.0/Util.js";
|
|
11
|
+
import { FSharpChoice$3, FSharpChoice$2 } from "../../fable_modules/fable-library-js.4.14.0/Choice.js";
|
|
10
12
|
|
|
11
13
|
export function $007CHasTypeFlags$007C_$007C(flag, flags) {
|
|
12
14
|
if ((flags & flag) !== 0) {
|
|
@@ -188,7 +190,10 @@ export function isFromEs5Lib(symbolOpt) {
|
|
|
188
190
|
}
|
|
189
191
|
}
|
|
190
192
|
else {
|
|
191
|
-
return
|
|
193
|
+
return contains(symbol.name, ofArray(["Iterable", "IterableIterator"]), {
|
|
194
|
+
Equals: (x, y) => (x === y),
|
|
195
|
+
GetHashCode: stringHash,
|
|
196
|
+
});
|
|
192
197
|
}
|
|
193
198
|
}
|
|
194
199
|
else {
|
|
@@ -196,4 +201,31 @@ export function isFromEs5Lib(symbolOpt) {
|
|
|
196
201
|
}
|
|
197
202
|
}
|
|
198
203
|
|
|
204
|
+
export function Type_StringLiteral_$007CString$007COther$007C(literalType) {
|
|
205
|
+
const matchValue = literalType.flags | 0;
|
|
206
|
+
if ($007CHasTypeFlags$007C_$007C(128, matchValue) != null) {
|
|
207
|
+
const literalType_1 = literalType;
|
|
208
|
+
return new FSharpChoice$2(0, [literalType_1.value]);
|
|
209
|
+
}
|
|
210
|
+
else {
|
|
211
|
+
return new FSharpChoice$2(1, [void 0]);
|
|
212
|
+
}
|
|
213
|
+
}
|
|
214
|
+
|
|
215
|
+
export function Type_NumberLiteral_$007CInt$007CFloat$007COther$007C(literalType) {
|
|
216
|
+
const matchValue = literalType.flags | 0;
|
|
217
|
+
if ($007CHasTypeFlags$007C_$007C(256, matchValue) != null) {
|
|
218
|
+
const literalType_1 = literalType;
|
|
219
|
+
if (Number.isSafeInteger(literalType_1.value)) {
|
|
220
|
+
return new FSharpChoice$3(0, [literalType_1.value]);
|
|
221
|
+
}
|
|
222
|
+
else {
|
|
223
|
+
return new FSharpChoice$3(1, [literalType_1.value]);
|
|
224
|
+
}
|
|
225
|
+
}
|
|
226
|
+
else {
|
|
227
|
+
return new FSharpChoice$3(2, [void 0]);
|
|
228
|
+
}
|
|
229
|
+
}
|
|
230
|
+
|
|
199
231
|
//# sourceMappingURL=Utils.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../../src/Glutinum.Converter/Reader/Utils.fs"],"names":["flags","flag","text","isNumericString","matchValue","outArg","expression","literal","tryReadNumericLiteral","node","checker","symbol","tryGetFullName","modifiers","modifier","GetAccessor","currentModifier","HasModifier","reader","heritageClauses","typNode","clause","symbolOpt","declarations","sourceFile"],"mappings":"
|
|
1
|
+
{"version":3,"sources":["../../../src/Glutinum.Converter/Reader/Utils.fs"],"names":["flags","flag","text","isNumericString","matchValue","outArg","expression","literal","tryReadNumericLiteral","node","checker","symbol","tryGetFullName","modifiers","modifier","GetAccessor","currentModifier","HasModifier","reader","heritageClauses","typNode","clause","symbolOpt","declarations","sourceFile","literalType","(|HasTypeFlags|_|)"],"mappings":";;;;;;;;;;;;;AASI,QAAG,CAAA,AAAIA,QAAcC,UAAQ;AACzB,eAAA,KAAI;;;AAEJ,eAAA;;;;;AAGJ,QAAG,CAAA,AAAID,QAAcC,UAAQ;AACzB,eAAA,KAAI;;;AAEJ,eAAA;;;;;AAGJ,QAAG,CAAA,AAAID,QAAcC,UAAQ;AACzB,eAAA,KAAI;;;AAEJ,eAAA;;;;;AAGJ,QAAA,CAAA,OAASC,UAAO;AAAuD,eAAA,CAA7B,aAARA;;;eAAlC;;;;;AAGA,QAAG,AAAAC,gBAAgBD;AAETE;AAAAC;AAAAD,sBAAA,SAAsBF,sBAAtB,oBAAAG;AAAAA;aAAAA;AAAA,YAAA,AAAAD;AACS,mBAAA,oBAAA,AAAAA;;;AAGLA;AAA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AAAC,qBAA6B;;;uBAC1B;;;;AAP\u002BB,mBAAA,SAAc,AAAAb,aAApD,SAAE,YAAY;;;;;;;eANZ;;;;;AAoBIP,uBAAA,AAAAqB;AACJ,QADI,AACJ,AAAAC,6BAAa,KADTtB;AAEEqB,8BAAcA;AAElB,eAAA,uBAAqB,AAAAA;;;AAClB,eAAA,uBAAA;;;;;AAKDrB,uBAAA,AAAAqB;AACJ,QADI,AACJ,AAAAC,6BAAa,KADTtB;AAEEqB,8BAAcA;AAElB,YAAG,qBAAkC,AAAAA;AACjC,mBAAA,uBAAe,AAAAA;;;AAEf,mBAAA,uBAAmB,AAAAA;;;;AACpB,eAAA,uBAAA","file":null,"sourcesContent":null,"sourceRoot":null}
|
|
@@ -15,7 +15,7 @@ export function readVariableStatement(reader, statement) {
|
|
|
15
15
|
name = id.getText();
|
|
16
16
|
}
|
|
17
17
|
else {
|
|
18
|
-
throw new Error(Report_readerError_Z19516DCE("variable statement", "Unable to read variable name", declaration, "/
|
|
18
|
+
throw new Error(Report_readerError_Z19516DCE("variable statement", "Unable to read variable name", declaration, "/home/mmangel/Workspaces/Github/glutinum-org/cli/main/src/Glutinum.Converter/Reader/VariableStatement.fs", 29));
|
|
19
19
|
}
|
|
20
20
|
return new GlueType(2, [new GlueVariable(reader["Glutinum.Converter.Reader.Types.ITypeScriptReader.ReadDocumentationFromNode6C0FD055"](declaration), name, reader["Glutinum.Converter.Reader.Types.ITypeScriptReader.ReadTypeNodeZ64B23DD2"](declaration.type))]);
|
|
21
21
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../../src/Glutinum.Converter/Reader/VariableStatement.fs"],"names":["modifier","modifiers","statement","matchValue","declaration","name","id","reader"],"mappings":";;;;;;;
|
|
1
|
+
{"version":3,"sources":["../../../src/Glutinum.Converter/Reader/VariableStatement.fs"],"names":["modifier","modifiers","statement","matchValue","declaration","name","id","reader"],"mappings":";;;;;;;AAiBI,QAFO,WAJA,mBAEI,sBAA4B,AAAAA,kBAAgB,KAD/CC,YAFJ,AAAAC,sBAKuB;AAGjBC,2BAA0C,OAA1C,AAAAD;AAAA,YAAA,CAAA,QAAAC;AAGJC,gCACM,KAAAD;AAAAE;AACM,gBAAA,AAAAD,0BAAA;AAEEE,2BAAsB,AAAAF;AAC1B,AAJJC,uBAII,AAAAC;;;AAOG,gCALH,6BACI,sBACA,gCACAF,aAHJ,4GAAA;;AAaL,mBAAA,iBANF,iBACmB,AAAAG,8FAAiCH,cAC1CC,MACA,AAAAE,kFAAoB,AAAAH;;;AAnB3B,mBAAA;;;;AAyBR,eAAA","file":null,"sourcesContent":null,"sourceRoot":null}
|