Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
| From | Tim Rentsch <txr@alumni.caltech.edu> |
|---|---|
| Newsgroups | comp.std.c |
| Subject | Re: Description of "." operator |
| Date | 2012-12-21 08:45 -0800 |
| Organization | A noiseless patient Spider |
| Message-ID | <kfn7gob73r4.fsf@x-alumni2.alumni.caltech.edu> (permalink) |
| References | <lntxrxnufa.fsf@nuthaus.mib.org> <kfn623v97x5.fsf@x-alumni2.alumni.caltech.edu> <lnpq23pvj5.fsf@nuthaus.mib.org> <kb1r3i$48g$1@dont-email.me> |
Eric Sosman <esosman@comcast-dot-net.invalid> writes:
> On 12/21/2012 5:08 AM, Keith Thompson wrote:
>>[...]
>> That's one way to approach it; the only way to have a struct value would
>> be for it to be the value of some object.
>
> If the expression is not evaluated (think `sizeof'), the `.'
> operator works just fine even if there's no struct object or
> struct value anywhere in sight.
>
> struct {
> int foo, bar;
> } *ptr = NULL;
> size_t size = sizeof (*ptr).bar;
I don't see the relevance. The result of sizeof depends only
on the type of its operand. Naturally there are no values or
objects involved, for structs or anything else (not counting
an operand of VLA type). How does this bear on the discussion
of the thread?
Back to comp.std.c | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
Description of "." operator Keith Thompson <kst-u@mib.org> - 2012-12-07 18:34 -0800
Re: Description of "." operator Keith Thompson <kst-u@mib.org> - 2012-12-08 10:43 -0800
Re: Description of "." operator Jens Gustedt <jens.gustedt@loria.fr> - 2012-12-10 00:35 +0100
Re: Description of "." operator Keith Thompson <kst-u@mib.org> - 2012-12-09 20:02 -0800
Re: Description of "." operator jgk@panix.com (Joe keane) - 2012-12-09 23:34 +0000
Re: Description of "." operator Keith Thompson <kst-u@mib.org> - 2012-12-09 20:00 -0800
Re: Description of "." operator Tim Rentsch <txr@alumni.caltech.edu> - 2012-12-20 23:32 -0800
Re: Description of "." operator Keith Thompson <kst-u@mib.org> - 2012-12-21 02:08 -0800
Re: Description of "." operator Eric Sosman <esosman@comcast-dot-net.invalid> - 2012-12-21 09:18 -0500
Re: Description of "." operator Tim Rentsch <txr@alumni.caltech.edu> - 2012-12-21 08:45 -0800
Re: Description of "." operator Tim Rentsch <txr@alumni.caltech.edu> - 2012-12-21 08:37 -0800
Re: Description of "." operator Shao Miller <sha0.miller@gmail.com> - 2013-01-06 01:23 -0500
Re: Description of "." operator Keith Thompson <kst-u@mib.org> - 2013-01-05 23:51 -0800
Re: Description of "." operator Shao Miller <sha0.miller@gmail.com> - 2013-01-06 13:49 -0500
Re: Description of "." operator Keith Thompson <kst-u@mib.org> - 2013-01-06 22:12 -0800
Re: Description of "." operator Shao Miller <sha0.miller@gmail.com> - 2013-01-17 23:19 -0500
Re: Description of "." operator Shao Miller <sha0.miller@gmail.com> - 2013-01-18 20:47 -0500
Re: Description of "." operator Keith Thompson <kst-u@mib.org> - 2013-01-18 20:14 -0800
Re: Description of "." operator jgk@panix.com (Joe keane) - 2013-01-20 20:07 +0000
Re: Description of "." operator Shao Miller <sha0.miller@gmail.com> - 2013-01-20 15:36 -0500
csiph-web