[comp.object] Strong/Weak typing, polymorphism, languages, OO

nick@lfcs.ed.ac.uk (Nick Rothwell) (02/01/90)

I tried sending this reply directly back to Lawrence Mayka but it got
bounced back a week later from somewhere, so I hope Lawrence doesn't
mind if I continue this conversation here...

>I find it ironic that so many of the posted comments favorable to
>static typing cite ML, which itself is not a "conventional"
>language.  That is, few are publicly defending the static typing
>style of, say, C++.

I don't know too much about the static typing style of C++. I notice
however that you said "style" rather than "system". ML's type system
is essentially formal and mathematical, whereas the impression I get
about C++ is that it's defined in terms of lookup tables and things like
this, rather than semantically.

I think people cite ML in answer to generalisations people make about
strongly typed languages ("you have to specify all the types", "you
can't write a single function to build a list", and so on) which aren't
true, and ML is the convenient counter-example.

>In addition to the needs I've already described in my postings, my
>group's work requires a general-purpose, industrial-strength
>programming language and a first-class software development
>environment supported by a commercial vendor, (ideally) integrated
>with a synergistic operating system.

...which ML does not currently provide, although there are commercial
vendors working on this. ML is a very nice language with no support
environment to speak of, so you do need to know what you're doing to
put together large pieces of software. Not that the software will
be "buggy" otherwise, but rather that it will never typecheck. The fact
that ML is memory-safe avoids all those nasty discussions of aliasing,
stack overwriting, garbage memory values and so on (in fact, ML has
a formal execution semantics) which seem to be occupying the newsgroups
at the moment; the downside is the fact that ML systems require fairly
large machines, and that garbage collection isn't (yet) concurrent
with program execution.

>I hope that we can all resist or evade the C++ steamroller.

That isn't too much of a problem in Europe, I don't think; the US seems
to have a "systems" mentality to programming language design, and
so embraced the ideas behind C and then into C++. Here in Edinburgh
ML is the "systems" language (it's what we write all our code in),
although I currently have to use C when hacking on my Macintosh,
or for external consultancy work where there's no ML compiler, or
where instant response is important. The price for the "performance"
gains in writing in C is the faultiness of the final product...

Of course, ML isn't perfect and it's showing its age in one or two
places, so it's a shame that it's still seen as a bold new experimental
language in the US.

		Nick.
--
Nick Rothwell,	Laboratory for Foundations of Computer Science, Edinburgh.
		nick@lfcs.ed.ac.uk    <Atlantic Ocean>!mcvax!ukc!lfcs!nick
~~ ~~ ~~ ~~ ~~ ~~ ~~ ~~ ~~ ~~ ~~ ~~ ~~ ~~ ~~ ~~ ~~ ~~ ~~ ~~ ~~ ~~ ~~ ~~ ~~
		       ...als das Kind, Kind war...

peter@ficc.uu.net (Peter da Silva) (02/02/90)

In article <1933@castle.ed.ac.uk> nick@lfcs.ed.ac.uk (Nick Rothwell) writes:
> the downside is the fact that ML systems require fairly
> large machines...

> That isn't too much of a problem in Europe, I don't think; the US seems
> to have a "systems" mentality to programming language design...

It's not so much a programming language design issue, but rather that
fairly powerful personal computers have been readily available for 10 years
or more. The impression I've received from people in Europe is that
Europeans tend to have fewer computing resources at home, so that
languages that won't run reasonably on PCs are more acceptable. In the
US, a language that doesn't run on PCs (as, for example, Smalltalk hasn't
until fairly recently) is not going to get the popular support it might
in Europe. You *have* to take a "systems" approach when you want to work
with machines with a 64K to 640K of RAM, slow secondary storage, and clocks
starting at 2 MHz.
-- 
 _--_|\  Peter da Silva. +1 713 274 5180. <peter@ficc.uu.net>.
/      \
\_.--._/ Xenix Support -- it's not just a job, it's an adventure!
      v  "Have you hugged your wolf today?" `-_-'