ePolyglot: Examination and development of multilanguage programming using Eiffel, Python, and Haskell | ||
---|---|---|
Prev | Next |
Calling Python from Eiffel is only half of the Eiffel/Python story. It's equally important to be able to get some sort of interplay going on--in other words, to call Eiffel from within Python. By using SmallEiffel's CECIL library and another series of scripts, this can be accomplished in a relatively easy manner.
Up until now, we've discussed our ability to export Python functionality to Eiffel programs, allowing the elegant but static language Eiffel to experience some of the run-time extendibility and powerful libraries of Python. But it would be very useful if we could also do the reverse--allow Python code to manipulate Eiffel objects. This would allow true run-time extendibility of Eiffel programs--one has only to look at the pervasiveness of Microsoft's Visual Basic for Applications in its Office suite to see how useful (and dangerous!) this can be; in particular, Microsoft's Excel and Access applications (an extendible spreadsheet and relational database respectively) rely heavily on Visual Basic for Applications for much of their appeal. How, then, to export Eiffel functionality to Python?