Adding static typing to Python

Christian Tanzer tanzer at swing.co.at
Tue Feb 19 02:02:36 EST 2002


"Peter Milliken" <peter.milliken at gtech.com> wrote:

> The loose typing of Python is perceived as one of its big features :-).
> There are regular discussions on the usefulness of Python for "larger"
> projects. Many claim that they use it without any problems - I suspect that
> it is from a background of ignorance and lack of metrics i.e. how much time
> is lost in their projects to misnamed variables etc?

Your statement smacks of quite a bit of ignorance (not to mention the
arrogance involved).

> The only way in Python to find these is through (exhaustive) testing -
> such rigorous testing *requires* you to develop an exhaustive test
> suite that is capable of running periodically i.e. nightly etc to
> catch such errors.

I have to admit that I'm not yet using `exhaustive` testing. Still,
lack of static typing hasn't been a problem. I should add that I came
to Python with a strong belief in static typing and was quite a bit
worried about it in the beginning. It turned out to be a non-issue.

I even shed my long standing habit of using pre-/post-conditions and
invariants -- something I still consider indispensable for working in
Ada or C++.

> Whether the people who support Python for larger
> projects have the discipline within their project team to maintain
> such an effort is unclear - there has been no mention of it at all.

You seem to read only what is fitting into your preconceived notions.
XP and unit testing is brought up regularly in such discussions.

-- 
Christian Tanzer                                         tanzer at swing.co.at
Glasauergasse 32                                       Tel: +43 1 876 62 36
A-1130 Vienna, Austria                                 Fax: +43 1 877 66 92






More information about the Python-list mailing list