File tree 3 files changed +13
-4
lines changed
3 files changed +13
-4
lines changed Original file line number Diff line number Diff line change @@ -6,7 +6,7 @@ export class Value<T extends Type = Type> {
6
6
public type : T ,
7
7
public data : ResolveType < T > ,
8
8
) { }
9
-
9
+
10
10
public encode ( codec : JsonValueCodec ) : void {
11
11
const value = this . data ;
12
12
const type = this . type ;
Original file line number Diff line number Diff line change @@ -60,7 +60,12 @@ export class TypeSystem implements Printable {
60
60
61
61
public importTypes < A extends TypeMap > (
62
62
types : A ,
63
- ) : { readonly [ K in keyof A ] : TypeAlias < K extends string ? K : never , /** @todo Replace `any` by inferred type here. */ any > } {
63
+ ) : {
64
+ readonly [ K in keyof A ] : TypeAlias <
65
+ K extends string ? K : never ,
66
+ /** @todo Replace `any` by inferred type here. */ any
67
+ > ;
68
+ } {
64
69
const result = { } as any ;
65
70
for ( const id in types ) result [ id ] = this . alias ( id , this . t . import ( types [ id ] ) ) ;
66
71
return result ;
Original file line number Diff line number Diff line change @@ -198,9 +198,13 @@ export class TypeBuilder {
198
198
case 'ref' :
199
199
return this . Ref ( node . ref ) . options ( node ) ;
200
200
case 'fn' :
201
- return this . Function ( this . import ( node . req as schema . Schema ) , this . import ( node . res as schema . Schema ) ) . options ( node ) ;
201
+ return this . Function ( this . import ( node . req as schema . Schema ) , this . import ( node . res as schema . Schema ) ) . options (
202
+ node ,
203
+ ) ;
202
204
case 'fn$' :
203
- return this . Function$ ( this . import ( node . req as schema . Schema ) , this . import ( node . res as schema . Schema ) ) . options ( node ) ;
205
+ return this . Function$ ( this . import ( node . req as schema . Schema ) , this . import ( node . res as schema . Schema ) ) . options (
206
+ node ,
207
+ ) ;
204
208
}
205
209
throw new Error ( `UNKNOWN_NODE [${ node . kind } ]` ) ;
206
210
}
You can’t perform that action at this time.
0 commit comments