Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

> Don't think I've made this claim.

That's true, but it sounds a bit as if Lisp interpreters are something very unusual. The syntax and other details may differ, but the general idea of executing source code via an interpreter is very old, often implemented - similar also the idea that the code can be mutable. It's just not very fashionable, since some Lisp dialects are designed such that one wants the compiler to be able to statically check the code for various things, before runtime.

In Common Lisp we would not want to introduce variables into an outer scope by enclosed functions. One would explicitly set up a scope.

Example: this is a macro example, which creates a scope, where the matching match-variables are also Lisp variables.

    CL-USER 165 > (pmatch:when-match (append (coerce "hello" 'list)
                                             '(#$a)
                                             (coerce "ld" 'list))
                      (coerce "helloworld" 'list)
                      (length a))

    3


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

Search: