Skip to content

Commit

Permalink
Remove unused context manager
Browse files Browse the repository at this point in the history
  • Loading branch information
Sekenre committed Dec 4, 2018
1 parent 31ab387 commit bb6d467
Showing 1 changed file with 0 additions and 9 deletions.
9 changes: 0 additions & 9 deletions cbor2/decoder.py
@@ -1,7 +1,6 @@
import re
import struct
from datetime import datetime, timedelta
from contextlib import contextmanager
from io import BytesIO

from .compat import timezone, xrange, byte_as_integer, unpack_float16
Expand Down Expand Up @@ -418,14 +417,6 @@ def decode_from_bytes(self, buf):
self.fp = old_fp
return retval

@contextmanager
def key_decoder(self):
""" Forces decoders that return mutable types by default to produce immutable types."""
original_flag = self._immutable
self._immutable = True
yield self.decode
self._immutable = original_flag


def loads(payload, **kwargs):
"""
Expand Down

0 comments on commit bb6d467

Please sign in to comment.