Could you show a sample of the problem with "new" (perhaps a screenshot)? We always aim to improve error messages and documentation, especially if something frustrates.

Code that is "close" to being well-indented can be converted very quickly - for example I've converted about 4000 lines in 10 minutes. However we certainly need more examples of "standard" formattings, covering the basic techniques to dig yourself out of trouble.

thanks

don

By on 9/10/2006 10:26 AM ()

The code fragment is:

1
2
3
4
5
6
7
type input =
    class
        val mutable escStrobe : bool
        val pads : gamepad []
        val map : (Keys * int * int) list
        new() = {
                pads = Array.init numPlayers (fun _ -> new gamepad());

The problem was that it took me a while to figure out that I had to move the line starting with "pads" so far to the right. As a "C" programmer I think of the open curly brace as having just one level of indenting. But in this situation F# thinks it needs two levels of indenting.

By on 9/10/2006 6:09 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