Path: csiph.com!eternal-september.org!feeder.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail From: Keith Thompson Newsgroups: comp.lang.c Subject: Re: double free Date: Wed, 13 Jul 2016 13:02:04 -0700 Organization: None to speak of Lines: 42 Message-ID: References: <57837892.8808984@news.xs4all.nl> <481f30b4-acb3-4445-92b3-c403dc3e51f7@googlegroups.com> <8760sc2aiz.fsf@bsb.me.uk> <57856cf1.441531@news.xs4all.nl> <9cfaefc2-92a1-4e03-aa6b-d071a0988c87@googlegroups.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Injection-Info: mx02.eternal-september.org; posting-host="945944de09706c9b4e29b53c9d2efdc2"; logging-data="12944"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1/SfU9+nfY1/oKU7YgSgJgg" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.1 (gnu/linux) Cancel-Lock: sha1:j/U72sE/wBDERstB5RRiXRxCMF0= sha1:FO2+pPpUuvXuGI6XmISRFzteB2Q= Xref: csiph.com comp.lang.c:90345 Richard Heathfield writes: > On 13/07/16 15:11, BartC wrote: >> On 13/07/2016 13:57, Richard Heathfield wrote: >>> On 13/07/16 13:41, BartC wrote: >> >>>> I still think that using * for deference, for multiply and for >>>> 'pointer-to' was a bad idea. The fact that C isn't going to change that >>>> doesn't mean I'm completely wrong. >>> >>> In C, they work fine, and in C, you're completely wrong. >> >> A**B doesn't mean raise A to power B, > > Why on earth would it? Why not? There are a number of languages that use ** as the exponentiation operator (Ada, Perl, Python, Ruby). And when I use those languages, the fact that ** means exponentation has never been a problem for me. All symbols are ultimately arbitrary. I'd say the fact that mathematical notation uses superscript for exponentiation is more arbitrary than the use of ** (or ^, or whatever). It only seems less arbitrary because it happens to be older. [...] > Every language has compromises. We know what C's are. They're a little > quirky, but they don't cause any problems to anyone who knows the language. Agreed. I consider it *slightly* inconvenient that we can't add "**" as an exponentation operator in a future version of C, or as an extension, because `x**y` already has a meaning. (For example, with an integer right operand `x**2` could be substantially more efficient than `pow(x, 2)`, while avoiding possible rounding errors.) But it's not that big a deal. ("^^" is available, but I'm not holding my breath.) -- Keith Thompson (The_Other_Keith) kst-u@mib.org Working, but not speaking, for JetHead Development, Inc. "We must do something. This is something. Therefore, we must do this." -- Antony Jay and Jonathan Lynn, "Yes Minister"