-
Notifications
You must be signed in to change notification settings - Fork 804
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Better lexer symbol #2056
Better lexer symbol #2056
Conversation
/// Gets the value associated with the option or the supplied default value. | ||
let inline getOrElse v = function | ||
| Some x -> x | None -> v | ||
|
||
/// Gets the option if Some x, otherwise try to get another value | ||
let inline orTry f = |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
these are in the FSharp.Core now, right? (just as possible optimization)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No they are not. I could not compile without these helpers.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
weird. thanks for checking
@dotnet-bot test this please |
The options module has some additions, the names are a bit different from the ones you used:
Hope this helps Kevin |
remove Pervasive.fs
Done. |
Thanks for taking care of this Kevin |
* port lexer symbol lookup logic from VFPT and use it in DocumentHighlightsService * QuickInfoProvider uses lexer symbol * remove tryClassifyAtPosition * do not show quick info if FCS return a list of single FSharpTooltipElement.None * use standard Option combinators remove Pervasive.fs
This code is (partially) ported from VFPT and it's main goal is to find proper range of a symbol at position. The previous implementation was buggy, it returned wrong ranges for operators and type parameters.