Hacker News new | past | comments | ask | show | jobs | submit login

You're right about with(), which I'd forgotten about — JS with with() is not lexically scoped!

Access to the global object is still statically decidable. It just might raise an exception. This is not really different from Scheme.

I agree that block scope is a defining feature of Scheme's (and ALGOL's, and C's) approach to scope. However, Scheme's block scopes are all functions, at least if you accept the macro-definition of let that's been there since R5RS, rather than treating let as a separate primitive construct.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: