Skip to content

IndexOutOfBoundsException during DiffMatcher #15

Open
@sianghwee

Description

@sianghwee

Hi, I faced an IndexOutOfBoundsException when running a Maven project, cron-utils, in Tregression. I have uploaded the file here (cron-utils.zip).

To reproduce the bug, load this folder in the Tregression preference page and run the trace comparison. The following bug will appear.

java.lang.IndexOutOfBoundsException: Index 49 out of bounds for length 49
	at java.base/jdk.internal.util.Preconditions.outOfBounds(Preconditions.java:64)
	at java.base/jdk.internal.util.Preconditions.outOfBoundsCheckIndex(Preconditions.java:70)
	at java.base/jdk.internal.util.Preconditions.checkIndex(Preconditions.java:266)
	at java.base/java.util.Objects.checkIndex(Objects.java:359)
	at java.base/java.util.ArrayList.get(ArrayList.java:427)
	at tregression.separatesnapshots.DiffMatcher.checkFollowByAdd(DiffMatcher.java:419)
	at tregression.separatesnapshots.DiffMatcher.constructMapping(DiffMatcher.java:363)
	at tregression.separatesnapshots.DiffMatcher.matchCode(DiffMatcher.java:298)
	at tregression.empiricalstudy.TrialGenerator0.analyzeTestCase(TrialGenerator0.java:255)
	at tregression.empiricalstudy.TrialGenerator0.generateTrials(TrialGenerator0.java:88)
	at tregression.handler.SeparateVersionHandler$1.run(SeparateVersionHandler.java:67)
	at org.eclipse.core.internal.jobs.Worker.run(Worker.java:63)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions