-
Notifications
You must be signed in to change notification settings - Fork 16
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
ReferenceAssemblyAttribute in System.Diagnostics.StackTrace? #25
Comments
I am sorry, but it is unclear what the issue is. Does it refer to Could you please provide some steps to reproduce the issue? |
Yes. It is attempting to use the attribute in System.Diagnostic.StackTrace. It did also create it's own version of is the attribute on my assembly. But, that's not the one who's ctor is invoked. I'll try to figure out a simple test case for ya. |
Refasmer tries to find ReferenceAssemblyAttribute in processed assembly before creating it's own one. |
Checking over the TypeDef table on the original assembly, I don't see any entry for it. Checking the TypeRef table, I don't see any reference to it. On the resulting assembly, though, I do see, at the end of the TypeRef table, a new entry for ReferenceAssemblyAttribute from System.Diagnostics.StackTrace. This is dotPeeks view of the TypeRef that was apparently created: So, the input assembly has no TypeRef to System.Diagnostics.StackTrace, but the output assembly does. I've been going over the refasmer code, and I can't really see anyway this could be possible, yet. But, there it is.... and I've rerun it a few times now and produced the same thing. |
I do see that it tries to search all TypeRef's for a matching type name. So, if the original assembly had a TypeRef to the type in System.Diagnostics.StackTrace, I do see how it would be copied over. But, still, can't find such a thing in the original assembly. |
Attempting to make a reference assembly from another .NET 6 assembly. .NET 6 assembly... seems pretty normal. No ReferenceAssemblyAttribute on it.... run refasmer.
refasmer -o foo.dll -r bar.dll
Looking in foo.dll, in ildasm, I see:
.custom instance void [System.Diagnostics.StackTrace]System.Runtime.CompilerServices.ReferenceAssemblyAttribute::.ctor() = ( 01 00 00 00 )
System.Diagnostics.StackTrace? What?
The text was updated successfully, but these errors were encountered: