22 ms·
(@lispm Looks like our symbolic language flame war has exceeded yc metrics) Yes, I understand what ' does. You are manually controlling evaluation. The same wa
by programnature 16y ago
(@lispm Looks like our symbolic language flame war has exceeded yc metrics)
Yes, I understand what ' does. You are manually controlling evaluation. The same way, once upon a time, people manually controlled garbage collection.
Having a+a explode by default means that the whole time you have to be juggling what is intended to be used symbolically or not. This seems to not be a 100% perfect realization of the code == data paradigm.
I'm glad you now agree that structure is a good way to encode meaning. Now, what is a more idiomatic way to manipulate that information? Walking the tree manually, or expressing those patterns of structure directly?
Unfortunately, in Lisp, you need to "evaluation manage" those structures. And its not just quote, its the whole macro language with its own idiosyncrasies. Its just a lot easier to have a single elegant system with the right defaults.
I'm the kind of person who implements models of computation as a recreational activity. I've probably wished for more granular evaluation control 1% of the time, but having civilized pattern matching (and representation) has vastly increased productivity and code density.
- lispm 16y agoI haven't said anything about encoding of meaning, you are dreaming. You are the kind of person of Xah Lee...
- deleted 16y ago[deleted]
- silentbicycle 16y agoDo you know Prolog? It sounds like it might appeal to you. Rather than evaluating expressions, it does pattern matching (unification, really) on data structures, rewriting and evaluating them as specified. It can pass around uninstantiated variables and do depth-first search* through known facts/rules to find complete matches, backtracking when it hits dead ends or alternative solutions are requested. Rather than saying Prolog has pattern matching, it almost makes more sense to say it is pattern matching. It's very central to its model of computation. * Breadth-first and other search techniques are easy to write, depth-first is just the default.
- jjs 16y agoYes, I understand what ' does. You are manually controlling evaluation. The same way, once upon a time, people manually controlled garbage collection. Having a+a explode by default means that the whole time you have to be juggling what is intended to be used symbolically or not. This seems to not be a 100% perfect realization of the code == data paradigm. I don't think you've thought this through. If (+ a a) evaluated to (+ a a), then code would not be data, because there would be no code, only data. There is a compiler for this ideal, pure-declarative language: it's called cat. Alternatively, you could have a separate bracket type for evaluation, but that doesn't solve your complaint. Unfortunately, in Lisp, you need to "evaluation manage" those structures. And its not just quote, its the whole macro language with its own idiosyncrasies. The macro language is called Lisp. Its just a lot easier to have a single elegant system with the right defaults. If you don't grasp macros, then Lisp will seem useless to you. This is actually the origin of the term Blub. I'm the kind of person who implements models of computation as a recreational activity. I've probably wished for more granular evaluation control 1% of the time, but having civilized pattern matching (and representation) has vastly increased productivity and code density. I'm the kind of person who implements working Lisps as a recreational activity. I guarantee you that adding a (def/pat ) pattern matching function definition form is just a macro away (and already exists in some Lisps). At that point, you don't need to manually quote your patterns, which I believe addresses the remainder of your objections.