Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Decompiler Bug or F# Quotation Bug: generic empty list treated as call #9

Closed
GoogleCodeExporter opened this issue Jun 21, 2015 · 4 comments

Comments

@GoogleCodeExporter
Copy link

Possibly a Quotation bug, resolution uncertain:

> let xl = [];;

val xl : 'a list

> <@ xl @>;;

  <@ xl @>;;
  ^^^^^^^^

C:\Users\Stephen\AppData\Local\Temp\stdin(9,1): error FS0030: Value 
restriction. The value 'it' has been inferred to have generic type
    val it : Expr<'_a list>    
Either define 'it' as a simple data term, make it a function with explicit 
arguments or, if you do not intend for it to be generic, add a type annotation.
> <@@ xl @@>;;
val it : Expr =
  Call (None,
      Microsoft.FSharp.Collections.FSharpList`1[System.Object] xl[Object](), [])
    {CustomAttributes = [NewTuple (Value ("DebugRange"),
          NewTuple (Value ("stdin"), Value (10), Value (4), Value (10),
                    Value (6)))];
     Type = Microsoft.FSharp.Collections.FSharpList`1[System.Object];}
> source <@ xl @>
;;
val it : string = "xl()"

Original issue reported on code.google.com by stephen....@gmail.com on 20 Feb 2011 at 2:55

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant