4 ms·
> All we'd need is comments in header files with the extra type information encoded, and automated FFI would be possible. That’s SWIG. It’s something like 15 y
by masklinn 5y ago
> All we'd need is comments in header files with the extra type information encoded, and automated FFI would be possible.
That’s SWIG. It’s something like 15 years old, possibly more.
> building a type system on top of a language that lacks it is anything but easy, but it's possible. TypeScript is an excellent example.
That has nothing to do with the issue at hand. You can compile haskell to c, that does not help FFI-ing to unannotated C functions.
- DonHopkins 5y agohttps://en.wikipedia.org/wiki/SWIG https://en.wikipedia.org/wiki/SWIG >Initial release February 1996; 25 years ago http://www.swig.org/history.html http://www.swig.org/history.html >July, 1995. Dave develops SWIG while working in the Theoretical Physics Division at Los Alamos National Laboratory. Originally, it was conceived as an extension building tool for a customized scripting language that had been created for the Connection Machine 5. David Beazley, the author of SWIG, is a brilliant programmer, mad scientist, and excellent presenter. https://en.wikipedia.org/wiki/David_M._Beazley https://en.wikipedia.org/wiki/David_M._Beazley https://www.dabeaz.com/ https://www.dabeaz.com/ Check out his many talks about programming, especially his epic PyCon 2014 talk on his work as an expert on a patent infringement case. https://www.youtube.com/user/dabeazllc/videos https://www.youtube.com/user/dabeazllc/videos https://www.youtube.com/watch?v=RZ4Sn-Y7AP8 https://www.youtube.com/watch?v=RZ4Sn-Y7AP8 >David Beazley: Discovering Python - PyCon 2014 >So, what happens when you lock a Python programmer in a secret vault containing 1.5 TBytes of C++ source code and no internet connection? Find out as I describe how I used Python as a secret weapon of "discovery" in an epic legal battle. >Slides can be found at: https://speakerdeck.com/pycon2014 https://speakerdeck.com/pycon2014 and https://github.com/PyCon/2014-slides https://github.com/PyCon/2014-slides