Type feedback tool?

Martin Vilcans martin at librador.com
Sun Oct 26 08:54:13 EDT 2008


Hi list,

I'm wondering if there's a tool that can analyze a Python program
while it runs, and generate a database with the types of arguments and
return values for each function. In a way it is like a profiler, that
instead of measuring how often functions are called and how long time
it takes, it records the type information. So afterwards, when I'm
reading the code, I can go to the database to see what data type
parameter "foo" of function "bar" typically has. It would help a lot
with deciphering old code.

When I googled this, I learned that this is called "type feedback",
and is used (?) to give type information to a compiler to help it
generate fast code. My needs are much more humble. I just want a
faster way to understand undocumented code with bad naming.

-- 
martin at librador.com
http://www.librador.com



More information about the Python-list mailing list