4 ms·
I see both of those things a lot. The problem is if you aren't already familiar with those idea, the statements mean literally nothing. They basically don't mak
by jedimastert 7y ago
I see both of those things a lot. The problem is if you aren't already familiar with those idea, the statements mean literally nothing. They basically don't make sense.
- ken 7y agoThese examples aren't so far out there. DSLs exist in other languages. Statements exist in other languages. A programmer who has never used macros can imagine being able to create these, even if they have no idea what exactly that would look like in a Lisp program. That issue is also true of any game-changing technology you haven't used yet. If you hadn't used a personal computer, we could enumerate the features and advantages, but you probably wouldn't be able to truly appreciate it until you used one yourself.
- AlexCoventry 7y agoThey're also rarely useful things to do in regular software development.
- quickthrower2 7y agoI wonder if we struggle needlessly though in "regular software development" - and entire jobs or teams exist because we didn't find the right way to express things in a language. OTOH you could create lisp code that is so unique and weird in it's semantics that it's hard for a new team member to get onboard. But I've seen that done in C# too which allows you to have code that writes code at runtime (not as elegantly though!).
- AlexCoventry 7y agoYeah, writing your own language and self-modifying code can give you a lot of leverage, but usually they also make the code so much harder for other people to pick up that it's not worth it.
- FrozenVoid 7y agoThe idea is that all LISP code is data that is easily altered, essentially https://en.wikipedia.org/wiki/Abstract_syntax_tree https://en.wikipedia.org/wiki/Abstract_syntax_tree encapsulated in parens. LISP syntax is uniform,everything(functions,data,argument lists) is nested lists of lists like (list(list(list))), so that allows altering specific places "in-the-list"(place 1,2,3...) as form of meta-programming, where normal syntax FOR( A IN B) would be written roughly as (for a b) where for is used as a function taking 'a' and 'b' as parameters, but in this form(where 'for' is just the first element of the list) you can have functions that "alter-the-list" by example (replace-first-list-element (for a b) replacement-part) returns (replacement-part a b).