public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "rguenth at gcc dot gnu dot org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug middle-end/27529] Does not fold (char *)(size_t)char_ptr or (size_t)(char *)size_t_var
Date: Thu, 11 May 2006 08:30:00 -0000	[thread overview]
Message-ID: <20060511083020.29576.qmail@sourceware.org> (raw)
In-Reply-To: <bug-27529-10053@http.gcc.gnu.org/bugzilla/>



------- Comment #2 from rguenth at gcc dot gnu dot org  2006-05-11 08:30 -------
Subject: Bug 27529

Author: rguenth
Date: Thu May 11 08:29:40 2006
New Revision: 113692

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=113692
Log:
2006-05-11  Richard Guenther  <rguenther@suse.de>

        PR middle-end/27529
        * fold-const.c (fold_unary): Handle intermediate conversion
        to a pointer type like intermediate conversion to an integer
        type in folding of (T1)(T2)var to var.
        Match the code to the comment in the final conversion for
        (T1)(T2)var to (T1)var regarding to type precision.  Rather
        than disallow T1 being of pointer type, assert that both T1
        and var are of pointer type or not.  Make sure not to fall
        over the frontends lazyness wrt array to pointer decay though.

        * gcc.dg/tree-ssa/foldcast-1.c: New testcase.

Added:
    trunk/gcc/testsuite/gcc.dg/tree-ssa/foldcast-1.c
Modified:
    trunk/gcc/ChangeLog
    trunk/gcc/fold-const.c
    trunk/gcc/testsuite/ChangeLog


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=27529


  parent reply	other threads:[~2006-05-11  8:30 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-05-10 10:01 [Bug middle-end/27529] New: " rguenth at gcc dot gnu dot org
2006-05-10 15:48 ` [Bug middle-end/27529] " pinskia at gcc dot gnu dot org
2006-05-11  8:30 ` rguenth at gcc dot gnu dot org
2006-05-11  8:30 ` rguenth at gcc dot gnu dot org [this message]
2006-05-15 19:40 ` patchapp at dberlin dot org

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=20060511083020.29576.qmail@sourceware.org \
    --to=gcc-bugzilla@gcc.gnu.org \
    --cc=gcc-bugs@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: link
Be 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).