Repository navigation
Fix access modifier information handover between CDP and DAP for public members #1331
Copy link
Copy link
Closed
Labels
bugIssue identified by VS Code Team member as probable bugIssue identified by VS Code Team member as probable bug
Description
Depending on the access modifier of a property it should either have a different icon (VS) or different ink (Browser). We implemented object members' grouping by access modifiers in Wasm Debugger (dotnet/runtime#62627) into:
result
internalProperties
privateProperties.
Thanks to that, in Browser we can see:

However, VS still does not respect the grouping for public members and displays:

We are dropping the information about the grouping between CDP and DAP messages. CDP contains the correct grouping but DAP mixes the information up for the public. It claims that public member is private. It recognizes private and internal/protected groups correctly.
{
"tag":"cdp.receive",
"timestamp":1657630024842,
"metadata":{
"connectionId":0,
"message":{
"id":1030,
"sessionId":"96A2541DCEEFD7DF5CC4C0C1873DFF5B",
"result":{
"result":[
{
"value":{
"type":"string",
"value":"different",
"description":"different"
},
"writable":false,
"isOwn":true,
"name":"publicMember"
}
],
"internalProperties":[
{
"value":{
"type":"string",
"value":"and different here",
"description":"and different here"
},
"writable":false,
"isOwn":true,
"name":"protectedMember"
}
],
"privateProperties":[
{
"value":{
"type":"number",
"value":0,
"description":"0"
},
"writable":true,
"isOwn":true,
"name":"privateMember"
}
]
}
}
},
"level":0
}
DAP:
{
"tag":"dap.send",
"timestamp":1657630024854,
"metadata":{
"connectionId":1,
"message":{
"seq":80,
"type":"response",
"request_seq":14,
"command":"variables",
"success":true,
"body":{
"variables":[
{
"name":"privateMember",
"value":"0",
"evaluateName":".privateMember",
"type":"number",
"variablesReference":0,
"presentationHint":{
"visibility":"private"
}
},
{
"name":"publicMember",
"value":"'different'",
"evaluateName":".publicMember",
"type":"string",
"variablesReference":0,
"presentationHint":{
"visibility":"private"
}
},
{
"name":"protectedMember",
"value":"'and different here'",
"evaluateName":".protectedMember",
"type":"string",
"variablesReference":0,
"presentationHint":{
"visibility":"internal"
}
}
]
}
}
},
"level":0
}
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
bugIssue identified by VS Code Team member as probable bugIssue identified by VS Code Team member as probable bug
Activity
fix: private properties in Blazor apps not grouping correctly
fix: private properties in Blazor apps not grouping correctly (#1484)