More tidying up for consistency with gui libs

git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@8568 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
richard 2001-01-12 14:29:34 +00:00
parent bc651e8fce
commit 2bae002b52
9 changed files with 137 additions and 105 deletions

View file

@ -14,6 +14,7 @@
int main()
{
NSPoint p;
NSRange range;
NSRect rect;
NSValue *v1, *v2;
NSNumber *nc, *ns, *n1, *n2, *n3, *n4, *n5;
@ -78,6 +79,12 @@ printf("nc compare:ns is %d\n", [nc compare:ns]);
v1 = [NSValue valueWithNonretainedObject:v2];
[[v1 nonretainedObjectValue] getValue:&p];
printf("point is %f %f\n", p.x, p.y);
range = NSMakeRange(1, 103);
range = NSIntersectionRange(range, NSMakeRange(2, 73));
v1 = [NSValue valueWithRange:range];
printf("Encoding for range is %s\n", [v1 objCType]);
range = [v1 rangeValue];
printf("Range is %u %u\n", range.location, range.length);
printf("Try getting a null NSValue, should get a NSLog error message:\n");
v2 = [NSValue value:NULL withObjCType:@encode(int)];