mirror of
https://github.com/sbt/sbt.git
synced 2026-09-02 11:07:30 +02:00
xsbti.Position: add startOffset and endOffset
A position now has a start, an end, and a point (the existing `offset`), just like it does in the Scala compiler. This information is especially useful for displaying squiggly lines in an IDE. This commit and the next one are required for https://github.com/sbt/zinc/pull/571
This commit is contained in:
@@ -18,4 +18,8 @@ public interface Position
|
||||
|
||||
Optional<String> sourcePath();
|
||||
Optional<File> sourceFile();
|
||||
|
||||
// Default values to avoid breaking binary compatibility
|
||||
default Optional<Integer> startOffset() { return Optional.empty(); }
|
||||
default Optional<Integer> endOffset() { return Optional.empty(); }
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user