-
Notifications
You must be signed in to change notification settings - Fork 5.3k
Closed
Labels
Description
Currently:
public class Test
{
public List<int> list { get { return new List<int>() { 1, 2 }; } }
public int[] array { get { return new int[] { 11, 22 }; } }
public string text { get { return "text"; } }
}
Custom getters are displayed in Visual Studio as:
{{
"get": {
"type": "function",
"objectId": "dotnet:object:2:methodId:8",
"className": "Function",
"description": "get list ()",
"methodId": 8,
"objectIdValue": "dotnet:object:2"
},
"name": "list",
"isOwn": true
}}
and arrow used to expand properties triggers "Runtime.callFunctionOn".
In Browser no custom getter values are displayed because arrow triggers "Runtime.getProperties" and we are getting exception caused by casting string to integer in RuntimeGetPropertiesInternal.
Goal:
both in VS and Browser display the accessor in a form of values, not an expendable function, so like in Console App:
{
"value": {
"type": "object",
"value": null,
"description": "Count = 2",
"className": "System.Collections.Generic.List<int>",
"objectId": "dotnet:object:3"
},
"writable": false,
"isOwn": true,
"name": "list"
}