linux-man.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Rick Stanley <rstanley@rsiny.com>
To: "Michael Kerrisk (man-pages)" <mtk.manpages@gmail.com>
Cc: linux-man@vger.kernel.org
Subject: Re: Man page pre & post operators error
Date: Wed, 25 Sep 2019 18:53:32 -0400	[thread overview]
Message-ID: <c9d561ab9053da5e1e3a1d095001b39e2da88258.camel@rsiny.com> (raw)
In-Reply-To: <b26c24c2-63ae-bb99-4df9-653f9d33f20d@gmail.com>

Michael:

I have made the assumption that the current manpage operator table was
based on the C89/90 C Standard. This was a bad assumption!

Please throw out what I have sent and I will create a new more detailed
interpretation of the Draft Standards, with more detailed explanation.
I do not work with anything but the Draft Standards documents.  (With
one possible additional source. Will explain later)

Thanks!

Rick 

--
RSI (Rick Stanley, Inc.)
(917) 822-7771
www.rsiny.com
Computer  Consulting
Linux & Open Source Specialist
On Sep 25, 2019, at 4:08 PM, "Michael Kerrisk (man-pages)" <
mtk.manpages@gmail.com> wrote:
> Hello Rick,
> 
> (Im reflecting more.)
> 
> On 9/25/19 9:42 PM, Michael Kerrisk (man-pages) wrote:
> >  Hello Rick,
> >  
> >  On 9/25/19 5:23 PM, Rick Stanley wrote:
> > >  Hello again!
> > > 
> > >  In an effort to bring the current manpage for the C operator
> > > table up
> > >  to the current official Standard, I went back and compared the
> > > current
> > >  manpage operator table against the C99, C11, and C17(18) Draft
> > >  Standards documents.  I do not have access to the Official ISO C
> > >  Standards documents.
> > > 
> > >  I have attached a PDF to document my interpretation of the
> > > Standards
> > >  against the current `man operator` manpage
> > > 
> > >  In addition to the pre & postfix ++ & -- operators, I have found
> > > one
> > >  additional change & three additions to the table.  Because of
> > > these
> > >  appearing in 6.5.x, and A.2.1, I assume they should be included
> > > in the
> > >  operator table.
> > > 
> > >  The current table consists of 15 levels of precedence, C99 adds
> > > one new
> > >  level and C11 adds one more.
> > > 
> > >  (type) cast operator change
> > > 
> > >  In the current table, the cast operator is listed on level 2 of
> > > 15
> > >  levels, along with other operators.  In C99 this operator has
> > > been
> > >  demoted to a new level inserted between level 2 & 3 of the
> > > current
> > >  level, expanding the table to 16 levels of precedence.  I assume
> > > the
> > >  associativity is also "right to left", as is level 2.
> 
> How do you deduce that this changed between C89/90 and c99?
> I'm not so convinced now that '(type) cast' changed in precedence.
> 
> > >  _Generic operator/keyword addition
> > > 
> > >  This new operator/keyword was added in C11.  A new top level was
> > >  created and the remainder of the table has been demoted by one
> > > level.
> 
> But, is it really an operator? How do you deduce that?
> 
> > >  default operator/keyword addition
> > > 
> > >  This too has been added to the new top level in C11
> >  
> >  But, 'default' is not an operator as far as I can tell?
> >  (It is part of the '_Generic' construct, not an operator
> >  in its own right.)
> >  
> > >  _Alignof operator/keyword addition
> 
> This seems clearly correct to me, and I find other sources
> that agree on this.
> 
> My general problem is that I find no other sources
> that confirm your interpretation of the standard that _Generic
> is a new operator at a new level and that '(type) cast' has
> changed in precedence.
> 
> Thanks,
> 
> Michael
> 
-- 
RSI (Rick Stanley, Inc.)
(917) 822-7771
www.rsiny.com
Computer Systems Consulting
Linux & Open Source Specialists


  reply	other threads:[~2019-09-25 23:40 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-09-20 14:19 Man page pre & post operators error Rick Stanley
2019-09-20 17:00 ` Jakub Wilk
2019-09-22 21:01 ` Michael Kerrisk (man-pages)
2019-09-22 22:50   ` Rick Stanley
2019-09-23  7:43     ` Michael Kerrisk (man-pages)
2019-09-25 15:23     ` Rick Stanley
2019-09-25 19:42       ` Michael Kerrisk (man-pages)
2019-09-25 20:08         ` Michael Kerrisk (man-pages)
2019-09-25 22:53           ` Rick Stanley [this message]
2019-09-28 18:05         ` Manpage operator update Rick Stanley
2019-10-01 13:48         ` proposed patch to operator manpage Rick Stanley

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=c9d561ab9053da5e1e3a1d095001b39e2da88258.camel@rsiny.com \
    --to=rstanley@rsiny.com \
    --cc=linux-man@vger.kernel.org \
    --cc=mtk.manpages@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).