This commit is contained in:
Umur Ozkul 2022-06-09 15:53:07 +02:00
parent e4eceb9cd3
commit 2f4db3230d
2 changed files with 8 additions and 5 deletions

View File

@ -188,7 +188,10 @@ function createTsExport(
case "EvTypeIdentifier":
return tag("typeIdentifier", x.value);
case "EvModule":
let moduleResult: tagged<"module", { [key: string]: squiggleExpression }> = tag(
let moduleResult: tagged<
"module",
{ [key: string]: squiggleExpression }
> = tag(
"module",
_.mapValues(x.value, (x: unknown) =>
convertRawToTypescript(x as rescriptExport, environment)

View File

@ -75,9 +75,9 @@ export type rescriptExport =
_0: string;
}
| {
TAG: 14; // EvModule
_0: { [key: string]: rescriptExport };
};
TAG: 14; // EvModule
_0: { [key: string]: rescriptExport };
};
type rescriptDist =
| { TAG: 0; _0: rescriptPointSetDist }
@ -184,7 +184,7 @@ export function convertRawToTypescript(
return tag("typeIdentifier", result._0);
case 14: // EvModule
return tag(
"module",
"module",
_.mapValues(result._0, (x) => convertRawToTypescript(x, environment))
);
}