Mailing Lists: Apple Mailing Lists
Image of Mac OS face in stamp
Re: NSExpression
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: NSExpression




On Jun 28, 2008, at 10:35 PM, Chris wrote:
NSExpression * ex = [NSExpression expressionForFunction: [NSExpression expressionForConstantValue:@"BAR"] selectorName:@"length" arguments:nil];
NSPredicate * predicate = [NSCompoundPredicate
andPredicateWithSubpredicates:[NSArray arrayWithObject: ex]];
[predicate evaluateWithObject:@"FOO" substitutionVariables:nil];


What are you trying to achieve?
ex is not a predicate, so you're only supplying one -- incorrect -- argument to create an AND predicate. It's not clear what role "FOO" plays in the third line.


mmalc

_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


References: 
 >NSExpression (From: Chris <email@hidden>)
 >Re: NSExpression (From: Shawn Erickson <email@hidden>)
 >Re: NSExpression (From: Chris <email@hidden>)



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2011 Apple Inc. All rights reserved.