Python from Wise Guy's Viewpoint
Marshall Spight
mspight at dnai.com
Thu Oct 23 03:15:09 EDT 2003
More information about the Python-list mailing list
Thu Oct 23 03:15:09 EDT 2003
- Previous message (by thread): Static typing
- Next message (by thread): Python from Wise Guy's Viewpoint
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
"Pascal Costanza" <costanza at web.de> wrote in message news:bn7a3p$1h6$1 at newsreader2.netcologne.de... > > I wouldn't count the use of java.lang.Object as a case of dynamic > typing. You need to explicitly cast objects of this type to some class > in order to make useful method calls. You only do this to satisfy the > static type system. (BTW, this is one of the sources for potential bugs > that you don't have in a decent dynamically typed language.) Huh? The explicit-downcast construct present in Java is the programmer saying to the compiler: "trust me; you can accept this type of parameter." In a dynamically-typed language, *every* call is like this! So if this is a source of errors (which I believe it is) then dynamically-typed languages have this potential source of errors with every function call, vs. statically-typed languages which have them only in those few cases where the programmer explicitly puts them in. Marshall
- Previous message (by thread): Static typing
- Next message (by thread): Python from Wise Guy's Viewpoint
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
More information about the Python-list mailing list