4 ms·
There reason you don't see interfaces or abstract classes in Ruby or Python is because they are dynamically typed. Interfaces and abstract classes are byproduct
by lars 14y ago
There reason you don't see interfaces or abstract classes in Ruby or Python is because they are dynamically typed. Interfaces and abstract classes are byproducts that are required for Java and C#'s type systems to work. What use would you have for them in Ruby?
- zimbatm 14y agoI still reason in terms on interfaces when passing arguments to a function though (eg: argument X needs to behave like a string). It will later be verified in runtime and when running the tests but it's how I reason when structuring the code.
- viraptor 14y agoActually Zope.interfaces for Python are more popular than I expected. Not sure how I feel about it really. They're both annoying and useful.