Article View: comp.std.c++
Article #707Re: Exponentiation operator proposal
From: Robert Corbett
Date: Thu, 15 Oct 1992 03:12
Date: Thu, 15 Oct 1992 03:12
23 lines
1582 bytes
1582 bytes
In article <1992Oct14.225725.16486@microsoft.com> jimad@microsoft.com (Jim Adcock) writes: >In article <23663@alice.att.com> bs@alice.att.com (Bjarne Stroustrup) writes: >>How frequent is a**p anyway? (has anyone got any data?) How confusing... > >I just ran a quick measurement on a convenient sample of 85,000 lines of >C and C++ code. Based on this sample "**" appears on average about once >per every 200 lines of code. This is a pretty high occurance. For comparison >"^" [XOR] appears on average once per 3000 lines of code! Based on this >measure I'd much rather see "^^" used for exponentiation, since the potential >for confusion would seem to be much much lower. Too bad "^" was misused to >mean XOR in the first place or the problem would be solved! I find it hard to believe that there are that many instances of multiplication following indirect referencing. How many of those instances of ** are of the form /* ** Commentary */ ? Yours truly, Robert Corbett
Technical Details
Message-ID:
<ldpoc1INNbe7@exodus.Eng.Sun.COM>Path:
arc1-ca.pugleaf.net!sparky!uunet!charon.amdahl.com!pacbell.com!ames!sun-barr!news2me.EBay.Sun.COM!exodus.Eng.Sun.COM!lupa.Eng.Sun.COM!corbettReferences:
<1992Sep13.193507.27813@ima.isc.com> <BuJJxs.8Hx@world.std.com> <23663@alice.att.com> <1992Oct14.225725.16486@microsoft.com>Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!sparky!uunet!charon.amdahl.com!pacbell.com!ames!sun-barr!news2me.EBay.Sun.COM!exodus.Eng.Sun.COM!lupa.Eng.Sun.COM!corbett From: corbett@lupa.Eng.Sun.COM (Robert Corbett) Newsgroups: comp.std.c++,comp.lang.c++ Subject: Re: Exponentiation operator proposal Date: 15 Oct 1992 03:12:01 GMT Organization: Sun Microsystems, Mt. View, Ca. Lines: 23 Message-ID: <ldpoc1INNbe7@exodus.Eng.Sun.COM> References: <1992Sep13.193507.27813@ima.isc.com> <BuJJxs.8Hx@world.std.com> <23663@alice.att.com> <1992Oct14.225725.16486@microsoft.com> NNTP-Posting-Host: lupa