softdevteam / lrpar

Rust LR parser
Other
1 stars 0 forks source link

Add cpctplusdyndist recoverer. #69

Closed ltratt closed 6 years ago

ltratt commented 6 years ago

This PR does two things: first it renames the "corchuelo" recoverer to "cpctplus" to match the paper. Second, it adds a new recoverer "CPCTPlusDynDist" (not a snappy name, I admit) which is a mix of cpctplus and MF: it uses dyn_dist to speed up cpctplus. My quick experiments suggest that CPCTPlusDynDist is quite a bit faster than CPCTPlus, but still a bit slower than MF.

The cpctplusdyndist.rs file is, basically, a copy of mf.rs (minus the Dist struct) with the reduction rules taken from cpctplus.rs with the addition of the dyn_dist calls. It's less scary than it looks (I hope).

ptersilie commented 6 years ago

Merged!