Hi Steve,

A comment about your monadic pipeline keyword suggestion.

In your blog post you give this example:

1
2
3
4
5
6
7
8
let result = myBuilder {  


  let result1 = initialValue
  let! r2 = r1 |> f1
  let! r3 = r2 |> f2
  let! r4 = r3 |> f3
  return r4 }

You don't need the intermediate values and want it to look like this

1
2
3
4
5
let result =
   initialValue
  |> f1
  |> f2
  |> f3

Let's say your myBuilder computation expression makes values of type MyBuilder<'a>.

f1 has type 'a -> MyBuilder<'b>
f2 has type 'b -> MyBuilder<'c>
f3 has type 'c -> MyBuilder<'d>

If we define

let (>>=) x f = myBuilder.Bind(x, f)

then we can compose the functions like this:

let f x = f1 x >>= f2 >>= f3

where f has type 'a -> MyBuilder<'d>. So it is not necessary for Microsoft to introduce a special keyword,
you can define it yourself.

By on 9/11/2009 12:14 PM ()

Thanks Felix. I have acknowledged you and your solution on an updated post here: [link:stevehorsfield.wordpress.com]

By on 9/12/2009 1:12 AM ()

Hi,What do you mean by "5) Direct support for targeting Windows executables"?thanks,Kurt

By on 9/14/2009 2:24 AM ()

In Visual Studio 2008 with the F# CTP, the "add project" options only allow a console application or an F# library.

You can manually edit the project settings to change this, although I had some problems with the change being correctly saved. The most reliable method I found was editing the MSBuild project file directly and then reloading in Visual Studio. I just think that:

1) The project settings should save correctly

2) There is no reason not to allow Add New Project to include an option for F# Windows Application

By on 9/14/2009 3:00 AM ()

I see - indeed. Thanks.Incidentally, it might be faster (and the F# team welcomes you) to file future bugs and suggestions ts fsbugs directly.  (It sure will give you better and faster feedback).Kurt

By on 9/14/2009 5:06 AM ()
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