@@ -42,17 +42,6 @@ function tsExport (registry: Registry, definitions: Record<string, ModuleTypes>,
4242 return exportInterface ( def . lookupIndex , def . name , formatType ( registry , definitions , def , imports , false ) ) ;
4343}
4444
45- const tsBTreeMap = tsExport ;
46- const tsBTreeSet = tsExport ;
47- const tsCompact = tsExport ;
48- const tsDoNotConstruct = tsExport ;
49- const tsHashMap = tsExport ;
50- const tsOption = tsExport ;
51- const tsPlain = tsExport ;
52- const tsTuple = tsExport ;
53- const tsWrapperKeepOpaque = tsExport ;
54- const tsWrapperOpaque = tsExport ;
55-
5645/** @internal */
5746function tsEnum ( registry : Registry , definitions : Record < string , ModuleTypes > , { lookupIndex, name : enumName , sub } : TypeDef , imports : TypeImports ) : string {
5847 setImports ( definitions , imports , [ 'Enum' ] ) ;
@@ -227,29 +216,29 @@ function tsVec (registry: Registry, definitions: Record<string, ModuleTypes>, de
227216// `generators[typedef.info](...)` TS will show any unhandled types. Rather
228217// we are being explicit in having no handlers where we do not support (yet)
229218export const typeEncoders : Record < TypeDefInfo , ( registry : Registry , definitions : Record < string , ModuleTypes > , def : TypeDef , imports : TypeImports ) => string > = {
230- [ TypeDefInfo . BTreeMap ] : tsBTreeMap ,
231- [ TypeDefInfo . BTreeSet ] : tsBTreeSet ,
232- [ TypeDefInfo . Compact ] : tsCompact ,
233- [ TypeDefInfo . DoNotConstruct ] : tsDoNotConstruct ,
219+ [ TypeDefInfo . BTreeMap ] : tsExport ,
220+ [ TypeDefInfo . BTreeSet ] : tsExport ,
221+ [ TypeDefInfo . Compact ] : tsExport ,
222+ [ TypeDefInfo . DoNotConstruct ] : tsExport ,
234223 [ TypeDefInfo . Enum ] : tsEnum ,
235- [ TypeDefInfo . HashMap ] : tsHashMap ,
224+ [ TypeDefInfo . HashMap ] : tsExport ,
236225 [ TypeDefInfo . Int ] : tsInt ,
237226 [ TypeDefInfo . Linkage ] : errorUnhandled ,
238227 [ TypeDefInfo . Null ] : tsNull ,
239- [ TypeDefInfo . Option ] : tsOption ,
240- [ TypeDefInfo . Plain ] : tsPlain ,
241- [ TypeDefInfo . Range ] : errorUnhandled ,
242- [ TypeDefInfo . RangeInclusive ] : errorUnhandled ,
228+ [ TypeDefInfo . Option ] : tsExport ,
229+ [ TypeDefInfo . Plain ] : tsExport ,
230+ [ TypeDefInfo . Range ] : tsExport ,
231+ [ TypeDefInfo . RangeInclusive ] : tsExport ,
243232 [ TypeDefInfo . Result ] : tsResult ,
244233 [ TypeDefInfo . Set ] : tsSet ,
245234 [ TypeDefInfo . Si ] : tsSi ,
246235 [ TypeDefInfo . Struct ] : tsStruct ,
247- [ TypeDefInfo . Tuple ] : tsTuple ,
236+ [ TypeDefInfo . Tuple ] : tsExport ,
248237 [ TypeDefInfo . UInt ] : tsUInt ,
249238 [ TypeDefInfo . Vec ] : tsVec ,
250239 [ TypeDefInfo . VecFixed ] : tsVec ,
251- [ TypeDefInfo . WrapperKeepOpaque ] : tsWrapperKeepOpaque ,
252- [ TypeDefInfo . WrapperOpaque ] : tsWrapperOpaque
240+ [ TypeDefInfo . WrapperKeepOpaque ] : tsExport ,
241+ [ TypeDefInfo . WrapperOpaque ] : tsExport
253242} ;
254243
255244/** @internal */
0 commit comments