Hmm... May be I misunderstood something
Hmm... May be I misunderstood something
Posted Jul 18, 2009 10:47 UTC (Sat) by bockman (guest, #3650)In reply to: Hmm... May be I misunderstood something by khim
Parent article: Unladen Swallow 2009Q2 released
And I don't think that in a dynamic language one has to do explicit unit test for wrong parameter types : misusage of a function is bound to trigger some exception or make anyway fail the test. The resulting error message might not be the most informative, but usually lead you to the original problem. What you have to do is ensure full code coverage, which is a good practice also in statically-typed languages.
Not that I would dislike having more compiler-time checks in python: there are tools that help with that, and maybe they will help more in the future making clever usage of python3 annotations.
Ciao
------
FB
