Dump: Fix `typeof` sub-check for `window`

Fixes #631.