diff --git a/ChangeLog b/ChangeLog index 870e0bf61..69ed05b87 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2007-03-30 Richard Frith-Macdonald + + * Source/NSPredicate.m: ([-parseOr]) Use orPredicateWithSubpredicates + rather than andPredicateWithSubpredicates. Fix for bug #19446. + 2007-03-25 Richard Frith-Macdonald * Source/NSTimer.m: minor optimisation ... avoid unnecessary use of diff --git a/Source/NSPredicate.m b/Source/NSPredicate.m index aaa415a52..31fe90094 100644 --- a/Source/NSPredicate.m +++ b/Source/NSPredicate.m @@ -1435,11 +1435,11 @@ notPredicateWithSubpredicate: [self parseNot]]; } - if ([self scanPredicateKeyword:@"TRUEPREDICATE"]) + if ([self scanPredicateKeyword: @"TRUEPREDICATE"]) { return [NSPredicate predicateWithValue: YES]; } - if ([self scanPredicateKeyword:@"FALSEPREDICATE"]) + if ([self scanPredicateKeyword: @"FALSEPREDICATE"]) { return [NSPredicate predicateWithValue: NO]; } @@ -1451,7 +1451,7 @@ { NSPredicate *l = [self parseNot]; - while ([self scanPredicateKeyword:@"OR"]) + while ([self scanPredicateKeyword: @"OR"]) { NSPredicate *r = [self parseNot]; @@ -1483,7 +1483,7 @@ } else { - l = [NSCompoundPredicate andPredicateWithSubpredicates: + l = [NSCompoundPredicate orPredicateWithSubpredicates: [NSArray arrayWithObjects: l, r, nil]]; } } @@ -1771,7 +1771,7 @@ [args addObject: [self parseExpression]]; } - if (![self scanString:@")" intoString:NULL]) + if (![self scanString: @")" intoString: NULL]) { [NSException raise: NSInvalidArgumentException format: @"Missing ) in function arguments"];