🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: net.lang.c
Article #9562

Re: Expression sequencing query

#9562
From: Wayne A. Christopher
Date: Wed, 15 Oct 1986 20:51
31 lines
2183 bytes
In article <483@jc3b21.UUCP>, fgd3@jc3b21.UUCP writes:
>      Your examples support my point: a _portable_ language is one which
> runs identically on all implementations.  A language which permits the code
> generated by its statements to be implementation-dependent is not portable.

A language can't be called portable, but programs written in that language
can.  A measure of how useful a language is how easy it is to write portable
code in it.  By your definition, you could call any language "non-portable"
because you can always (at least if the language is used for real things)
write code that determines what kind of processor it is running on.

> When dealing with a non-portable language (like C) ...

I know of no other (useful) language which is as easy to write portable code
in as C.  Most other common languages such as lisp suffer from a lack of
a standard such as K&R which all compilers follow (at least in theory).  (I
know, there is a lisp standard now...)

> But if portability is important to you--and
> I believe it should be--then it is a flaw in the language definition to
> permit the evaluation of statements which are syntactically correct to
> depend on the implementation.

Most of these cases where things are implementation-dependent are situations
where the hardware must dictate how things are to be done if they are to be
done in an optimal manner.  For instance, order of argument evaluation must
depend on the implementation because different machines like different
stack setups.  Anyway, there is 'lint', so it should be very easy to write
portable C code if you try.

	Wayne
Technical Details
Message-ID: <1092@ucbcad.BERKELEY.EDU>
Path: arc1-ca.pugleaf.net!utzoo!mnetor!seismo!think!nike!ucbcad!faustus
References: <111@titan.UUCP> <139200039@uiucdcsb> <483@jc3b21.UUCP>

Show Full Headers
Complete Article Headers
Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP
Path: arc1-ca.pugleaf.net!utzoo!mnetor!seismo!think!nike!ucbcad!faustus
From: faustus@ucbcad.BERKELEY.EDU (Wayne A. Christopher)
Newsgroups: net.lang.c
Subject: Re: Expression sequencing query
Message-ID: <1092@ucbcad.BERKELEY.EDU>
Date: Wed, 15-Oct-86 16:51:04 EDT
Article-I.D.: ucbcad.1092
Posted: Wed Oct 15 16:51:04 1986
Date-Received: Wed, 15-Oct-86 21:53:34 EDT
References: <111@titan.UUCP> <139200039@uiucdcsb> <483@jc3b21.UUCP>
Organization: CAD Group, U.C. Berkeley
Lines: 31