|
|
|
|
|
by mercurial
4558 days ago
|
|
I don't think you mean "python" in this list. Anyway, you're right most of the time, though you can end up in the same situation with "optimistic downcasting" (eg, get an Object as parameter, and downcast it to whatever it is you hope the concrete object is an instance of). |
|
> though you can end up in the same situation with "optimistic downcasting" (eg, get an Object as parameter
You can, though it doesn't happen much in practice. The complexity of the type systems (generics, interfaces, etc) are aimed in part at always allowing there to be a strong type.