3 ms·
> We see that languages like Perl and Python have huge numbers of libraries for doing all sorts of tasks. Those libraries are only accessible through the progra
by metadat 2y ago
> We see that languages like Perl and Python have huge numbers of libraries for doing all sorts of tasks. Those libraries are only accessible through the programming language they were developed for. This is a missed opportunity for the languages to interoperate synergistically with the rest of the Unix ecosystem.
What would this interoperability look like, in practical terms?
For example, how would you invoke a program in language A from language B, other than the typical existing `system.exec(...)'.
- jeremyjh 2y agoIts nonsense. They interoperate just as well as any other programs in UNIX. You can pipe stdin to them, pipe their output to other programs, or invoke the shell or other programs. The fact that they have libraries that don't require integration through text streams doesn't take anything away from the text processing interfaces and programs. Shell scripts have their place, and UNIX is beautiful, but that doesn't mean everything has to work this way.
- ColonelPhantom 2y agoIt's not nonsense; the point is that calling a Numpy function needs to be done from Python. You cannot pipe stdin to np.array().
- jeremyjh 2y agoYes exactly, and you shouldn't complain that Numpy isn't directly available to perl and grep. I think we're in agreement.
- paulddraper 2y agoThe author is saying these libraries expose Perl/Python/etc functions, that can only be invoked by Perl/Python/etc code. Whereas Unix functions (programs) can be invoked by any programming language. --- The C ABI would be a second place, as many languages can interact with it.