3 ms·
I don't see that working very well. If you ever made a typo in a function name, the compiler would have to assume that you are referring to an external tool tha
by rgovostes 8y ago
I don't see that working very well. If you ever made a typo in a function name, the compiler would have to assume that you are referring to an external tool that would be available at runtime.
Swift gives the programmer a lot of flexibility in overriding operators, though, so one could probably make a decent DSL that approximates shell syntax.
- delinka 8y agoFor scripts, you're not compiling an executable that you'll run later, you're having Swift execute the code "now" so "available at runtime" becomes "immadiately after you parse the code."