Skip to content

Instantly share code, notes, and snippets.

@iddoeldor
Forked from zoriankazinski/a.py
Created May 20, 2020 17:21
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save iddoeldor/1a18af55d0c4ac9a0627bb90ab10d551 to your computer and use it in GitHub Desktop.
Save iddoeldor/1a18af55d0c4ac9a0627bb90ab10d551 to your computer and use it in GitHub Desktop.
def _masquerade(self,origin):
self.__class__ = type(origin.__class__.__name__,(self.__class__,origin.__class__),{})
self.__dict__ = origin.__dict__
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment