Re:Dart/Flutter now has macros/metaprogramming
by millsteed on Tuesday January 30, 2024 @07:13PM
(#39197928)
Yeah, it is. It inspired the reflection in Dart, which inspired the macros. You can only use Dart's reflection when running in VM mode though. Flutter apps use AOT compilation, due to tree-shaking, so you lose the reflection and fall back to having to run codegen - kind of like TypeScript -> JS. This is a nice improvement that is run in memory before compilation and allows better access to the AST.
[ Parent
| on HN ]
There are no comments on this comment yet.