[PEAK] Patch: Update RuleDispatch for python-2.7
Toshio Kuratomi
a.badger at gmail.com
Mon Aug 2 01:32:22 EDT 2010
On Sun, Aug 01, 2010 at 02:08:14PM -0400, P.J. Eby wrote:
> At 10:01 AM 8/1/2010 -0400, Toshio Kuratomi wrote:
> >In Fedora we've recently upgraded from python-2.6 to python-2.7. In doing
> >so we found that the unittests for RuleDispatch were failing. The failures
> >seem to be legitimate bugs in ruledispatch so I've updated the code to fix
> >them. I'm attaching a patch for your perusal.
>
> I've checked in something that should be equivalent, and updated the
> testlist_comp in PEAK-Rules as well. Thanks!
>
Thank you!
> Btw, it's highly recommended that people switch to PEAK-Rules, as it
> is better tested, has better performance (especially if you're just
> using type checks without full predicate dispatch), and its internals
> are far more documented and extensible than RuleDispatch.
>
> For ease in porting, there's even a peak.rules.dispatch module that
> provides a partial API emulation for RuleDispatch.
>
> If you're using an API that's not supported by the emulation, I'd
> appreciate a heads-up so I can give it implementation priority, or at
> least document how to translate what you're doing to the new API.
>
> Come to think of it, I should probably slap that information into
> RuleDispatch's README, so it'll go into your next release... There,
> done and done. ;-)
>
It's great to have porting docs! Thanks. That could help us either
convince upstreams to port their code or to help them port their code over.
One slight problem we've run into is that we can't currently get
python-peak-rules running on python-2.7 due to incompatibility between the
current version of python-byte-assembler (which is a peak-rules dependency)
and python-2.7. The JUMP_IF_FALSE and FUMP_IF_TRUE opcodes have been
removed in python-2.7.
-Toshio
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 198 bytes
Desc: not available
Url : http://www.eby-sarna.com/pipermail/peak/attachments/20100802/a407dc9e/attachment.bin
More information about the PEAK
mailing list