Commit f234f078 by Marek Polacek Committed by Marek Polacek

* objc.dg/proto-lossage-4.m: Accept int/long int as intptr_t.

From-SVN: r251022
parent aaab59b4
......@@ -3,6 +3,8 @@
PR testsuite/81784
* gcc.dg/compare2.c: Update dg-bogus and dg-warning.
* objc.dg/proto-lossage-4.m: Accept int/long int as intptr_t.
2017-08-10 Martin Liska <mliska@suse.cz>
PR c++/81355
......
......@@ -28,13 +28,13 @@ long foo(void) {
receiver += [receiver anotherValue]; /* { dg-warning "invalid receiver type .intptr_t." } */
receiver += [(Obj *)receiver someValue]; /* { dg-warning ".Obj. may not respond to .\\-someValue." } */
/* { dg-warning "assignment to 'intptr_t {aka long int}' from 'id' makes integer from pointer without a cast" "" { target *-*-* } .-1 } */
/* { dg-warning "assignment to 'intptr_t {aka (long )?int}' from 'id' makes integer from pointer without a cast" "" { target *-*-* } .-1 } */
receiver += [(Obj *)receiver anotherValue];
receiver += [(Obj <Proto> *)receiver someValue];
receiver += [(Obj <Proto> *)receiver anotherValue];
receiver += [objrcvr someValue]; /* { dg-warning ".Obj. may not respond to .\\-someValue." } */
/* { dg-warning "assignment to 'intptr_t {aka long int}' from 'id' makes integer from pointer without a cast" "" { target *-*-* } .-1 } */
/* { dg-warning "assignment to 'intptr_t {aka (long )?int}' from 'id' makes integer from pointer without a cast" "" { target *-*-* } .-1 } */
receiver += [objrcvr anotherValue];
receiver += [(Obj <Proto> *)objrcvr someValue];
......@@ -42,7 +42,7 @@ long foo(void) {
receiver += [objrcvr2 someValue];
receiver += [objrcvr2 anotherValue];
receiver += [(Obj *)objrcvr2 someValue]; /* { dg-warning ".Obj. may not respond to .\\-someValue." } */
/* { dg-warning "assignment to 'intptr_t {aka long int}' from 'id' makes integer from pointer without a cast" "" { target *-*-* } .-1 } */
/* { dg-warning "assignment to 'intptr_t {aka (long )?int}' from 'id' makes integer from pointer without a cast" "" { target *-*-* } .-1 } */
receiver += [(Obj *)objrcvr2 anotherValue];
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment