|
|
|
|
|
by kasey_junk
3372 days ago
|
|
There is nothing language specific or magic about those things. You could (and you will see people) write those things in go as the language starts getting more adoption. Go goes further and encourages code gen, so that will probably be the way you start seeing terrible frameworks being built. In any case, "configuration as code" doesn't seem like a good definition of "magic" to me. |
|
Also, if load-time aspect-weaving and classpath-scanning-based autodiscovery don't count as magic to you, then not much will. Code generation at least has the huge, huge, humongous advantage that you have code on disk that you can read and debug.
I also admire Racket's macro system for coming with IDE support for introspecting and debugging the code generated by macros. Macros are a much better design because they generally run at compile time and they generally only make local code transformations that are much easier to reason about, as opposed to the sweeping global changes a weaver will make.