3 ms·
> Code is not data Lisp would, of course, disagree. :-)
by AsyncAwait 8y ago
> Code is not data
Lisp would, of course, disagree. :-)
- ArneBab 8y ago(import (ice-9 match)) (define data '(display code)) (define code (let ((pe primitive-eval)) (match data ((fun arg ...) (lambda () (apply (pe fun) arg)))))) (code)
- Spivak 8y agoLisp recognizes that the difference between code and data is the context they're interpreted in. A more accurate phrasing of "code is not data" should be, "data from untrusted sources should not be interpreted as code".