Absolute symbols path in PEHeaders #967
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Consider the following code:
If
outputAssemblyPathis an absolute path, the symbol path written in the dll PE Headers will be absolute as well.This can lead to confusion of the debugger if somehow the assembly is loaded from a different path.
Also, if the assembly is loaded with
AssemblyLoadContext.LoadFromStreamto prevent the runtime to lock the assembly file, an attached debugger will likely lock the pdb file as it will still be able to find it (as the PE Header has the full path information) - while the expected behavior would have been for the debugger to pick the symbols information from the symbols stream passed to the AssemblyLoadContext.In Unity CoreCLR editor context we worked around that by writing the assembly to a custom stream, but it would be nicer if the PE header would be filled with a path relative to the assembly output directory - the same way csc seems to behave.