diff options
author | rsandifo <rsandifo@138bc75d-0d04-0410-961f-82ee72b054a4> | 2013-11-15 14:52:36 +0000 |
---|---|---|
committer | rsandifo <rsandifo@138bc75d-0d04-0410-961f-82ee72b054a4> | 2013-11-15 14:52:36 +0000 |
commit | 0aa8c34eee39336ae1df533ab1aa5709ad456e6d (patch) | |
tree | 127b40289dd443d16cd6949cde1204ebc2e7a747 /gcc/c-family | |
parent | 20448fd9822d3cf5e860550092cba0d2d7839ade (diff) | |
download | gcc-0aa8c34eee39336ae1df533ab1aa5709ad456e6d.tar.gz |
gcc/c-family/
* c-pretty-print.c (pp_c_character_constant): Remove unnecessary
wchar_type and host_integerp checks.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@204847 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/c-family')
-rw-r--r-- | gcc/c-family/ChangeLog | 5 | ||||
-rw-r--r-- | gcc/c-family/c-pretty-print.c | 8 |
2 files changed, 6 insertions, 7 deletions
diff --git a/gcc/c-family/ChangeLog b/gcc/c-family/ChangeLog index 9deab9e7f58..0c97da83e93 100644 --- a/gcc/c-family/ChangeLog +++ b/gcc/c-family/ChangeLog @@ -1,3 +1,8 @@ +2013-11-15 Richard Sandiford <rdsandiford@googlemail.com> + + * c-pretty-print.c (pp_c_character_constant): Remove unnecessary + wchar_type and host_integerp checks. + 2013-11-14 Andrew MacLeod <amacleod@redhat.com> * c-common.c: Likewise. diff --git a/gcc/c-family/c-pretty-print.c b/gcc/c-family/c-pretty-print.c index 652c3a89215..54ed5512cd4 100644 --- a/gcc/c-family/c-pretty-print.c +++ b/gcc/c-family/c-pretty-print.c @@ -950,14 +950,8 @@ pp_c_integer_constant (c_pretty_printer *pp, tree i) static void pp_c_character_constant (c_pretty_printer *pp, tree c) { - tree type = TREE_TYPE (c); - if (type == wchar_type_node) - pp_character (pp, 'L'); pp_quote (pp); - if (host_integerp (c, TYPE_UNSIGNED (type))) - pp_c_char (pp, tree_low_cst (c, TYPE_UNSIGNED (type))); - else - pp_scalar (pp, "\\x%x", (unsigned) TREE_INT_CST_LOW (c)); + pp_c_char (pp, (unsigned) TREE_INT_CST_LOW (c)); pp_quote (pp); } |