try to get instance size on all systems

git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/performance/trunk@31600 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
rfm 2010-11-11 17:29:35 +00:00
parent b7ae464e45
commit 0e173bd4ff
2 changed files with 7 additions and 2 deletions

View file

@ -1,3 +1,8 @@
2010-11-11 Richard Frith-Macdonald <rfm@gnu.org>
* GSCache.m: Try to get defines right to get instance size depending
on the runtime in use.
2010-11-10 Riccardo Mottola
* GSLinkedList.h

View file

@ -757,10 +757,10 @@ static void removeItem(GSCacheItem *item, GSCacheItem **first)
return 0;
}
[exclude addObject: self];
#if !defined(GNUSTEP)
#if defined(__OBJC2__) || defined(GNUSTEP)
return class_getInstanceSize(isa);
#else
return isa->instance_size;
return ((struct objc_class *)isa)->instance_size;
#endif
}
@end