You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The F# compiler can give a Type mismatch when building 'expr' error on two types which should be the same during the running of a TP.
Found when building https://github.com/dotnet-websharper/ui and this is a breaking change introduced by #332, works with the previous state (e9d2c93).
Example of error:
The type provider 'WebSharper.UI.Templating.TemplatingProvider' reported an error in the context of provided type 'WebSharper.UI.Templating.Template,pathOrHtml="index.html,template.html",clientLoad="2",legacyMode="3"+template', member 'NewDescription'. The error: Type mismatch when building 'expr': the expression has the wrong type. Expected 'WebSharper.UI.Var`1[System.String]', but received type 'WebSharper.UI.Var`1[System.String]'.�Parameter name: receivedType
The WebSharper.UI.Templating type provider uses expression splicing extensively, probably the issue is related to that, I am experimenting to find a minimal failing test case and will update this description if found.
#332 was actually done to build methods that have parameters or return types that are RuntimeType generics (like Task<'t> or Async<'t>) of generated type.
Previously, the handling of method parameters used t.MakeGeneric which returns such generic that doesn't work then for generation.. I may have broken your usecase in the process.
A repro would ease the fix
Description
The F# compiler can give a
Type mismatch when building 'expr'
error on two types which should be the same during the running of a TP.Found when building https://github.com/dotnet-websharper/ui and this is a breaking change introduced by #332, works with the previous state (e9d2c93).
Example of error:
The WebSharper.UI.Templating type provider uses expression splicing extensively, probably the issue is related to that, I am experimenting to find a minimal failing test case and will update this description if found.
Repro steps
build WS-Update
build WS-BuildRelease
Expected behavior
WebSharper.UI.Templating.Tests
project should build as before, now fails on erased TP use.Actual behavior
Build errors.
Known workarounds
Use earlier state of FSharp.TypeProviders.SDK.
Related information
The text was updated successfully, but these errors were encountered: