All of lore.kernel.org
 help / color / mirror / Atom feed
From: Andrew Cooper <andrew.cooper3@citrix.com>
To: Ian Jackson <Ian.Jackson@eu.citrix.com>
Cc: roger.pau@citrix.com, wei.liu2@citrix.com,
	Ian Campbell <ian.campbell@citrix.com>,
	stefano.stabellini@eu.citrix.com, xen-devel@lists.xen.org
Subject: Re: [PATCH RFC tools 1/6] tools: Refactor "xentoollog" into its own library
Date: Mon, 21 Sep 2015 18:30:53 +0100	[thread overview]
Message-ID: <56003ECD.9010105@citrix.com> (raw)
In-Reply-To: <22016.15007.372240.924416@mariner.uk.xensource.com>

On 21/09/15 18:13, Ian Jackson wrote:
> Andrew Cooper writes ("Re: [Xen-devel] [PATCH RFC tools 1/6] tools: Refactor "xentoollog" into its own library"):
>> On 21/09/15 17:17, Ian Jackson wrote:
>>> Do you mean that statement expressions (originally a GNU extension)
>>> should be avoided in tools code ?  A quick git-grep discovered that
>>> xenctrl already contains numerous statement expressions.
>> It is fine (in principle) to be used internally.  Not in a public header
>> for what is supposed to be a clean API.
> I don't understand why this distinction is relevant.  Either the
> compiler supports it, or it doesn't.

There shouldn't be items in a public header which can't be used by all
compilers which might want to compile it.

GCC is not the only compiler liable to encounter this new header file.

>
>>>> violates several principles of least supprise,
>>> This is just invective.
>> /me googles and discovered a new word.  I stand by my statement.
> Well, if you feel so strongly, I won't object to a patch to remove it.

This is exactly why I raise the point now when the ABI is deliberately
changing.  Having said that, it was previously in libxc so anything
went.  I would be happy to submit a patch either to libxc now, or to
libxentoollog later.

>
>>>> As part of the tidyup, we should choose a particular C standard (89,
>>>> probably) and ensure that the API/ABI complies with `gcc -std=c$VER
>>>> -pedantic`.  This will help to provide a consistent API on other
>>>> platforms (I seem to recall an effort to port libvchan to windows.)
>>> -pedantic is certainly a bad idea.
>> Pedantic is absolutely the correct answer.  It will cause gcc to reject
>> any non C compliant statements.
> No, that is not what -pedantic does.  Please RTFM.

Please explain why you believe it to be unsuitable?  It is not perfect,
but is far better than nothing.

~Andrew

  reply	other threads:[~2015-09-21 17:30 UTC|newest]

Thread overview: 29+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-06-10 11:36 [PATCH RFC 0/6+2+2] Begin to disentangle libxenctrl and provide some stable libraries Ian Campbell
2015-06-10 11:36 ` [PATCH RFC tools 1/6] tools: Refactor "xentoollog" into its own library Ian Campbell
2015-06-11 11:20   ` Andrew Cooper
2015-06-11 11:35     ` Ian Campbell
2015-06-11 12:06       ` Jan Beulich
2015-06-11 12:21         ` Ian Campbell
2015-09-21 16:17     ` Ian Jackson
2015-09-21 17:03       ` Andrew Cooper
2015-09-21 17:13         ` Ian Jackson
2015-09-21 17:30           ` Andrew Cooper [this message]
2015-09-22  8:39             ` Ian Campbell
2015-06-10 11:36 ` [PATCH RFC tools 2/6] tools: Link in-tree libvchan users against libxenvchan.so Ian Campbell
2015-06-10 11:36 ` [PATCH RFC tools 3/6] tools: Do not add top-level tools dir to include path Ian Campbell
2015-06-10 11:36 ` [PATCH RFC tools 4/6] tools/libxc: Remove osdep indirection for xc_evtchn Ian Campbell
2015-06-10 11:36 ` [PATCH RFC tools 5/6] tools: Refactor /dev/xen/evtchn wrappers into libxenevtchn Ian Campbell
2015-06-10 16:29   ` David Vrabel
2015-06-11  8:58     ` Ian Campbell
2015-06-10 17:16   ` Andrew Cooper
2015-06-11  9:03     ` Ian Campbell
2015-06-10 11:36 ` [PATCH RFC tools 6/6] Cleanup SHLIBDEPS Ian Campbell
2015-06-10 11:37 ` [PATCH RFC qemu-trad 1/2] qemu-xen-traditional: Use xentoollog as a separate library Ian Campbell
2015-06-10 15:57   ` Ian Jackson
2015-06-11  8:59     ` Ian Campbell
2015-06-10 11:37 ` [PATCH RFC qemu-trad 2/2] qemu-xen-traditional: Use libxenevtchn Ian Campbell
2015-06-10 11:37 ` [PATCH RFC mini-os 1/2] mini-os: Include libxentoollog with libxc Ian Campbell
2015-06-10 11:37 ` [PATCH RFC mini-os 2/2] mini-os: Include libxenevtchn " Ian Campbell
2015-06-10 16:01 ` [PATCH RFC 0/6+2+2] Begin to disentangle libxenctrl and provide some stable libraries Ian Jackson
2015-06-10 16:15   ` Wei Liu
2015-06-11 10:01     ` Antti Kantee

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=56003ECD.9010105@citrix.com \
    --to=andrew.cooper3@citrix.com \
    --cc=Ian.Jackson@eu.citrix.com \
    --cc=ian.campbell@citrix.com \
    --cc=roger.pau@citrix.com \
    --cc=stefano.stabellini@eu.citrix.com \
    --cc=wei.liu2@citrix.com \
    --cc=xen-devel@lists.xen.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.