@@ -405,7 +405,6 @@ public struct BridgeJSLink {
405405 scope : JSGlueVariableScope ( intrinsicRegistry : intrinsicRegistry ) ,
406406 printer : printer ,
407407 hasDirectAccessToSwiftClass : false ,
408- classNamespaces : intrinsicRegistry . classNamespaces
409408 )
410409 }
411410
@@ -1226,7 +1225,6 @@ public struct BridgeJSLink {
12261225 scope : structScope ,
12271226 printer : structPrinter ,
12281227 hasDirectAccessToSwiftClass : false ,
1229- classNamespaces : intrinsicRegistry . classNamespaces
12301228 )
12311229 )
12321230 bodyPrinter . write ( lines : structPrinter . lines )
@@ -1248,7 +1246,6 @@ public struct BridgeJSLink {
12481246 scope : enumScope ,
12491247 printer : enumPrinter ,
12501248 hasDirectAccessToSwiftClass : false ,
1251- classNamespaces : intrinsicRegistry . classNamespaces
12521249 )
12531250 )
12541251 bodyPrinter . write ( lines : enumPrinter . lines )
@@ -1348,14 +1345,6 @@ public struct BridgeJSLink {
13481345 public func link ( sharedMemory : Bool = false ) throws -> ( outputJs : String , outputDts : String ) {
13491346 intrinsicRegistry . reset ( )
13501347 importedModuleRegistry . configure ( skeletons : skeletons )
1351- intrinsicRegistry . classNamespaces = skeletons . reduce ( into : [ : ] ) { result , unified in
1352- guard let skeleton = unified . exported else { return }
1353- for klass in skeleton . classes {
1354- if let namespace = klass . resolvedJSNamespace {
1355- result [ klass . name ] = namespace
1356- }
1357- }
1358- }
13591348 intrinsicRegistry . classPaths = skeletons . reduce ( into : [ : ] ) { result , unified in
13601349 for klass in unified . exported ? . classes ?? [ ] {
13611350 result [ klass . swiftCallName ] = klass . tsPathComponents
@@ -1581,7 +1570,6 @@ public struct BridgeJSLink {
15811570 scope : scope ,
15821571 printer : body ,
15831572 hasDirectAccessToSwiftClass : hasDirectAccessToSwiftClass ,
1584- classNamespaces : intrinsicRegistry . classNamespaces
15851573 )
15861574 }
15871575
@@ -2617,7 +2605,6 @@ extension BridgeJSLink {
26172605 scope : scope ,
26182606 printer : body ,
26192607 hasDirectAccessToSwiftClass : false ,
2620- classNamespaces : intrinsicRegistry . classNamespaces
26212608 )
26222609 }
26232610
@@ -4158,14 +4145,15 @@ extension BridgeJSLink {
41584145 fileprivate func renderJSDoc ( documentation : String ? , parameters : [ Parameter ] ) -> [ String ] {
41594146 let parsed = documentation . map ( DocCComment . init ( parsing : ) ) ?? DocCComment ( )
41604147
4148+ let resolveTypeName = makeCodecPrintContext ( printer : CodeFragmentPrinter ( ) ) . defaultValueTypeName
41614149 var tagLines : [ String ] = [ ]
41624150 for parameter in parameters {
41634151 let docText = parsed . parameter ( named : parameter . name )
41644152 let defaultValue = parameter . defaultValue . map {
41654153 DefaultValueUtils . format (
41664154 $0 ,
41674155 as : . typescript ,
4168- resolveTypeName : makeCodecPrintContext ( printer : CodeFragmentPrinter ( ) ) . defaultValueTypeName
4156+ resolveTypeName : resolveTypeName
41694157 )
41704158 }
41714159 switch ( docText , defaultValue ) {
0 commit comments