aboutsummaryrefslogtreecommitdiff
path: root/gcc/cp/typeck2.c
diff options
context:
space:
mode:
authorno-author <no-author@gcc.gnu.org>2004-05-25 00:42:56 +0000
committerno-author <no-author@gcc.gnu.org>2004-05-25 00:42:56 +0000
commita179c469d8ee094e2f32bccce1d67112c716cd1b (patch)
treeaebc03a02688908125930f50f1cf08dae22fa640 /gcc/cp/typeck2.c
parent03846eafd7c275b583a97c40554da04c978a110a (diff)
This commit was manufactured by cvs2svn to create tagapple/gcc-1756
'apple-gcc-1756'. git-svn-id: https://gcc.gnu.org/svn/gcc/tags/apple-gcc-1756@82225 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/cp/typeck2.c')
-rw-r--r--gcc/cp/typeck2.c10
1 files changed, 9 insertions, 1 deletions
diff --git a/gcc/cp/typeck2.c b/gcc/cp/typeck2.c
index f0717f60884..3edf58313aa 100644
--- a/gcc/cp/typeck2.c
+++ b/gcc/cp/typeck2.c
@@ -555,13 +555,21 @@ digest_init (tree type, tree init, tree* tail)
if ((TYPE_MAIN_VARIANT (TREE_TYPE (TREE_TYPE (string)))
!= char_type_node)
+ /* APPLE LOCAL begin Pascal strings 2001-07-05 zll */
+ && (TYPE_MAIN_VARIANT (TREE_TYPE (TREE_TYPE (string)))
+ != unsigned_char_type_node)
+ /* APPLE LOCAL end Pascal strings 2001-07-05 zll */
&& TYPE_PRECISION (typ1) == BITS_PER_UNIT)
{
error ("char-array initialized from wide string");
return error_mark_node;
}
- if ((TYPE_MAIN_VARIANT (TREE_TYPE (TREE_TYPE (string)))
+ /* APPLE LOCAL begin Pascal strings 2001-07-05 zll */
+ if (((TYPE_MAIN_VARIANT (TREE_TYPE (TREE_TYPE (string)))
== char_type_node)
+ || (TYPE_MAIN_VARIANT (TREE_TYPE (TREE_TYPE (string)))
+ == unsigned_char_type_node))
+ /* APPLE LOCAL end Pascal strings 2001-07-05 zll */
&& TYPE_PRECISION (typ1) != BITS_PER_UNIT)
{
error ("int-array initialized from non-wide string");