* Tests/base/NSArchiver/stringEncoding.m: Use PASS_EQUAL instead

of PASS.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@36617 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
fredkiefer 2013-05-13 20:55:37 +00:00
parent d1c37454fd
commit 22cc232988
4 changed files with 35 additions and 4 deletions

View file

@ -139,6 +139,31 @@ static NSMapTable *globalClassMap = 0;
return o;
}
/**
* This method is used to replace oldObj with newObj
* in the map that is maintained in NSKeyedUnarchiver.
*/
- (BOOL) replaceObject: (id)oldObj withObject: (id)newObj
{
unsigned int i = 0;
unsigned int count = GSIArrayCount(_objMap);
for (i = 0; i < count; i++)
{
id obj = GSIArrayItemAtIndex(_objMap, i).obj;
if (obj == oldObj)
break;
}
if (i < count)
{
GSIArraySetItemAtIndex(_objMap, (GSIArrayItem)newObj, i);
return YES;
}
return NO;
}
@end
@implementation NSKeyedUnarchiver (Private)