Repository navigation
Conversation
…w`/`grw` suggestions
PR summary 02bbed9e6fImport changes for modified filesNo significant changes to the import graph Import changes for all files
|
grunweg
left a comment
There was a problem hiding this comment.
Thanks! Looks reasonable to me, but I'd appreciate another pair of eyes.
maintainer delegate?
| -- different side conditions! | ||
| /-- The new subexpression. -/ | ||
| replacement : AbstractMVarsResult | ||
| /-- The new subexpression and the corresponding side goals. -/ |
There was a problem hiding this comment.
It seems that the side goals are put before the subexpression. Do you think such ordering is worth documenting? (Same question above.)
There was a problem hiding this comment.
My idea was that the ordering doesn't really matter, as long as it's done consistently.
|
🚀 Pull request has been placed on the maintainer queue by grunweg. |
|
Thanks! This looks very good! I only have two questions.
|
This was discussed in yesterday's maintainers meeting, I'm tasked with following up on this. Opinion in the meeting was "yes" and "seems rather unlikely". In any case, this should be a separate PR :) |
|
Having a test for this would obviously be great, but I don't know if this is feasible. |
|
Adding a test for this is a bit awkward, because the current testing setup can only tell which tactics are suggested at all. Since there is also an unfiltered section of the output, this is not affected by the deduplication. 🫤 The way the test works is that it traverses the produced |
|
Hm. What you suggest is certainly an improvement! |
This PR improves the deduplication of
rwandgrwsuggestions in#click_suggestions. Previously, it would only look at the replacement expression and not at side goals. As a result, important suggestions could get lost.This PR makes it compare the side goals as well, so that it only consider two rewrites the same when the replacement expression and the new side goals are all the same. This might cause some unwanted suggestions to not be filtered out, but that is better than that good suggestions are filtered out.
Example by Floris van Doorn: