Remix.run Logo
taeric 3 days ago

I am not clear on why reaching for an existing compiler's AST would ever be top of list?

Don't get me wrong. I think many language design points should be used more. But starting from scratch makes a ton of sense. Skip the parsing stage and build up supported AST style constructs of your own.

Done simply, this is basically the command pattern. Keep execution separate from declaration and you should be fine?

Sure, you may want a parser for a dedicated serialization language some day. Hard to think you need start there?

But starting with the full AST of an existing language feels like a terrible idea. In any world.