4 ms·
Because if you're scripting something out, it's very possible that you'll need to run it outside of a Mac in no time. Yes, it's still early, but with Swift bec
by dottrap 11y ago
Because if you're scripting something out, it's very possible that you'll need to run it outside of a Mac in no time.
Yes, it's still early, but with Swift becoming open source, the portability problem will probably become less of an issue.
Plus, there's no decent dependency management yet and you can't compare the amount of external libraries commonly used for scripting with languages like Python or Ruby.
Thinking about this, I wonder if it is actually as big of a problem as some may think. Swift has built-in automatic bridging capabilities to both C and Objective-C. Assuming this works the same in the REPL/command line (I haven't verified this), then you can directly call every system library on your platform that is written in C or Obj-C (which is all of them). The need to download external modules like in Python or Ruby seems greatly diminished.
And to the portability question, on a Unix platform in general, the majority of libraries available for the platform are C libraries with all the capabilities you normally would have to get as a separate module for Python or Ruby. Since this is all directly available without separate modules, when you do need a feature not installed on your system, you would simply install a C library with that capability through your system's normal packaging management system or build/compile it yourself.