You defined a method but called it as if it were a fun. (Sometimes the fn syntax works as a shortcut, but not in all cases.)

By on 4/27/2010 4:08 PM ()

Well, I'm not an expert (yet) but this code works:

type Class2A () =

abstract member Foo : int * int -> int

default this.Foo(x, y) = x + y

type Class2B () =

inherit Class2A()

override this.Foo(x, y) = (base.Foo(x, y)) + 1

I believe it's something to do with function currying. This code takes a tuple as the function's input, therefore denying any sort of curried mess.

By on 4/27/2010 2:19 PM ()

Interesting one! Nice sample code. It looks like a bug to me. I can't

find any documentation on what to expect here, or on the error message,

but, based on the code for a member with one argument, your code for two arguments looks correct.

I've typed it in, and get the same error message.

By on 6/7/2009 5:12 PM ()
IntelliFactory Offices Copyright (c) 2011-2012 IntelliFactory. All rights reserved.
Home | Products | Consulting | Trainings | Blogs | Jobs | Contact Us | Terms of Use | Privacy Policy | Cookie Policy
Built with WebSharper