Skip to content

Failure getting expression for a provided method call #460

Closed
@Jand42

Description

@Jand42

I you have an erased type provider that generates a call to a method of an F# type, then try to get the expression from a checked project which uses this, there is an error "A call to '...' could not be resolved.

This is thrown by Microsoft.FSharp.Compiler.SourceCodeServices.FSharpExprConvert.ConvExprPrim. It seems that coming from the TP, the call is represented as a Tast.Expr.Op(TOp.ILCall ...) but the type containing the method has F# metadata, so it will not represented by a TILObjModelRepr case when imported.

I have a minimal test project at https://github.com/Jand42/FCS-TP-error
Failing using FSharp.Compiler.Service 1.4.2.1 and FSharp.TypeProviders.StarterPack 1.1.3.76

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions