-
-
Notifications
You must be signed in to change notification settings - Fork 42
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Wrong edit scripts #235
Comments
Hi @XY-WHU ! Thank you for the potential bug report. It is a bit unclear to me diff of which two files are being computed here. Could you please share the link of the commit or the pull request where the two files can be found? |
file links: program-repair/defects4j-dissection@d7b7936 |
@XY-WHU I am sorry I am reverting to this quite late. I completely missed this issue and forgot to follow-up on your comment. The edit script is indeed a bit weird with the redundant deletion and insertion of |
One more instance of this bug. Redundant insertion and deletion of |
@algomaster99 I have the same problem, especially in the |
@xzm2000 could you please provide test cases? It will be helpful while I debug it. |
I don't know whether it's a bug, because https://github.com/GumTreeDiff/gumtree gives the same result, has extra operation(insert and delete). |
There could ve a bug in gumtree as well. I will investigate when I get time. Thanks for the test cases. |
When applying gumtree-spoon-ast diff to extract the edit scripts between buggy file and fixed one in Defects4j Chart 14, the edit scripts returned have some wrong or meaningless edit script. Specifically, when using gun diff , its result is
xy@xy-ThinkStation-P320:~/defects/chart/chart_14_buggy$ diff source/org/jfree/chart/plot/CategoryPlot.java ../chart_14_fix/source/org/jfree/chart/plot/CategoryPlot.java
2165a2166,2168
2446a2450,2452
However, gumtree-spoon-ast-diff gives the following edit scripts:
Delete TypeReference at org.jfree.chart.plot.XYPlot:277
org.jfree.chart.plot.Plot
Insert TypeReference at org.jfree.chart.plot.XYPlot:277
org.jfree.chart.plot.Plot
Insert If at org.jfree.chart.plot.XYPlot:2293
if (markers == null) {
return false;
}
Insert If at org.jfree.chart.plot.XYPlot:2532
if (markers == null) {
return false;
}
The text was updated successfully, but these errors were encountered: