@@ -1068,51 +1068,51 @@ type sliceHeader struct {
10681068
10691069var (
10701070 nullType = reflect .TypeOf (nil )
1071- boolType = reflect .TypeOf ( false )
1072-
1073- intType = reflect .TypeOf ( int ( 0 ) )
1074- int8Type = reflect .TypeOf ( int8 ( 0 ) )
1075- int16Type = reflect .TypeOf ( int16 ( 0 ) )
1076- int32Type = reflect .TypeOf ( int32 ( 0 ) )
1077- int64Type = reflect .TypeOf ( int64 ( 0 ) )
1078-
1079- uintType = reflect .TypeOf ( uint ( 0 ) )
1080- uint8Type = reflect .TypeOf ( uint8 ( 0 ) )
1081- uint16Type = reflect .TypeOf ( uint16 ( 0 ) )
1082- uint32Type = reflect .TypeOf ( uint32 ( 0 ) )
1083- uint64Type = reflect .TypeOf ( uint64 ( 0 ) )
1084- uintptrType = reflect .TypeOf ( uintptr ( 0 ) )
1085-
1086- float32Type = reflect .TypeOf ( float32 ( 0 ) )
1087- float64Type = reflect .TypeOf ( float64 ( 0 ) )
1088-
1089- bigIntType = reflect .TypeOf ( new ( big.Int ) )
1090- numberType = reflect .TypeOf ( json .Number ( "" ) )
1091- stringType = reflect .TypeOf ( "" )
1092- stringsType = reflect .TypeOf ([ ]string ( nil ) )
1093- bytesType = reflect .TypeOf (([ ]byte )( nil ) )
1094- durationType = reflect .TypeOf ( time .Duration ( 0 ) )
1095- timeType = reflect .TypeOf ( time.Time {} )
1096- rawMessageType = reflect .TypeOf ( RawMessage ( nil ) )
1071+ boolType = reflect .TypeFor [ bool ]( )
1072+
1073+ intType = reflect .TypeFor [ int ]( )
1074+ int8Type = reflect .TypeFor [ int8 ]( )
1075+ int16Type = reflect .TypeFor [ int16 ]( )
1076+ int32Type = reflect .TypeFor [ int32 ]( )
1077+ int64Type = reflect .TypeFor [ int64 ]( )
1078+
1079+ uintType = reflect .TypeFor [ uint ]( )
1080+ uint8Type = reflect .TypeFor [ uint8 ]( )
1081+ uint16Type = reflect .TypeFor [ uint16 ]( )
1082+ uint32Type = reflect .TypeFor [ uint32 ]( )
1083+ uint64Type = reflect .TypeFor [ uint64 ]( )
1084+ uintptrType = reflect .TypeFor [ uintptr ]( )
1085+
1086+ float32Type = reflect .TypeFor [ float32 ]( )
1087+ float64Type = reflect .TypeFor [ float64 ]( )
1088+
1089+ bigIntType = reflect .TypeFor [ * big.Int ]( )
1090+ numberType = reflect .TypeFor [ json.Number ]( )
1091+ stringType = reflect .TypeFor [ string ]( )
1092+ stringsType = reflect .TypeFor [[ ]string ]( )
1093+ bytesType = reflect .TypeFor [[ ]byte ]( )
1094+ durationType = reflect .TypeFor [ time.Duration ]( )
1095+ timeType = reflect .TypeFor [ time.Time ]( )
1096+ rawMessageType = reflect .TypeFor [ RawMessage ]( )
10971097
10981098 numberPtrType = reflect .PtrTo (numberType )
10991099 durationPtrType = reflect .PtrTo (durationType )
11001100 timePtrType = reflect .PtrTo (timeType )
11011101 rawMessagePtrType = reflect .PtrTo (rawMessageType )
11021102
1103- sliceInterfaceType = reflect .TypeOf (([ ]any )( nil ) )
1104- sliceStringType = reflect .TypeOf (([ ]any )( nil ) )
1105- mapStringInterfaceType = reflect .TypeOf (( map [string ]any )( nil ) )
1106- mapStringRawMessageType = reflect .TypeOf (( map [string ]RawMessage )( nil ) )
1107- mapStringStringType = reflect .TypeOf (( map [string ]string )( nil ) )
1108- mapStringStringSliceType = reflect .TypeOf (( map [string ][]string )( nil ) )
1109- mapStringBoolType = reflect .TypeOf (( map [string ]bool )( nil ) )
1110-
1111- interfaceType = reflect .TypeOf (( * any )( nil )). Elem ()
1112- jsonMarshalerType = reflect .TypeOf (( * Marshaler )( nil )). Elem ()
1113- jsonUnmarshalerType = reflect .TypeOf (( * Unmarshaler )( nil )). Elem ()
1114- textMarshalerType = reflect .TypeOf (( * encoding .TextMarshaler )( nil )). Elem ()
1115- textUnmarshalerType = reflect .TypeOf (( * encoding .TextUnmarshaler )( nil )). Elem ()
1103+ sliceInterfaceType = reflect .TypeFor [[ ]any ]( )
1104+ sliceStringType = reflect .TypeFor [[ ]any ]( )
1105+ mapStringInterfaceType = reflect .TypeFor [ map [string ]any ]( )
1106+ mapStringRawMessageType = reflect .TypeFor [ map [string ]RawMessage ]( )
1107+ mapStringStringType = reflect .TypeFor [ map [string ]string ]( )
1108+ mapStringStringSliceType = reflect .TypeFor [ map [string ][]string ]( )
1109+ mapStringBoolType = reflect .TypeFor [ map [string ]bool ]( )
1110+
1111+ interfaceType = reflect .TypeFor [ any ] ()
1112+ jsonMarshalerType = reflect .TypeFor [ Marshaler ] ()
1113+ jsonUnmarshalerType = reflect .TypeFor [ Unmarshaler ] ()
1114+ textMarshalerType = reflect .TypeFor [ encoding.TextMarshaler ] ()
1115+ textUnmarshalerType = reflect .TypeFor [ encoding.TextUnmarshaler ] ()
11161116
11171117 bigIntDecoder = constructJSONUnmarshalerDecodeFunc (bigIntType , false )
11181118)
0 commit comments