Re: The result of ++ is not an lvalue?



Old Wolf wrote On 05/21/07 17:31,:
On May 21, 2:18 am, Eric Sosman <esos...@xxxxxxxxxxxxxxxxxxx> wrote:

No. *(any_valid_pointer_expression) is an lvalue, whatever
the status of any_valid_pointer_expression itself.


Except when it doesn't designate an object (e.g. if
the any_valid_pointer_expression is pointing one off
the end of an array).

One thing about c.l.c. is that verbal shortcuts always
catch up with one ... I used "valid" suggestively rather
than precisely, and dangitall if'n somebody didn't call me
on it.

Another way a perfectly good pointer value can fail to
be "valid" in my imprecise sense is to be a pointer to an
incomplete type, e.g., a `void*' or a `struct opaque*'.
Such a pointer can be perfectly well-defined, useful, and
a model citizen in every way, yet not be capable of yielding
an lvalue.

And if somebody nit-picks that `struct opaque' might
not be an incomplete type, I'm gonna boot up my DS9K and
do some DAMAGE!

http://dialspace.dial.pipex.com/town/green/gfd34/art/

--
Eric.Sosman@xxxxxxx
.



Relevant Pages

  • Re: 5.3: cant install openoffice 1.1 from ports
    ... > to install gnome2.8, which im using know, great. ... before "void" ... pointer to incomplete type ...
    (freebsd-questions)
  • UInaqble to install OpenOffice 1.1.3 from porte, 5.3R
    ... Im running 5.3R and i've cvsuped ports to get gnome 2.8 running which went fine. ... before "void" ... pointer to incomplete type ...
    (freebsd-hackers)
  • Re: 5.3: cant install openoffice 1.1 from ports
    ... >> Problem is that it wont allow me to compile openoffice properly, ... >> and i've since made clean. ... > pointer to incomplete type ...
    (freebsd-questions)
  • Re: Arrays of incomplete type
    ... dereference a pointer to an incomplete type (the pointer is ... to an incomplete type is not itself incomplete: ... void free_opaque (struct opaque *o); ... extern struct opaque *const default_value; ...
    (comp.std.c)
  • Re: Banks and economy
    ... Such a declarator makes the contained identifier ... "array of" specification are adjacent, ... type', and as I quoted to Phil, the incomplete type can't be ... parameters since array types used there are converted to pointer types. ...
    (alt.lang.asm)