diff options
author | Jakub Jelinek <jakub@redhat.com> | 2008-01-22 18:03:12 +0100 |
---|---|---|
committer | Jakub Jelinek <jakub@gcc.gnu.org> | 2008-01-22 18:03:12 +0100 |
commit | 270e749db4e806317425bf51a774c87eae069057 (patch) | |
tree | bdf1a2c50a6ec8b32870c8f61c89d45760a612c7 /gcc/tree.c | |
parent | 2ddd2871085a3bf35e2429390272301d8c6ab851 (diff) | |
download | gcc-270e749db4e806317425bf51a774c87eae069057.zip gcc-270e749db4e806317425bf51a774c87eae069057.tar.gz gcc-270e749db4e806317425bf51a774c87eae069057.tar.bz2 |
re PR c++/34914 (Member pointer to vector rejected)
PR c++/34914
* c-common.c (handle_vector_size_attribute): Only allow
integral, scalar float and fixed point types. Handle OFFSET_TYPE
the same way as pointer, array etc. types.
* tree.c (reconstruct_complex_type): Handle OFFSET_TYPE.
* g++.dg/ext/vector10.C: New test.
From-SVN: r131729
Diffstat (limited to 'gcc/tree.c')
-rw-r--r-- | gcc/tree.c | 5 |
1 files changed, 5 insertions, 0 deletions
@@ -7631,6 +7631,11 @@ reconstruct_complex_type (tree type, tree bottom) inner, TREE_CHAIN (TYPE_ARG_TYPES (type))); } + else if (TREE_CODE (type) == OFFSET_TYPE) + { + inner = reconstruct_complex_type (TREE_TYPE (type), bottom); + outer = build_offset_type (TYPE_OFFSET_BASETYPE (type), inner); + } else return bottom; |