Is this possible in Python? SOLUTION FOUND
alainpoint at yahoo.fr
alainpoint at yahoo.fr
Tue Mar 14 07:43:40 EST 2006
jalanb wrote:
> You might like the version here:
> http://www.jorendorff.com/toys/out.html
>
> Especially the "need to know" presentation, which is cute
>
> --
> Alan
> http://aivipi.blogspot.com
Thank you for the tip.
Meanwhile, I found a shorter solution to my problem:
def magic(arg):
import inspect
return inspect.stack()[1][4][0].split("magic")[-1][1:-1]
assert magic(3+4)=="3+4"
Alain
More information about the Python-list
mailing list