lotus

previous page: 2.5) What Is The Difference Between Static And Dynamic Typing? (Typing - Object-Oriented Technology)
  
page up: Object-Oriented Technology FAQ
  
next page: 2.7) What Is A Separation Between Type And Class (Representation)? (Typing - Object-Oriented Technology)

2.6) What Is This I Hear About ML And Functional Programming Languages? (Typing - Object-Oriented Technology)




Description

This article is from the Object-Oriented Technology FAQ, by Bob Hathaway rjh@geodesic.com with numerous contributions by others.

2.6) What Is This I Hear About ML And Functional Programming Languages? (Typing - Object-Oriented Technology)

ML, Metalanguage, is a functional programming language with a strongly typed
polymorphic type system [Wikstrom 87]. Russell (see Appendix E) is a more
recent functional language and Haskell [Hudak 92] provides a more modern and
"pure" example. Section 2.5 discusses why static typing has less power/
flexibility than dynamic typing and the same applies to ML (although see the
appendixes for an experimental dynamic extension to ML, Alcool-90 and [Cardelli
85] for a proper placement of ML's type system). ML doesn't use inheritance
for polymorphism; unlike OO languages, but provides the prototypical example of
parametric polymorphism, so no inheritance is required. This is "true" or
"pure" statically (or strongly) checked parametric polymorphism, by Strachey's
(and Cardelli and Wegner's) definitions.

Smalltalk is an example of a dynamically-typed language which does not check
types during assignment (and hence for parameters) and therefore provides
parametric polymorphism without static constraints (by Strachey's definition).
However, Smalltalk's style uses inclusion polymorphism in practise and
inheritance for subclassing (representation).

 

Continue to:













TOP
previous page: 2.5) What Is The Difference Between Static And Dynamic Typing? (Typing - Object-Oriented Technology)
  
page up: Object-Oriented Technology FAQ
  
next page: 2.7) What Is A Separation Between Type And Class (Representation)? (Typing - Object-Oriented Technology)