🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.std.c
Article #2613

Re: Unary plus

#2613
From: Doug Gwyn
Date: Wed, 27 Mar 1991 21:57
12 lines
1004 bytes
In article <370@ptcburp.ptcbu.oz.au> michi@ptcburp.ptcbu.oz.au (Michael Henning) writes:
>It basically states that the unary plus operator may be used to force
>a particular order of evaluation.

No, that was proposed in early drafts of the standard, but was dropped in
favor of requiring "honoring of parentheses" (a la Fortran) instead.

>If I want to enforce evaluation order by assigning to temporary variables, ...

Don't do that, use parentheses instead.
For finer-grained control you can use volatile, but that should not be
used merely to control subexpression evaluation order.
Technical Details
Message-ID: <15604@smoke.brl.mil>
Path: arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!rpi!uupsi!cmcl2!adm!smoke!gwyn
References: <370@ptcburp.ptcbu.oz.au>

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!rpi!uupsi!cmcl2!adm!smoke!gwyn
From: gwyn@smoke.brl.mil (Doug Gwyn)
Newsgroups: comp.std.c
Subject: Re: Unary plus
Keywords: unary plus, semantics of, order of evaluation
Message-ID: <15604@smoke.brl.mil>
Date: 27 Mar 91 21:57:52 GMT
References: <370@ptcburp.ptcbu.oz.au>
Organization: U.S. Army Ballistic Research Laboratory, APG, MD.
Lines: 12