Join GitHub today
GitHub is home to over 40 million developers working together to host and review code, manage projects, and build software together.Sign up
@zmb3: I saw your reply and started trying to refactor things to make it easier to fix this bug, and then I got a bit carried away and got through about 3/4 of the fix myself. Did you want to fix this yourself or is it cool if I send out my CL? My CL won't fix everything - it handles ranges for types.Errors, but not for scanner.Errors, which are a bit more complicated.
Added a View interface to the source package, which allows for reading of other files (in the same package or in other packages). We were already reading files in jump to definition (to handle the lack of column information in export data), but now we can also read files in diagnostics, which allows us to determine the end of an identifier so that we can report ranges in diagnostic messages. Updates golang/go#29150 Change-Id: I7958d860dea8f41f2df88a467b5e2946bba4d1c5 Reviewed-on: https://go-review.googlesource.com/c/154742 Reviewed-by: Ian Cottrell <email@example.com>