comp.lang.ada
 help / color / mirror / Atom feed
From: seas.gwu.edu!mfeldman@uunet.uu.net  (Michael Feldman)
Subject: Re: FORTRAN bug(was Re: C++ vs. Ada -- Is Ada loosing?)
Date: 9 Dec 92 06:02:18 GMT	[thread overview]
Message-ID: <1992Dec9.060218.23940@seas.gwu.edu> (raw)

In article <1992Dec8.172551.16780@newshost.lanl.gov> jlg@cochiti.lanl.gov (J. G
iles) writes:

[stuff deleted]
>
>Well, not quite.  The proper moral is that all programming languages
>(even informal specification languages) have contexts in which single
>character errors can lead to linguistically correct programs which
>don't compute the intended functionality.  The moral often stated
>instead is that this is a bad feature of Fortran.  While Fortran
>could indeed have been designed better, it is not the only language
>with, or even the most severly affected by, this kind of problem.
>
You make a good point. Perhaps the modern equivalent of that Fortran
single-keystroke bug is my favorite bit of C code (and no, I don't
want to bash C, just point out how common these flukes are):

   int x;
   ...
   x = 1;
   while (x <= 10);
   { 
      printf("%d\n", x);
      x++;
   }

For 10 points on your grade: what is printed? Why?
Try explaining it to a freshman.

Any similar idiosyncracies in Ada? 

Mike Feldman
------------------------------------------------------------------------
Michael B. Feldman
co-chair, SIGAda Education Committee

Professor, Dept. of Electrical Engineering and Computer Science
School of Engineering and Applied Science
The George Washington University
Washington, DC 20052 USA
(202) 994-5253 (voice)
(202) 994-5296 (fax)
mfeldman@seas.gwu.edu (Internet)

"Americans want the fruits of patience -- and they want them now."
------------------------------------------------------------------------

             reply	other threads:[~1992-12-09  6:02 UTC|newest]

Thread overview: 25+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1992-12-09  6:02 Michael Feldman [this message]
  -- strict thread matches above, loose matches on Subject: below --
1992-12-18 21:56 FORTRAN bug(was Re: C++ vs. Ada -- Is Ada loosing?) Michael Feldman
1992-12-18  9:22 agate!spool.mu.edu!uwm.edu!zaphod.mps.ohio-state.edu!caen!uvaarpa!vger.ns
1992-12-16 17:40 Pascal Obry
1992-12-16 16:02 fred j mccall 575-3539
1992-12-15 16:36 enterpoop.mit.edu!bloom-picayune.mit.edu!mintaka.lcs.mit.edu!ogicse!uwm.e
1992-12-15  2:57 Michael Feldman
1992-12-15  2:43 Michael Feldman
1992-12-14 22:15 John Bollenbacher
1992-12-14 18:33 J. Giles
1992-12-14 17:04 agate!spool.mu.edu!yale.edu!qt.cs.utexas.edu!cs.utexas.edu!csc.ti.com!til
1992-12-14 17:00 agate!spool.mu.edu!sdd.hp.com!zaphod.mps.ohio-state.edu!cs.utexas.edu!csc.ti.com!tilde.csc.ti.com!mksol!mccall
1992-12-14 16:55 agate!spool.mu.edu!sdd.hp.com!zaphod.mps.ohio-state.edu!cs.utexas.edu!csc.ti.com!tilde.csc.ti.com!mksol!mccall
1992-12-12 17:53 Michael Feldman
1992-12-12 14:34 Fergus Jam es HENDERSON
1992-12-12 14:20 Fergus Jam es HENDERSON
1992-12-12  6:04 Bob Kitzberger
1992-12-12  0:42 Pascal Obry
1992-12-11 23:22 Tucker Taft
1992-12-11 22:24 John Nestoriak III
1992-12-11 21:31 Michael Feldman
1992-12-11 21:04 Tucker Taft
1992-12-11 15:38 Robb Nebbe
1992-12-11 13:29 agate!spool.mu.edu!uwm.edu!cs.utexas.edu!csc.ti.com!tilde.csc.ti.com!mkso
1992-12-08 17:25 J. Giles
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox