diff options
| author | jakub <jakub@138bc75d-0d04-0410-961f-82ee72b054a4> | 2008-12-08 18:03:40 +0000 |
|---|---|---|
| committer | jakub <jakub@138bc75d-0d04-0410-961f-82ee72b054a4> | 2008-12-08 18:03:40 +0000 |
| commit | 6242196e91dd11d7c1bcbd6d9c1ebefd5a2cb324 (patch) | |
| tree | 4b32010721bc7d4d4caef10a35f123a3c0bf3887 | |
| parent | 342ad2d6a6167f3f9626947ac8affa9e0c92f611 (diff) | |
| download | ppe42-gcc-6242196e91dd11d7c1bcbd6d9c1ebefd5a2cb324.tar.gz ppe42-gcc-6242196e91dd11d7c1bcbd6d9c1ebefd5a2cb324.zip | |
PR c/35442
* c-pretty-print.c (pp_c_cast_expression, pp_c_expression): Handle
VIEW_CONVERT_EXPR the same as CASE_CONVERT.
* gcc.dg/pr35442.c: New test.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@142558 138bc75d-0d04-0410-961f-82ee72b054a4
| -rw-r--r-- | gcc/ChangeLog | 6 | ||||
| -rw-r--r-- | gcc/c-pretty-print.c | 2 | ||||
| -rw-r--r-- | gcc/testsuite/ChangeLog | 5 | ||||
| -rw-r--r-- | gcc/testsuite/gcc.dg/pr35442.c | 11 |
4 files changed, 24 insertions, 0 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 248979115b0..4a35cf450f4 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,9 @@ +2008-12-08 Jakub Jelinek <jakub@redhat.com> + + PR c/35442 + * c-pretty-print.c (pp_c_cast_expression, pp_c_expression): Handle + VIEW_CONVERT_EXPR the same as CASE_CONVERT. + 2008-12-08 Richard Henderson <rth@redhat.com> PR 38240 diff --git a/gcc/c-pretty-print.c b/gcc/c-pretty-print.c index cf1c6c3f52c..cc366791cfd 100644 --- a/gcc/c-pretty-print.c +++ b/gcc/c-pretty-print.c @@ -1629,6 +1629,7 @@ pp_c_cast_expression (c_pretty_printer *pp, tree e) case FLOAT_EXPR: case FIX_TRUNC_EXPR: CASE_CONVERT: + case VIEW_CONVERT_EXPR: pp_c_type_cast (pp, TREE_TYPE (e)); pp_c_cast_expression (pp, TREE_OPERAND (e, 0)); break; @@ -2020,6 +2021,7 @@ pp_c_expression (c_pretty_printer *pp, tree e) case FLOAT_EXPR: case FIX_TRUNC_EXPR: CASE_CONVERT: + case VIEW_CONVERT_EXPR: pp_c_cast_expression (pp, e); break; diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index 696d82a1a53..84fd6210dbf 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -1,3 +1,8 @@ +2008-12-08 Jakub Jelinek <jakub@redhat.com> + + PR c/35442 + * gcc.dg/pr35442.c: New test. + 2008-12-07 Eric Botcazou <ebotcazou@adacore.com> * gnat.dg/string_comparison.adb: New test. diff --git a/gcc/testsuite/gcc.dg/pr35442.c b/gcc/testsuite/gcc.dg/pr35442.c new file mode 100644 index 00000000000..4f1e3cc537f --- /dev/null +++ b/gcc/testsuite/gcc.dg/pr35442.c @@ -0,0 +1,11 @@ +/* PR c/35442 */ +/* { dg-bogus "not supported by" "" { target *-*-* } 0 } */ + +typedef char A __attribute__ ((vector_size (64))); +typedef int B __attribute__ ((vector_size (64))); + +void +foo (A a) +{ + ((B) a) (); /* { dg-error "is not a function" } */ +} |

