mirror of
https://github.com/gnustep/libs-base.git
synced 2025-04-22 16:33:29 +00:00
avoid crash with libobjc2. add comment about OSX inconsistency.
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@32250 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
313cf13c67
commit
ceb881bca3
1 changed files with 9 additions and 2 deletions
|
@ -94,6 +94,7 @@ main(int argc, char *argv[])
|
|||
NSUInteger a;
|
||||
const char *t0;
|
||||
const char *t1;
|
||||
const char *n;
|
||||
|
||||
t0 = "1@1:@";
|
||||
t1 = NSGetSizeAndAlignment(t0, &s, &a);
|
||||
|
@ -105,8 +106,14 @@ main(int argc, char *argv[])
|
|||
"class_isMetaClass() returns NO for Nil");
|
||||
PASS(Nil == class_getSuperclass(Nil),
|
||||
"class_getSuperclass() returns NO for Nil");
|
||||
PASS(strcmp(class_getName(Nil), "nil") == 0,
|
||||
"class_getName() for Nil is nil");
|
||||
|
||||
/* NB. the OSX documentation says that the function returns an empty string
|
||||
* when given a Nil argument, but the actual behavior on OSX 10.6 is to
|
||||
* return the string "nil"
|
||||
*/
|
||||
PASS_RUNS(n = class_getName(Nil), "class_getName() for Nil does not crash")
|
||||
PASS(n != 0 && strcmp(n, "nil") == 0, "class_getName() for Nil is nil");
|
||||
|
||||
PASS(0 == class_getInstanceVariable(Nil, 0),
|
||||
"class_getInstanceVariables() for Nil,0 is 0");
|
||||
PASS(0 == class_getVersion(Nil),
|
||||
|
|
Loading…
Reference in a new issue