Brian Allen Vanderburg II a écrit :
Okay so I don't really care about public/private but I was watching the
lists (Does python follow its idea of readability or something like
that) and I thought of a 'possible' way to add this support to the
language.
It has already been done at least a coup
There was a small error in setprivate/getprivate:
import sys
import inspect
def get_private_codes(class_):
codes = []
for i in class_.__dict__:
value = class_.__dict__[i]
if inspect.isfunction(value):
codes.append(value.func_code)
return codes
def get_protect
Okay so I don't really care about public/private but I was watching the
lists (Does python follow its idea of readability or something like
that) and I thought of a 'possible' way to add this support to the language.
I have implemented a class which allows creating both a private as well
as a