DrJavaAtRice / drjava

Branches for integration and releases
20 stars 28 forks source link

Fixed line number test case and off-by-one error in DrJava #25

Closed jacomjos closed 6 months ago

jacomjos commented 6 months ago

The test case that was failing was checking for(p1.getOffset() <= 20 && p1.getOffset() <= 29) instead of (p1.getOffset() >= 20 && p1.getOffset() <= 29). The description in the String is valid; the syntax error is in the line that starts at position 20. The compiler now has the correct line and column number that the DrJava UI uses to display where the error occurred and to position the cursor at when clicking on the error.