dotnet / fsharp

The F# compiler, F# core library, F# language service, and F# tooling integration for Visual Studio
https://dotnet.microsoft.com/languages/fsharp
MIT License
3.9k stars 782 forks source link

Re-implement `nameof` operator #2287

Closed vasily-kirichenko closed 7 years ago

vasily-kirichenko commented 7 years ago

As @dsyme suggested here https://github.com/fsharp/fslang-design/issues/48#issuecomment-227407028, it's much simpler and "the right way" in general to implement the feature in TypeChecker, namely in TcFunctionApplicationThen function, at this point https://github.com/Microsoft/visualfsharp/blob/master/src/fsharp/TypeChecker.fs#L8274

We should port all the wonderful tests @forki created in his old PR https://github.com/Microsoft/visualfsharp/pull/13

vasily-kirichenko commented 7 years ago

Implemented in https://github.com/Microsoft/visualfsharp/pull/2290