Aug-14-2019, 11:17 PM
Can you clarify what you want to do ? I do not understand the following:
Quote:i want to have class attribute names which could otherwise be used as variables be used for function referencesAs for your code, I don't think that the syntax you are using exists in Python. If you want to assign a function to a class attribute, you can do the following:
def myfunc(): print('my_func') class foo: func = myfunc foo.func()
Output:my_func