fsprojects / FSharp.TypeProviders.SDK

The SDK for creating F# type providers
https://fsprojects.github.io/FSharp.TypeProviders.SDK/
MIT License
298 stars 94 forks source link

fix 188 - Type replacement should apply to static parameter types #189

Closed dsyme closed 6 years ago

dsyme commented 6 years ago

Fix https://github.com/fsprojects/FSharp.TypeProviders.SDK/issues/188

Thorium commented 6 years ago

After the latest changes my type provider fails for:

FSC: error FS3047: Unknown static argument kind 'MyProject.MyEnum' when resolving a reference to a provided type or method 'MyProvider,MyEnumParam="1"'

error FS1109: A reference to the type 'MyProvider,MyEnumParam="1"' in assembly 'MyProject' was found, but the type could not be found in that assembly

Here, MyProject.MyEnum is a non-design-time enum that is a static parameter for the type provider constructor.

dsyme commented 6 years ago

@Thorium could you point me to the code for the type provider please?

dsyme commented 6 years ago

@Thorium I can see the problem, will fix it and add more tests, thanks

Thorium commented 6 years ago

This is now working with the latest changeset.