diff options
author | jxh <jxh@ae88bc3d-4319-0410-8dbf-d08b4c9d3795> | 1997-11-19 23:19:58 +0000 |
---|---|---|
committer | jxh <jxh@ae88bc3d-4319-0410-8dbf-d08b4c9d3795> | 1997-11-19 23:19:58 +0000 |
commit | 72bf57c12ab5e9d433af8b2b54c9041c85f90222 (patch) | |
tree | 7586ebaa19bf8de577e39ecd3ed4d1bf21f53cba | |
parent | 345c8450d06650451685c717f01c6d5a3e308f26 (diff) | |
download | ATCD-72bf57c12ab5e9d433af8b2b54c9041c85f90222.tar.gz |
Added casts to comparisons of char variables to 0, since chars are
unsigned by default in SGI.
-rw-r--r-- | TAO/TAO_IDL/ast/ast_expression.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/TAO/TAO_IDL/ast/ast_expression.cpp b/TAO/TAO_IDL/ast/ast_expression.cpp index c6f77e8b7a1..fd9d03fabbd 100644 --- a/TAO/TAO_IDL/ast/ast_expression.cpp +++ b/TAO/TAO_IDL/ast/ast_expression.cpp @@ -418,7 +418,7 @@ coerce_value(AST_Expression::AST_ExprValue *ev, AST_Expression::ExprType t) ev->et = AST_Expression::EV_short; return ev; case AST_Expression::EV_char: - if (ev->u.cval < 0) + if ((signed char) ev->u.cval < 0) return NULL; ev->u.usval = (unsigned short) ev->u.cval; ev->et = AST_Expression::EV_ushort; @@ -528,7 +528,7 @@ coerce_value(AST_Expression::AST_ExprValue *ev, AST_Expression::ExprType t) ev->et = AST_Expression::EV_ulong; return ev; case AST_Expression::EV_char: - if (ev->u.cval < 0) + if ((signed char) ev->u.cval < 0) return NULL; ev->u.ulval = (unsigned long) ev->u.cval; ev->et = AST_Expression::EV_ulong; @@ -795,7 +795,7 @@ coerce_value(AST_Expression::AST_ExprValue *ev, AST_Expression::ExprType t) ev->et = AST_Expression::EV_octet; return ev; case AST_Expression::EV_char: - if (ev->u.cval < 0) + if ((signed char) ev->u.cval < 0) return NULL; ev->u.oval = (unsigned char) ev->u.cval; ev->et = AST_Expression::EV_octet; |