[MacRuby-devel] NSPredicate crash
Laurent Sansonetti
lsansonetti at apple.com
Thu Jan 6 14:42:44 PST 2011
Hi Alan,
The crash may be a bug in the way we compile calls to variadic functions (such as predicateWithFormat:). Could you locate the crash report and copy/paste the backtrace information?
Laurent
On Jan 6, 2011, at 11:14 AM, Alan Skipp wrote:
> Hi everyone,
> Has anyone had any trouble with NSPredicate causing occasional crashes when used with NSArrayController? Well actually about 50% of the time.
>
> What I have is a subclass of NSArrayController which is a data source for an NSTableView that accepts drag and drop operations. In 'awakeFromNib' a NSPredicate is defined, sometimes the error is just, “EXC_BAD_ACCESS”, other times there's a bit more info:
>
> data_source.rb:20:in `awakeFromNib': NSInvalidArgumentException: Unable to parse the format string "AND" (RuntimeError)
>
> This is the offending line:
> @filter_predicate = NSPredicate.predicateWithFormat("file_type == 'NSFileTypeRegular'")
>
> The crash doesn't always occur, when it doesn't my app works without any problems. I've tried the predicate in macirb and the crash doesn't occur!?
>
> Best regards,
> Alan
> _______________________________________________
> MacRuby-devel mailing list
> MacRuby-devel at lists.macosforge.org
> http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/macruby-devel/attachments/20110106/4173733d/attachment-0001.html>
More information about the MacRuby-devel
mailing list