comp.lang.ada
 help / color / mirror / Atom feed
* Language wars
@ 1992-12-12 16:39 What? Me Ada?
  0 siblings, 0 replies; 5+ messages in thread
From: What? Me Ada? @ 1992-12-12 16:39 UTC (permalink / raw)


Furgus Henderson posts:
>mfeldman@seas.gwu.edu (Michael Feldman) writes:

>>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++;
>>   }

>A good compiler would give a warning that the call to printf was
>unreachable code. The only compiler I have available, gcc, unfortunately
>doesn't give any such warning. But the Pascal-subset compiler I wrote (as one
>of the projects for a 3rd-year subject) gives the following warnings for
>the equivalent Pascal code:

>warning: variable 'x' is not used after assignment, so assignment has no effec
t
>warning: 'while' statement will cause an infinite loop

I would submit that neither of these warnings is completely correct for this
particular example, at least without further qualification.  'x' is, in fact,
used after assignment, although both the assignment and the subsequent use
could be optimized away.  If they are, the compiler should state that in the
warning.  If not, no warning should be given.  If you really put the
offending semicolon in by accident, but the program compiled OK anyway, even
with the warning, you'd say "Of course it's used.  Compiler bug." then get in
there with a debugger and wonder why you couldn't find 'x' or any code
associated with it.  The warning about the infinite loop should only be given
if the compiler supports the "volatile" storage class modifier.  Most do, and
I think the ANSI standard requires it, but not all compilers support it just
the same, or just ignore it.  The result is something outside the current
context could change the value of x and terminate the loop.

On the life cycle cost controversy:  While, as somebody recently pointed out,
statistics can be cooked up any way you want them, even a good cook can't
cook without ingredients.  The typical life cycle of a military system is
about 20 years, probably to grow a bit as time goes on.  I'm not sure what
the oldest fielded Ada based system is right now, but it couldn't be over
four or five years old.  Anybody who attempts to compare life cycle cost can
only do so based on speculation.

----------------------------------------------------------------------------
| Malcolm Petcher                    | Coming soon to this location:       |
| Petcher@m2000.dseg.ti.com          | some fancy disclaimer that keeps    |
| Malcolm Petcher @ V'ger            | me from getting fired               |
----------------------------------------------------------------------------

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Language Wars
@ 1996-09-05  0:00 Roy Gardiner
  1996-09-05  0:00 ` Jay McFadyen
  0 siblings, 1 reply; 5+ messages in thread
From: Roy Gardiner @ 1996-09-05  0:00 UTC (permalink / raw)



The debate on PL/I vs ADA seems to be becoming a little heated, so to 
inject a little levity here is the 'language preference survey'

About as scientific as Mystic Meg, it should cast some light on how we 
would like to work. Send an e-mail to me 
gardinerr@dcslambert.agw.bt.co.uk) indicating your 'favourite' languages, 
in order 1 to 4 (or less, if you only like 1 or 2 languages).If I get any 
response at all, I will repost the results from time to time in a grid 
like this:

The Language Preference Grid

           1   2   3   4
|--------|---|---|---|---|
| pli    | 0 | 0 | 0 | 0 |
| Rexx   | 0 | 0 | 0 | 0 |
| ada    | 0 | 0 | 0 | 0 |
| c      | 0 | 0 | 0 | 0 |
| c++    | 0 | 0 | 0 | 0 |
| pascal | 0 | 0 | 0 | 0 |
| fortran| 0 | 0 | 0 | 0 |

etc.


Rule: 

1) You may not vote for the language you learned first as no. 1. So 
'everyone always loves their first language' is eliminated.

2) You may only vote for languages where you have good practical 
experience


Game for a laugh, Roy Gardiner





^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Language Wars
  1996-09-05  0:00 Language Wars Roy Gardiner
@ 1996-09-05  0:00 ` Jay McFadyen
  1996-09-05  0:00   ` Dave Jones
  0 siblings, 1 reply; 5+ messages in thread
From: Jay McFadyen @ 1996-09-05  0:00 UTC (permalink / raw)



pl1	1
pascal	2
c++	3++
cobol	4	(GACK!  They're makeing me say "GACK")
-- 
Jay McFadyen
Development Tools and Infrastructure, C2PSD, Ford Motor Company
mcfadyen@cadcam.pd9.ford.com or JMCFADYE
(313) 33-73359




^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Language Wars
  1996-09-05  0:00 ` Jay McFadyen
@ 1996-09-05  0:00   ` Dave Jones
  1996-09-06  0:00     ` Larry Kilgallen
  0 siblings, 1 reply; 5+ messages in thread
From: Dave Jones @ 1996-09-05  0:00 UTC (permalink / raw)



OK< here's my vote on the matter...:-)

PL/I    -- 1
Rexx    -- 2
PL/X    -- 3
Fortran -- 4

(for those of you with an IBM S/390 background, PL/X is a "PL/I like" 
system development language withsome OO features and direct access to
the S/390 assembler instructions....very cool. )

Dave Jones
Velocity Software
Houston, TX  77084







^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Language Wars
  1996-09-05  0:00   ` Dave Jones
@ 1996-09-06  0:00     ` Larry Kilgallen
  0 siblings, 0 replies; 5+ messages in thread
From: Larry Kilgallen @ 1996-09-06  0:00 UTC (permalink / raw)



Somebody wrote:

> OK< here's my vote on the matter.

No ! No ! No !

Please, people _MAIL_ your votes to the originator of the thread
for eventual summmary.  Do not pollute the multiple newsgroups
to which the topic was posted with individual ballots.

Larry Kilgallen




^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~1996-09-06  0:00 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
1992-12-12 16:39 Language wars What? Me Ada?
  -- strict thread matches above, loose matches on Subject: below --
1996-09-05  0:00 Language Wars Roy Gardiner
1996-09-05  0:00 ` Jay McFadyen
1996-09-05  0:00   ` Dave Jones
1996-09-06  0:00     ` Larry Kilgallen

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