Repository navigation
Fix Code Model bug reported by @carlos-j-quintero - #488
Merged
Merged
Conversation
VB CodeModel now returns proper EnvDTE80.vsCMFunction2 values for AddHandler, RemoveHandler and RaiseEvent accessors.
VB CodeModel now returns vsCMFunctionDestructor for Overrides Finalize() members
C# CodeModel FunctionKind should not throw on an explicit interface implementation of a method.
It turns out that there was a fundamental problem with how parameter names were handled in VB Code Model. Essentially, the CodeParameter object was created with the modified identifier of the name. So, it included the ? or () if they were declared and the type character if it was declared. This made a bit of a mess when it came time to look of the underlying node. This should fix several problems (not all reported), so I went ahead and added several unit tests.
VB code model should include Declare Sub and Function
This should return vsCMFunctionSub for Subs and vsCMFunctionFunction for Functions
VB CodeModel GetStartPoint and GetEndPoint should not throw for property or event accessors.
VB CodeModel events (both simple and custom), auto-properties, and delegates should populate the Attributes property.
Member
There was a problem hiding this comment.
That's an oddly cased method name. What is the translation for that?
Member
There was a problem hiding this comment.
Ah okay, it's a mapping of COM error codes.
Member
Author
There was a problem hiding this comment.
Right. This is all fun COM stuff. 😄
Member
|
LGTM |
Member
There was a problem hiding this comment.
Nitpick: we probably don't need the this. anymore given we're doing _ qualification.
Member
Author
There was a problem hiding this comment.
True. That's just muscle memory on my part.
Member
|
👍 |
DustinCampbell
added a commit
that referenced
this pull request
Feb 13, 2015
Fix Code Model bug reported by @carlos-j-quintero
This was referenced Feb 13, 2015
Closed
This was referenced Feb 13, 2015
EnvDTE.CodeParameter.StartPoint and EndPoint causes exception for “ByVal ParamArray” parameters
#146
Closed
DustinCampbell
added a commit
to DustinCampbell/roslyn
that referenced
this pull request
Feb 13, 2015
DustinCampbell
added a commit
that referenced
this pull request
Feb 13, 2015
Code review feedback for PR #488
dibarbet
pushed a commit
that referenced
this pull request
Aug 18, 2026
Support stable target frameworks
This was referenced Aug 26, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Issue #143: VB Code Model should not throw COMExceptions for property or event accessors
Issue #146: Rework how VB parameter names are handled by Code Model. The parameter name should be the identifier name and not include a type character, ? or ().
Issue #147: C# Code Model should not throw when FunctionKind is accessed for an explicitly-implemented interface method.
Issue #148: VB Code Model should include Declare Subs and Functions.
Issue #149: VB Code Model should return vsCMFunctionDestructor when FunctionKind is accessed for an Overrides Finalize() method.
Issue #150: VB Code Model should return the appropriate EnvDTE80.vsCMFunction2 values for event AddHandler, RemoveHandler and RaiseEvent accessors.
Issue #151: VB CodeModel events (both simple and custom), auto-properties, and delegates should populate the Attributes property.