Article View: comp.lang.modula2
Article #585Re: m2 for scientific computation
From: Robert Frank
Date: Wed, 26 Aug 1992 06:26
Date: Wed, 26 Aug 1992 06:26
60 lines
3149 bytes
3149 bytes
In article <BtK7wI.MF3@ais.org> writes:
> In article <1992Aug25.170550.6706@sequent.com> tima@sequent.com (Timothy Alan
Anderson) writes:
> >
> >Modula2 is dead. It's a shame! I was just telling someone after looking at
> >a C++ example, "Luckily I learned Modula-2 first. I do all this stuff
> >allready, I just have to learn a different syntax".
> >
> >And let's all thank the Ada-2 folks for nailing the coffin shut...
> >
> >tima@sequent.com
>
> Right on, although Modula-2 is very much alive in many parts of the world,
> in the United States, it is dead. I too am glad that I learned M-2 before I
> learned C. I use many of the same principles I learned with M-2 in my C
> programming.
>
> One of the biggest complaints I stil have with M-2 is that the type checking
> is *too* strict.
>
> Why should I have to assign a pointer to an intermediate generic pointer,
> when I all I want to do is convert the type of my pointer?
>
Err, type casting is also possible in Modula-2!
> i.e.
> wordpointer = integer pointer;
> bytepointer = wordpointer;
> character pointer= bytepointer;
A good compiler should digest the following:
character pointer = ADDRESS(word word pointer);
Where 'word pointer' is simply casted (not converted) to type ADDRESS which is
asignable to all pointers.
>
> vs. C's character pointer = (char *) integer pointer;
>
> Oh well. I loved M-2 very much, except for the typechecking details. I am
> thankful that it taught me good style, but for me, M-2 will be a 'teaching'
.. let alone the syntacticall nesting of procedures...
> language, just like it's grandfather language, Pascal.
>
>
>
> ------------------////////////////////\\\\\\\\\\\\\\\\\\\\------------------
> | Patrick Draper Disclaimer: I can't control my fingers, |
> | draper@umcc.ais.org I can't control my toes! - Ramones |
> | University of Michigan |
> | Computer Club We are a nation of laws, not people |
> ------------------\\\\\\\\\\\\\\\\\\\\////////////////////------------------
--
Robert Frank tel. + (061) 321 99 67
Institut fuer Informatik fax + (061) 321 99 15
University of Basel, Switzerland
Mittlere Strasse 142 rfc822: frank@ifi.unibas.ch (NeXT mail accepted)
CH-4056 Basel X400: S=frank;OU=ifi;O=unibas;P=switch;A=arcom;C=ch
( if all fails try frank@urz.unibas.ch )
Technical Details
Message-ID:
<1992Aug26.062611.5114@urz.unibas.ch>Path:
arc1-ca.pugleaf.net!sparky!uunet!cs.utexas.edu!qt.cs.utexas.edu!yale.edu!ira.uka.de!chx400!urz.unibas.ch!lucy.ifi.unibas.ch!newsReferences:
<BtK7wI.MF3@ais.org>Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!sparky!uunet!cs.utexas.edu!qt.cs.utexas.edu!yale.edu!ira.uka.de!chx400!urz.unibas.ch!lucy.ifi.unibas.ch!news Newsgroups: comp.lang.modula2 Subject: Re: m2 for scientific computation Message-ID: <1992Aug26.062611.5114@urz.unibas.ch> From: frank@ifi.unibas.ch (Robert Frank) Date: Wed, 26 Aug 1992 06:26:11 GMT Reply-To: frank@ifi.unibas.ch Sender: news@urz.unibas.ch (USENET News System) References: <BtK7wI.MF3@ais.org> Organization: Institut fuer Informatik Nntp-Posting-Host: woodstock.ifi.unibas.ch Lines: 60