MCPcopy Index your code
hub / github.com/RustPython/RustPython / __enter__

Method __enter__

Lib/_pydecimal.py:3840–3843  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

3838 def __init__(self, new_context):
3839 self.new_context = new_context.copy()
3840 def __enter__(self):
3841 self.saved_context = getcontext()
3842 setcontext(self.new_context)
3843 return self.new_context
3844 def __exit__(self, t, v, tb):
3845 setcontext(self.saved_context)
3846

Callers

nothing calls this directly

Calls 2

getcontextFunction · 0.85
setcontextFunction · 0.85

Tested by

no test coverage detected