j***@gmail.com
2010-01-12 08:18:42 UTC
Today I came across this very old post (1/6/2005) of Guido van Rossum
"Optional Static Typing -- Stop the Flames!"
http://www.artima.com/weblogs/viewpost.jsp?thread=87182
which discusses optional static typing of Python. It particularly
interests me because I've been searching for a language that's
statically typed to take advantages of the error checking features
of compilers and IDEs (as well as many other features provided by
IDEs, e.g. refactoring), while also has the power of Python. I'm
not sure if it's eventually implemented or not. I checked Python 2.5
command line options but didn't find anything that's related to
static typing.
However, because of the flexibility of dynamic typing, Python code
is too easy to break (typos typos!). (I know I can always write
more unit tests for my code but I can't be convinced that unit tests
can replace the help of compiler and IDE.) Many times I ended up
rewriting Python projects in Java when they get big.
But Java doesn't really satisfy me because of its verbosity. So
I was on the lookout for a language that has the benefit of both
worlds. I have recently tried Scala for a concise and statically typed
language. It has a very powerful type system and it is much more
concise than Java. However, its syntax looks quite cryptic, especially
for new users. After playing with Scala for a short while, I miss
Python's simple but powerful syntax a lot. And I certainly miss the
"Zen of Python" (http://www.python.org/dev/peps/pep-0020/) a lot.
I believe many others are in the same boat.
After reading GvR's article, I come to think that maybe Jython with
(optional) static typing is the answer, with the added benefit of
running on the powerful JVM platform. I guess at this point this
is no more than wishful thinking but who knows. I understand at
this point improving Python compatibility is the main goal of Jython
development but maybe having a statically typed Jython is even more
useful to developers :)
"Optional Static Typing -- Stop the Flames!"
http://www.artima.com/weblogs/viewpost.jsp?thread=87182
which discusses optional static typing of Python. It particularly
interests me because I've been searching for a language that's
statically typed to take advantages of the error checking features
of compilers and IDEs (as well as many other features provided by
IDEs, e.g. refactoring), while also has the power of Python. I'm
not sure if it's eventually implemented or not. I checked Python 2.5
command line options but didn't find anything that's related to
static typing.
However, because of the flexibility of dynamic typing, Python code
is too easy to break (typos typos!). (I know I can always write
more unit tests for my code but I can't be convinced that unit tests
can replace the help of compiler and IDE.) Many times I ended up
rewriting Python projects in Java when they get big.
But Java doesn't really satisfy me because of its verbosity. So
I was on the lookout for a language that has the benefit of both
worlds. I have recently tried Scala for a concise and statically typed
language. It has a very powerful type system and it is much more
concise than Java. However, its syntax looks quite cryptic, especially
for new users. After playing with Scala for a short while, I miss
Python's simple but powerful syntax a lot. And I certainly miss the
"Zen of Python" (http://www.python.org/dev/peps/pep-0020/) a lot.
I believe many others are in the same boat.
After reading GvR's article, I come to think that maybe Jython with
(optional) static typing is the answer, with the added benefit of
running on the powerful JVM platform. I guess at this point this
is no more than wishful thinking but who knows. I understand at
this point improving Python compatibility is the main goal of Jython
development but maybe having a statically typed Jython is even more
useful to developers :)
--
Best regards,
Jack
Best regards,
Jack