(type_ reflect.Type)
| 196 | } |
| 197 | |
| 198 | func (c *ReadContext) getTypeInfoByType(type_ reflect.Type) *TypeInfo { |
| 199 | if type_ == nil { |
| 200 | return nil |
| 201 | } |
| 202 | typePtr := typePointer(type_) |
| 203 | if typePtr == c.lastTypePtr && c.lastTypeInfo != nil { |
| 204 | return c.lastTypeInfo |
| 205 | } |
| 206 | info := c.typeResolver.getTypeInfoByType(type_) |
| 207 | if info != nil { |
| 208 | c.lastTypePtr = typePtr |
| 209 | c.lastTypeInfo = info |
| 210 | } |
| 211 | return info |
| 212 | } |
| 213 | |
| 214 | // readFast reads a value using fast path based on DispatchId |
| 215 | func (c *ReadContext) readFast(ptr unsafe.Pointer, ct DispatchId) { |
no test coverage detected