def default_decoder(self, obj):
typename, marshalled_state = self.unwrap_callback(obj)<EOL>if typename is None:<EOL><INDENT>return obj<EOL><DEDENT>try:<EOL><INDENT>cls, unmarshaller = self.serializer.unmarshallers[typename]<EOL><DEDENT>except KeyError:<EOL><INDENT>raise LookupError('<STR_LIT>'.format(typename)) from None<EOL><DEDENT>if cls is not None:<EOL><INDENT>instance = cls.__new__(cls)<EOL>unmarshaller(instance, marshalled_state)<EOL>return instance<EOL><DEDENT>else:<EOL><INDENT>return unmarshaller(marshalled_state)<EOL><DEDENT>
Handle a dict that might contain a wrapped state for a custom type.