tweag / pirouette

Language-generic workbench for building static analysis
MIT License
47 stars 2 forks source link

Evaluate destructors earlier than other arguments #100

Closed serras closed 2 years ago

serras commented 2 years ago

See the discussion at https://github.com/tweag/pirouette/issues/94#issuecomment-1140823333. This is a better approach than #98.

VictorCMiraldo commented 2 years ago

The increase in runtime makes sense; before, say we had three arguments [x, y ,z], we would expand all three then run prune. Now, we expand one at a time (if they're all matches, for instance) and run prune multiple times.

Additionally, we still have to find which ones are matches, which is some additional computation.