1 /* Very simple root class for writing testcases.
2 Copyright (C) 2011-2016 Free Software Foundation, Inc.
3 Contributed by Nicola Pero
5 This file is part of GCC.
7 GCC is free software; you can redistribute it and/or modify
8 it under the terms of the GNU General Public License as published by
9 the Free Software Foundation; either version 3, or (at your option)
12 GCC is distributed in the hope that it will be useful,
13 but WITHOUT ANY WARRANTY; without even the implied warranty of
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 GNU General Public License for more details.
17 You should have received a copy of the GNU General Public License
18 along with GCC; see the file COPYING3. If not see
19 <http://www.gnu.org/licenses/>. */
21 /* This is the implementation, but in all simple testcases we
22 recommend simply including it in the testcase. */
24 #include "TestsuiteObject.h"
27 @implementation TestsuiteObject
34 return [[self alloc] init];
38 return class_createInstance (self, 0);
44 /* We return 'id' to have the same signature as [Object -free] in
45 older runtimes and avoid warnings about conflicting signatures. */
48 /* Cast 'self' to 'id' because the NeXT runtime in darwin8 (Apple
49 Mac OS X 10.4) declares object_dispose to take an "Object *"
51 return object_dispose ((id)self);
59 return class_getSuperclass (self);
63 return class_getName (self);
67 return class_getName (isa);