RegisterLeafDecoder can be used to register new leaf error types to the library. Registered types will be decoded using their own Go type when an error is decoded. Wrappers that have not been registered will be decoded using the opaqueLeaf type. Note: if the error type has been migrated from a prev
(typeName TypeKey, decoder LeafDecoder)
| 70 | // or a different type, ensure that RegisterTypeMigration() was called |
| 71 | // prior to RegisterLeafDecoder(). |
| 72 | func RegisterLeafDecoder(typeName TypeKey, decoder LeafDecoder) { |
| 73 | errbase.RegisterLeafDecoder(typeName, decoder) |
| 74 | } |
| 75 | |
| 76 | // TypeKey identifies an error for the purpose of looking up decoders. |
| 77 | // It is equivalent to the "family name" in ErrorTypeMarker. |
nothing calls this directly
no test coverage detected
searching dependent graphs…