-
Notifications
You must be signed in to change notification settings - Fork 418
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
Added attribute span property for fileMemberElement #1075
Conversation
Omnisharp-vscode side : dotnet/vscode-csharp#1938 |
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.
makes sense to me
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 tests?
@@ -9,6 +9,10 @@ public class FileMemberElement : IComparable<FileMemberElement> | |||
|
|||
public QuickFix Location { get; set; } | |||
|
|||
public int AttributeSpanStart { get; set; } |
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.
Can we make these some kind of range or span type?
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.
@rchande We could pass both AttributeSpanStart and AttributeSpanEnd in a Span type class. But in that case we will also have to define this class in protocol.ts in omnisharp-vscode. Should that be done ?
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.
Protocol.ts defines a range type: https://github.com/OmniSharp/omnisharp-vscode/blob/master/src/omnisharp/protocol.ts#L450
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.
@rchande Yes it does, but the range has the start and end as Point
type. And I couldn't spot a function in omnisharp-roslyn that converts from a span
to range
Issue : dotnet/vscode-csharp#429
Added properties to contain the attribute span in a file member element, which will be used by the editor to display the "# of references" before the attributes.