I wanted to add that you can use the vars command to investigate what objects and files you have been loading up:
so suppose you have:
CODE
import maya.precomp
and you want to know what mayaPrecomp is?
then do:
CODE
print vars(maya)["precomp"]
will result in maya sumarizing wher its atken form However please not somebody might hav injected code past you.
Theres aslternate tool in module sys called modules wich can investigate even unloaded bits and pieces, this probably reflect best how mayas whatIs does but for python modules, it of course doesnt do anything for functions:
CODE
import sys
sys.modules["maya.precomp"]