summaryrefslogtreecommitdiff
path: root/gcc/objc
diff options
context:
space:
mode:
authormrs <mrs@138bc75d-0d04-0410-961f-82ee72b054a4>2013-08-16 21:01:34 +0000
committermrs <mrs@138bc75d-0d04-0410-961f-82ee72b054a4>2013-08-16 21:01:34 +0000
commit2c5faab9c653b65a3b8752c87f5ce1e99a9086fb (patch)
tree00ee66136a9afaacbb5893fadfa79668e857d5a1 /gcc/objc
parent856d965fe4d0c9f653052b731015199df7886b0e (diff)
downloadgcc-2c5faab9c653b65a3b8752c87f5ce1e99a9086fb.tar.gz
Fix:
objc.dg/attributes/method-nonnull-1.m -fgnu-runtime (test for errors, line 22) objc.dg/attributes/method-nonnull-1.m -fgnu-runtime (test for errors, line 23) git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/branches/wide-int@201802 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/objc')
-rw-r--r--gcc/objc/objc-act.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/gcc/objc/objc-act.c b/gcc/objc/objc-act.c
index 21bac389f89..0d17eb28ea0 100644
--- a/gcc/objc/objc-act.c
+++ b/gcc/objc/objc-act.c
@@ -4923,7 +4923,8 @@ objc_decl_method_attributes (tree *node, tree attributes, int flags)
{
/* Get the value of the argument and add 2. */
tree number = TREE_VALUE (argument);
- if (number && TREE_CODE (number) == INTEGER_CST)
+ if (number && TREE_CODE (number) == INTEGER_CST
+ && !wide_int (number).zero_p ())
TREE_VALUE (argument)
= wide_int_to_tree (TREE_TYPE (number), wide_int (number) + 2);
argument = TREE_CHAIN (argument);