fix for arrya constant

This commit is contained in:
Richard Frith-Macdonald 2022-01-30 17:24:32 +00:00
parent 3e6284ab39
commit f3344628e5
2 changed files with 24 additions and 1 deletions

View file

@ -1,3 +1,8 @@
2022-01-30 Richard Frith-Macdonald <rfm@gnu.org>
* Source/NSPredicate.m:
Fix for git #233
2022-01-15 Frederik Seiffert <frederik@algoriddim.com>
* Source/NSPathUtilities.m:

View file

@ -1339,7 +1339,25 @@ GSICUStringMatchesRegex(NSString *string, NSString *regex, NSStringCompareOption
- (id) expressionValueWithObject: (id)object
context: (NSMutableDictionary *)context
{
return _obj;
if ([_obj isKindOfClass: [NSArray class]])
{
NSMutableArray *tmp = [(NSArray*)_obj mutableCopy];
NSUInteger count = [tmp count];
NSUInteger index;
for (index = 0; index < count; index++)
{
NSExpression *e = [tmp objectAtIndex: index];
id o = [e expressionValueWithObject: e context: context];
[tmp replaceObjectAtIndex: index withObject: o];
}
return AUTORELEASE(tmp);
}
else
{
return _obj;
}
}
- (void) dealloc