Metaprogramming
essays about the act and art of programming
higher level languages are built to help the programmer focus on higher
level ideas, protecting them from thinking about memory permissions, etc. this
is the case most of the time but all abstractions are at some point leaky given
our finite access to memory and compute.
javascript does not accomplish this; it merely shifts the
responsibilities of the programmer operating at lower levels of abstraction from
thinking about pointers, memory mapping, etc. to thinking about undefined, NaN
and object comparisons instead .
proper abstraction enables the programmer to think at a higher level;
javascript comes close before dragging the developer down with it
haskell doesnt work
macros involve evaluation: running program at compile time
requires running language inside compiler
places burden inside of language implementation to make life tricky
erlang vm has always supported continuously evaluating new code, unlike
haskell, which has to have a very strange embedded interpreter to work properly!
ghc templates might work better with better multi stage compilation?
macros in ruby are interesting:
[https://www.toptal.com/ruby/ruby-metaprogramming-cooler-than-it-sounds]
TODO programming tax
macro notes