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

Try to use the FSI as a dll instead of calling fsi.exe #41

Closed
forki opened this issue Feb 17, 2012 · 9 comments
Closed

Try to use the FSI as a dll instead of calling fsi.exe #41

forki opened this issue Feb 17, 2012 · 9 comments
Milestone

Comments

@forki
Copy link
Member

forki commented Feb 17, 2012

A FSI.dll is needed.
Good thing is: @fahadsuhaib built one.

Let's try this out.

@funnelweb
Copy link
Contributor

The F# 3.0 open source compiler comes with what looks like a simple API for interactive compilation and execution. See https://github.com/fsharp/fsharp/blob/master/src/fsharp/vs/SimpleServices.fs

This is part of FSharp.Compiler.dll when open source F# 3.0 is installed. I asked @dsyme and he said this it is the one they use for Try F#. See Microsoft.FSharp.Compiler.Interactive.Runner.InteractiveConsole.

This API is not in the Microsoft FSharp.Compiler.dll so you'd need a private copy of the compiler dll?

@forki
Copy link
Member Author

forki commented Oct 17, 2012

uih. this would help a lot.

@7sharp9
Copy link
Member

7sharp9 commented Oct 29, 2013

I would recommend adding or consuming the modified compiler

There a few options:

The ScriptCs stuff uses a modified compiler available from nuget, its slightly different in that it has evaluation options that are deterministic, as soon as you call for an eval you can retrieve the result from the output stream. This is something that I worked on with Dons help. I believe Tomas also has something almost identical.

To be honest I don't think the eval option is needed as you want to tun the whole fsx file through the compiler anyway.

@forki
Copy link
Member Author

forki commented Oct 29, 2013

Here are some of my goals:

  • Run the build script directly in the FAKE.exe process
  • Allow to set breakpoints in the build.fsx in VS or XS
  • Bundle FAKE directly with a compiler (no path detection of fsi) - this is important for FAKE.Deploy since we want to use the same compiler on client and server side. If we had different versions this could be confusing as @colinbull pointed out.

@7sharp9
Copy link
Member

7sharp9 commented Oct 29, 2013

Do you have a sample in mind to try this out on?

I could take a look when I get a chance.

@forki
Copy link
Member Author

forki commented Oct 29, 2013

Mhm. would be cool if it would work with http://fsharp.github.io/FAKE/gettingstarted.html

@forki
Copy link
Member Author

forki commented Dec 23, 2013

Documentation: http://fsharp.github.io/FSharp.Compiler.Service/interactive.html

@tpetricek @dsyme: Do you think this is a good idea?

@panesofglass
Copy link
Contributor

@forki Yes, this will be the baseline for future scriptcs-fsharp integration, as well.

@forki
Copy link
Member Author

forki commented Jun 18, 2014

FAKE 3.0 alpha is out

@forki forki closed this as completed Jun 18, 2014
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

4 participants