All of lore.kernel.org
 help / color / mirror / Atom feed
From: Philippe Gerum <rpm@xenomai.org>
To: dietmar.schindler@manroland-web.com
Cc: xenomai@xenomai.org
Subject: Re: [Xenomai] Segfaults and ENOMEM during rt_event_create()
Date: Thu, 6 Aug 2015 17:12:29 +0200	[thread overview]
Message-ID: <55C3795D.5000703@xenomai.org> (raw)
In-Reply-To: <208C6975C932E94F86239FEA59CCA632E0D9E8A1@AUSMXMBX02.mrws.biz>

On 08/06/2015 11:25 AM, dietmar.schindler@manroland-web.com wrote:
>> Von: Philippe Gerum
>> Gesendet: Donnerstag, 6. August 2015 10:01
>>
>> ..., but the ternary operator is a bit special since by
>> design, it won't compete for precedence with the expressions it evaluates.
> 
> Actually, this is not special - no operator will "compete for precedence with the expressions it evaluates", because _which_ expressions it evaluates is determined by the very outcome of the "competition for precedence". And sure enough, the expression
> 
>     b = a ? 0 : 1
> 

I would tend to think that associativity is part of the issue. e.g.
right association solves the ambiguity between multiple assignments
operators with the same precedence.

> is not equivalent to
> 
>     (b = a) ? 0 : 1
> 
> (but by this remark I do not at all want to advocate the undue use of parentheses).
> 

Clearly. This said, the original remark was rather about the precedence
between operators from the test expression and the operators forming the
ternary conditional itself.

-- 
Philippe.


  reply	other threads:[~2015-08-06 15:12 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-08-05 13:09 [Xenomai] Segfaults and ENOMEM during rt_event_create() Charles Kiorpes
2015-08-05 15:42 ` Philippe Gerum
2015-08-05 16:34   ` Charles Kiorpes
2015-08-06  7:42     ` Philippe Gerum
2015-08-05 17:24   ` Gilles Chanteperdrix
2015-08-06  7:40     ` Philippe Gerum
2015-08-06  7:49       ` Gilles Chanteperdrix
2015-08-06  8:00         ` Philippe Gerum
2015-08-06  9:25           ` dietmar.schindler
2015-08-06 15:12             ` Philippe Gerum [this message]
     [not found]   ` <CAHoW4hHS2QS1td6mUiWid-unDrMDZaQMo3vkYsDynNze5YsaSw@mail.gmail.com>
     [not found]     ` <55C326C5.4070608@xenomai.org>
2015-08-06 15:00       ` Charles Kiorpes
2015-08-06 15:23         ` Philippe Gerum
2015-08-06 15:26           ` Philippe Gerum
2015-08-10 13:52           ` Charles Kiorpes
2015-08-10 15:01             ` Philippe Gerum
2015-08-10 15:17               ` Charles Kiorpes
2015-08-10 15:40                 ` Philippe Gerum
2015-08-13 11:14                 ` Philippe Gerum
2015-08-13 11:39                   ` Charles Kiorpes
2015-08-13 16:21                     ` Philippe Gerum
2015-08-10 15:50             ` Philippe Gerum
2015-08-11 15:17             ` Philippe Gerum
2015-08-11 15:14         ` Philippe Gerum

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=55C3795D.5000703@xenomai.org \
    --to=rpm@xenomai.org \
    --cc=dietmar.schindler@manroland-web.com \
    --cc=xenomai@xenomai.org \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.