This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# -*- coding: utf-8 -*- | |
from __future__ import unicode_literals | |
import re | |
import sys | |
def c(i): | |
""" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import dis | |
import inspect | |
class MethodMissingMixin: | |
def __getattr__(self, attr): | |
if hasattr(getattr(self, '__methodmissing__', None), '__call__'): | |
parent_frame = inspect.currentframe().f_back | |
instructions = dis.get_instructions(parent_frame.f_code) | |