HMS Surprise wrote: > Is there a way that a function may access the doc string or func_name > of the caller? > > Thanks, > > jvh >
Add a parameter to the function to avoid mutilating your code with implementation specific inspection: def fun(caller, *original_parameters): do_something_to_caller_without_magic(caller) do_something_with_original_parameters(*original_parameters) James -- http://mail.python.org/mailman/listinfo/python-list