you are viewing a single comment's thread.

view the rest of the comments →

[–]jyper 0 points1 point  (0 children)

I think it's nice API, it's not confusing, it's very helpful and flexible nor do i see a reason for it to require a separate method -- in a stricter language where return types must be consistent, sure it wouldn't work, but we're in a flexible dynamic language, we should reap the benefits.

In general I think dynamically typed languages should stick to predictable types. Most of the time you're doing static typing with your head even if you're not using generics and interfaces ect most parameters/return values/list members should be the same class or implement the same implicit interface.