T O P I C R E V I E W |
Uniwares |
Posted - Nov 16 2020 : 12:37:36 PM I am getting mixed results when using the "Copy Declaration" on the entries in the HCB view on C# classes. Sometimes it copies the declaration correctly, sometimes I get two entries separated by a char[255], sometimes the entry has no method return type. I am pretty sure this has to do with the duplicate entries I am seeing.
For example, on the System.Diagnostics.Trace type:
Assert(Boolean condition, System.String message, System.String detailMessage)
static Void Assert(Boolean condition, System.String message, System.String detailMessage) both lines are copies from the same source entry.
Or this one:
static Void Fail(System.String message)
static Void Fail(System.String message, System.String detailMessage)[FF]static Void Fail(System.String message) In place of the [FF] is a char[255] that actually only shows up when pasting into Notepad++ My bet: the char 255 points to something bad and might give a lead where all the problems come from.
|
11 L A T E S T R E P L I E S (Newest First) |
Uniwares |
Posted - Nov 18 2020 : 08:16:59 AM Cant say. Today I was trying to find a pattern, but there seems to be none. for some assemblies its happening always, for others never. There is no pattern in method type or parameters, only can say that no method without parameters seem to cause this behaviour, but the type of parameters seems irrelevant. |
feline |
Posted - Nov 18 2020 : 08:13:41 AM It was worth asking on the off chance.
I will keep an eye on this, and keep checking in the background, but given how easily you can trigger this problem I really should have reproduced this by now.
I have even taken the steps from case=142203, which produces a corrupt VA symbol database for C# when using NuGet, and I still cannot get this problem to reproduce. There has to be some form of odd trigger, but I am not sure where else to look for it. |
Uniwares |
Posted - Nov 17 2020 : 1:14:45 PM Sorry, cant share anymore now. Anyway the FF char is appearing here in pretty much any assembly that I copy from, so its not project specific. I�d point to a string termination error in VA somewhere. |
feline |
Posted - Nov 17 2020 : 1:10:36 PM It looks like the most recent version of your Q7 solution I have is from May 2020, and there is no symbol containing "DataContext" in the Find Symbol dialog.
If you are able to share a current version, purely for testing purposes, I will have a look and see if I can get the same result. I want to say VA symbol database corruption, but I have no basis for this, and even if I assume so, where on earth is the FF character coming from? That seems quite random for copying a declaration from the HCB. |
Uniwares |
Posted - Nov 17 2020 : 10:58:09 AM This is from the Q7 solution, you might have this class complete actually. |
feline |
Posted - Nov 17 2020 : 10:51:56 AM What class / type is this from? I have a test project you sent me, so I can hopefully try the same type here, and see what I get.
I don't get why we seem to be getting such different results here. |
Uniwares |
Posted - Nov 17 2020 : 09:31:06 AM Thats what I get...
Note please that some methods have curly brackets, some dont, some of the above methods are twice with slightly different definitions, in the HCB they appear identical, although the tooltip of some shows the difference it copied. |
feline |
Posted - Nov 17 2020 : 09:08:44 AM I have just installed Notepad++, I don't use this as my text editor personally, so had to install it. So default settings. The only thing I have changed is to turn on wordwrap via the toolbar button. I have attached a screen shot of what I am getting, along with notes on what I did. I am assuming the [FF] character should be obvious if it was happening with the default settings, but it's always possible it isn't obvious.
Ah, got the [FF] character by copying a control character from another location and pasting it into Notepad++. Got lucky that the control character in question was [FF]. So definitely nothing showing up here.
|
Uniwares |
Posted - Nov 16 2020 : 2:28:59 PM I get this reliable, even in different classes. selecting the first method of the symbol, copy, paste into notepad++, select the second method, copy, paste into notepad++, i get now the first one + char[255] + second one. seems to work for any C# class with methods. |
feline |
Posted - Nov 16 2020 : 1:42:22 PM If you change HCB to show a different class, and then change it back again to show:
System.Diagnostics.Trace
and do the copy again, do you get the same confused results? This certainly looks like a related problem, except that I cannot reproduce it here. I have tried on two different systems, one with my normal settings and one with your settings, and no sign of the problem at all.
So I am wondering if this is a stable effect or if there is a random element for you. |
Uniwares |
Posted - Nov 16 2020 : 12:41:15 PM Addendum: the "Expand Descendants and copy" menu entry doesn't make much sense when not on a .h file as shown in the documentation. Or, when in a C# file. |
|
|