typeof works for undefined variables now. fixes #2.