Skip to content
This repository was archived by the owner on Jan 3, 2019. It is now read-only.

Commit c142474

Browse files
committed
fix pretty printing in FSI by referencing FSharp.Compiler.Interactive.Settings.dll
1 parent c479f5e commit c142474

File tree

4 files changed

+12
-11
lines changed

4 files changed

+12
-11
lines changed

MonoDevelop.FSharpi.Service/MonoDevelop.FSharpInteractive.Service.fsproj

Lines changed: 7 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
1+
<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
22
<PropertyGroup>
33
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
44
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
@@ -19,19 +19,16 @@
1919
<DefineConstants>DEBUG</DefineConstants>
2020
<ErrorReport>prompt</ErrorReport>
2121
<ExternalConsole>true</ExternalConsole>
22-
<PlatformTarget>
23-
</PlatformTarget>
22+
<PlatformTarget></PlatformTarget>
2423
</PropertyGroup>
2524
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
2625
<Optimize>true</Optimize>
2726
<OutputPath>..\bin</OutputPath>
28-
<DefineConstants>
29-
</DefineConstants>
27+
<DefineConstants></DefineConstants>
3028
<ErrorReport>prompt</ErrorReport>
3129
<ExternalConsole>true</ExternalConsole>
3230
<GenerateTailCalls>true</GenerateTailCalls>
33-
<PlatformTarget>
34-
</PlatformTarget>
31+
<PlatformTarget></PlatformTarget>
3532
</PropertyGroup>
3633
<PropertyGroup>
3734
<FSharpTargetsPath>$(MSBuildExtensionsPath32)\Microsoft\VisualStudio\v$(VisualStudioVersion)\FSharp\Microsoft.FSharp.Targets</FSharpTargetsPath>
@@ -47,7 +44,9 @@
4744
<Reference Include="System" />
4845
<Reference Include="System.Core" />
4946
<Reference Include="System.Numerics" />
50-
<Reference Include="FSharp.Compiler.Interactive.Settings" />
47+
<Reference Include="FSharp.Compiler.Interactive.Settings">
48+
<HintPath>lib\FSharp.Compiler.Interactive.Settings.dll</HintPath>
49+
</Reference>
5150
</ItemGroup>
5251
<ItemGroup>
5352
<Compile Include="AssemblyInfo.fs" />

MonoDevelop.FSharpi.Service/Program.fs

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ open System.Text
55
open Newtonsoft.Json
66
open Microsoft.FSharp.Compiler.SourceCodeServices
77
open Microsoft.FSharp.Compiler.Interactive.Shell
8+
89
open MonoDevelop.FSharp.Shared
910
/// Wrapper for fsi with support for returning completions
1011
module CompletionServer =
@@ -21,9 +22,10 @@ module CompletionServer =
2122

2223
let serializer = JsonSerializer.Create()
2324

24-
let fsiConfig = FsiEvaluationSession.GetDefaultConfiguration(Settings.fsi, true)
25-
let fsiSession = FsiEvaluationSession.Create(fsiConfig, argv, inStream, outStream, outStream, true)
25+
let fsiConfig = FsiEvaluationSession.GetDefaultConfiguration(Microsoft.FSharp.Compiler.Interactive.Settings.fsi, true)
2626

27+
let fsiSession = FsiEvaluationSession.Create(fsiConfig, argv, inStream, outStream, outStream, true)
28+
2729
let (|Input|_|) (command: string) =
2830
if command.StartsWith("input ") then
2931
Some(command.[6..])
Binary file not shown.

paket.dependencies

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
source https://nuget.org/api/v2/
22

33
nuget ExtCore framework: >= net40
4-
nuget FSharp.Compiler.Service >= 2
4+
nuget FSharp.Compiler.Service = 2.0.0.6
55
nuget FSharp.Core = 4.0.0.1
66
nuget Fantomas framework: >= net45
77
nuget FSharp.Compiler.CodeDom 0.9.2 framework: >= net40

0 commit comments

Comments
 (0)