aboutsummaryrefslogtreecommitdiff
path: root/gcc/testsuite/obj-c++.dg/comp-types-1.mm
blob: 2cea5eeb48a514b23ed9926497d90805b9e280a8 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
/* APPLE LOCAL file Objective-C++ */
/* { dg-do compile } */

@interface A
+ new;
@end

@interface B : A
@end

int main(int argc, char **argv) {
    B *b = [B new];
    A *a = b;

    return (b == a);
}