🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.std.c
Article #5138

Re: nonportable code or incorrect compilers?

#5138
From: Doug Gwyn
Date: Sat, 25 Jun 1988 05:34
14 lines
1123 bytes
In article <133@daitc.ARPA> jkrueger@daitc.ARPA (Jonathan Krueger) writes:
>My prediction, based on K&R, was the output:
>	count is 800, now 839
>Indeed, the Pyramid 98x produces exactly this output.
>But your mileage may vary.  4.2BSD VAX, Gould, and Sun-3 produce output:
>	count is 800, now 800

There is no ambiguity; the Pyramid has produced the correct answer
and the other three compilers are wrong.  The SVR2 VAX PCC also gets
this right, so presumably all recent 3B CCSes do also.

The code is "portable" to correct compilers.  Obviously it is not
"portable" to ALL compilers, as you have shown.  Nag your system
vendors to fix their compilers.
Technical Details
Message-ID: <8156@brl-smoke.ARPA>
Path: arc1-ca.pugleaf.net!utzoo!attcan!uunet!husc6!mailrus!ames!nrl-cmf!cmcl2!brl-adm!brl-smoke!gwyn
References: <133@daitc.ARPA>

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!attcan!uunet!husc6!mailrus!ames!nrl-cmf!cmcl2!brl-adm!brl-smoke!gwyn
From: gwyn@brl-smoke.ARPA (Doug Gwyn )
Newsgroups: comp.std.c
Subject: Re: nonportable code or incorrect compilers?
Keywords: portable language standard
Message-ID: <8156@brl-smoke.ARPA>
Date: 25 Jun 88 05:34:00 GMT
References: <133@daitc.ARPA>
Reply-To: gwyn@brl.arpa (Doug Gwyn (VLD/VMB) <gwyn>)
Organization: Ballistic Research Lab (BRL), APG, MD.
Lines: 14