public inbox for gcc-prs@sourceware.org help / color / mirror / Atom feed
From: Andrew Pinski <pinskia@physics.uc.edu> To: nobody@gcc.gnu.org Cc: gcc-prs@gcc.gnu.org, Subject: Re: c++/7828: g++ 3.3: bad non-lvalue error (non_cast_lvalue_or_else) Date: Wed, 04 Sep 2002 12:26:00 -0000 [thread overview] Message-ID: <20020904192601.14306.qmail@sources.redhat.com> (raw) The following reply was made to PR c++/7828; it has been noted by GNATS. From: Andrew Pinski <pinskia@physics.uc.edu> To: snyder@fnal.gov Cc: gcc-gnats@gcc.gnu.org Subject: Re: c++/7828: g++ 3.3: bad non-lvalue error (non_cast_lvalue_or_else) Date: Wed, 4 Sep 2002 15:21:32 -0400 One question which libstdc++, because the version 3 is fine and it compiles just fine with this patch? Another point, it is invalid code, the problem is that the casting does makes a variable not a lvalue. gcc was accepting the invalid code because no one wanted to fix it until Matt Austern did. The error message is because when you pass an argument into a function and that argument is a reference, gcc tries to use the unary `&', which means take the memory location that points to that lvalue. Thanks, Andrew Pinski PS Also it is not illegal code but invalid code.
next reply other threads:[~2002-09-04 19:26 UTC|newest] Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top 2002-09-04 12:26 Andrew Pinski [this message] -- strict thread matches above, loose matches on Subject: below -- 2002-10-11 13:26 Gabriel Dos Reis 2002-10-11 13:16 Matt Austern 2002-10-11 13:06 Gabriel Dos Reis 2002-10-11 12:59 gdr 2002-10-08 16:56 Pop Sébastian 2002-10-08 16:46 Gabriel Dos Reis 2002-10-08 16:26 Pop Sébastian 2002-09-13 9:42 nathan 2002-09-09 13:56 Nathan Sidwell 2002-09-05 9:26 Scott Snyder 2002-09-04 12:06 snyder
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=20020904192601.14306.qmail@sources.redhat.com \ --to=pinskia@physics.uc.edu \ --cc=gcc-prs@gcc.gnu.org \ --cc=nobody@gcc.gnu.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: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).