Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
| From | Keith Thompson <kst-u@mib.org> |
|---|---|
| Newsgroups | comp.lang.c |
| Subject | Re: Few questions about casting away const. |
| Date | 2014-03-10 09:00 -0700 |
| Organization | None to speak of |
| Message-ID | <lnob1et55u.fsf@nuthaus.mib.org> (permalink) |
| References | (3 earlier) <0.775bbd858311484cf33f.20140305043538GMT.87txbd9s9x.fsf@bsb.me.uk> <lf6f6d$t9e$1@speranza.aioe.org> <0.0302d1f985fe3795c4d3.20140305121413GMT.87d2i0alm2.fsf@bsb.me.uk> <lfbi2r$r3j$1@speranza.aioe.org> <kfnvbvmmrx0.fsf@x-alumni2.alumni.caltech.edu> |
Tim Rentsch <txr@alumni.caltech.edu> writes:
> Daniel Harrison <daniel@inventati.org> writes:
[...]
>> Since 42 is representable as an unsigned int, isn't the behaviour
>> of printf("%x\n", 42) well defined according to 7.16.1.1p2?
>
> Yes. The rules for printf() arguments are governed by the
> described behavior for the va_arg() macro.
>
> A few other posters have expressed the view that the rules for
> printf() are separate from, or not defined by, how va_arg()
> behaves. This view is at odds with opinions of members of the
> WG14 committee (who are responsible for writing and defining the
> C standard), as evidenced by comments in various committee
> documents appearing on the open-std.org website (eg, as may be
> seen in http://www.open-std.org/jtc1/sc22/wg14/www/docs/). Of
> course everyone is entitled to his or her opinion, but when it
> comes to deciding how the C standard should be interpreted, I
> believe the views of the WG14 committee should be given more
> weight than those who are not closely involved in defining and
> standardizing the language.
A valid point -- but then the problem, IMHO, is that the standard
does not sufficiently clearly express the committee's intent.
Programmers and implementers *should* be able to understand the
standard by reading the standard; they shouldn't have to resort to
asking the authors what they meant.
(This isn't a criticism of the committee, BTW; I don't expect either
the standard or its authors to be perfecdt, nor do I claim that I
would have done a better job myself.)
--
Keith Thompson (The_Other_Keith) kst-u@mib.org <http://www.ghoti.net/~kst>
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"
Back to comp.lang.c | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
Few questions about casting away const. Daniel <daniel@inventati.org> - 2014-03-04 11:18 +0000
Re: Few questions about casting away const. Ben Bacarisse <ben.usenet@bsb.me.uk> - 2014-03-04 12:39 +0000
Re: Few questions about casting away const. Kaz Kylheku <kaz@kylheku.com> - 2014-03-04 17:05 +0000
Re: Few questions about casting away const. Keith Thompson <kst-u@mib.org> - 2014-03-04 10:16 -0800
Re: Few questions about casting away const. Daniel <daniel@inventati.org> - 2014-03-05 03:45 +0000
Re: Few questions about casting away const. Ben Bacarisse <ben.usenet@bsb.me.uk> - 2014-03-05 04:20 +0000
Re: Few questions about casting away const. James Kuyper <jameskuyper@verizon.net> - 2014-03-04 15:18 -0500
Re: Few questions about casting away const. Daniel <daniel@inventati.org> - 2014-03-05 04:14 +0000
Re: Few questions about casting away const. Ben Bacarisse <ben.usenet@bsb.me.uk> - 2014-03-05 04:35 +0000
Re: Few questions about casting away const. Daniel <daniel@inventati.org> - 2014-03-05 06:11 +0000
Re: Few questions about casting away const. Ben Bacarisse <ben.usenet@bsb.me.uk> - 2014-03-05 12:14 +0000
Re: Few questions about casting away const. Daniel Harrison <daniel@inventati.org> - 2014-03-07 04:31 +0000
Re: Few questions about casting away const. Barry Schwarz <schwarzb@dqel.com> - 2014-03-06 21:23 -0800
Re: Few questions about casting away const. Kaz Kylheku <kaz@kylheku.com> - 2014-03-07 05:59 +0000
Re: Few questions about casting away const. James Kuyper <jameskuyper@verizon.net> - 2014-03-07 07:18 -0500
Re: Few questions about casting away const. Tim Rentsch <txr@alumni.caltech.edu> - 2014-03-10 00:30 -0700
Re: Few questions about casting away const. Keith Thompson <kst-u@mib.org> - 2014-03-10 09:00 -0700
Re: Few questions about casting away const. Tim Rentsch <txr@alumni.caltech.edu> - 2014-03-10 11:13 -0700
Re: Few questions about casting away const. Keith Thompson <kst-u@mib.org> - 2014-03-10 12:10 -0700
Re: Few questions about casting away const. Kaz Kylheku <kaz@kylheku.com> - 2014-03-11 07:38 +0000
Re: Few questions about casting away const. Tim Rentsch <txr@alumni.caltech.edu> - 2014-03-29 09:02 -0700
Re: Few questions about casting away const. Tim Rentsch <txr@alumni.caltech.edu> - 2014-03-10 02:29 -0700
Re: Few questions about casting away const. Keith Thompson <kst-u@mib.org> - 2014-03-10 10:52 -0700
Re: Few questions about casting away const. Tim Rentsch <txr@alumni.caltech.edu> - 2014-03-29 08:50 -0700
csiph-web