Some user defined symbols started to get CompilerGeneratedAttribute
- Dominant language
- F#
- Stars
- 4.3k
- Forks
- 876
- Avg merge
- 4d 22h
- Merged PRs (30d)
- 144
Description
In this bug report : @auduchinok provided some code that added a DebuggerNonUserCode attribute for user provided code.
https://github.com/dotnet/fsharp/issues/15298, that bug is fixed in the latest retail release of the compiler. However, while reviewing the bug there is also a CompilerGeneratedAttribute for the user provided code. This attribute is probably misleading and should not be produced here. I checked back and this is not a recent introduction, it has been in the compiler at lease since: dotnet sdk 3,0
````
type T() =
let f x = x + 1
````
IL
````
.method assembly hidebysig
instance int32 f (
int32 x
) cil managed
{
.custom instance void [netstandard]System.Runtime.CompilerServices.CompilerGeneratedAttribute::.ctor() = (
01 00 00 00
)
// Method begins at RVA 0x205c
// Header size: 1
// Code size: 4 (0x4)
.maxstack 8
// return x + 1;
IL_0000: ldarg.1
IL_0001: ldc.i4.1
IL_0002: add
IL_0003: ret
} // end of method T::f
````
Contributor guide
Assessment
This issue has not been assessed yet.