Closed ajaybhargavb closed 3 years ago
I think that makes sense.
Should we apply the same thing to Range
as well?
Should we apply the same thing to Range as well?
We haven't found the need for it yet. Maybe not given Roslyn doesn't do that either, https://github.com/dotnet/roslyn/blob/master/src/Compilers/Core/Portable/Text/LinePositionSpan.cs.
Thanks @david-driscoll
It is fairly common to want to check whether a position appears before or after another and it would be nice to have them be easily comparable(like this) instead of having to check the line and character separately.
Here is an example of where this might be useful.