|
|
|
|
|
by valenterry
2050 days ago
|
|
> Because the framework is working on a level above the application, it can easily deal with objects without worrying about what is inside them. Even for that there is no need for dynamic typing anymore. This problem has been solves with type parameters (aka generics) and type-classes. |
|
In Python and Ruby it's an extremely common pattern to return a dictionary with a half-dozen entries at most that will be consumed at a single location.
Defining an entire class for this sort of extremely common use case is for the most part a waste of time.
These languages allow for the formalization of those types by creating classes out of them, but looking at what 50% of my functions do in web dev code, they're returning tuples, small dictionaries, or standard library objects.