([OrderedCollection -putObject:atIndex:]): Return type changed from id

to void.  Use NSException, not error:.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@1274 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
Andrew McCallum 1996-03-26 20:52:17 +00:00
parent 5aae0eafb3
commit 7f329b4714

View file

@ -230,7 +230,7 @@
// OVERRIDE SOME KEYED COLLECTION METHODS;
/* Semantics: You can "put" an element only at index "count" or less */
- putObject: newObject atIndex: (unsigned)index
- (void) putObject: newObject atIndex: (unsigned)index
{
unsigned c = [self count];
@ -239,8 +239,9 @@
else if (index == c)
[self appendObject: newObject];
else
[self error:"in %s, can't put an element at index beyond [self count]"];
return self;
[NSException
raise: NSRangeException
format: @"in %s, can't put an element at index beyond [self count]"];
}
- putObject: newObject atKey: index