poscat0x04 / fastparse

BSD 3-Clause "New" or "Revised" License
0 stars 0 forks source link

Investigate into delimited continuation primops #1

Open poscat0x04 opened 3 years ago

poscat0x04 commented 3 years ago

We need continuations to implement the backtracking control flow (currently Its broken). But we also don't want to pay the cost when they are not being needed. It might be good to take a look into the delimited continuation primops.

poscat0x04 commented 3 years ago

I think I know how to implement <|> now: always capture the continuation using control0#, if the parser succeeded, then drop the continuation altogether, otherwise call the continuation.