`has_side_effects()` does not take `typeof`'s magical power of not tripping over undeclared variable into account. fixes #1668
`has_side_effects()` does not take `typeof`'s magical power of not tripping over undeclared variable into account. fixes #1668