Skip to content

Commit 840eae8

Browse files
committed
Fixed merge issues
1 parent cb5cca8 commit 840eae8

File tree

10 files changed

+18
-20
lines changed

10 files changed

+18
-20
lines changed

buildtools/AssemblyCheck/AssemblyCheck.fsproj

-1
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@
33
<PropertyGroup>
44
<OutputType>Exe</OutputType>
55
<TargetFramework>$(FSharpNetCoreProductTargetFramework)</TargetFramework>
6-
<TargetFramework>net8.0</TargetFramework>
76
<DisableImplicitFSharpCoreReference>true</DisableImplicitFSharpCoreReference>
87
</PropertyGroup>
98

buildtools/buildtools.targets

+2-2
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020
BeforeTargets="CoreCompile">
2121

2222
<PropertyGroup>
23-
<FsLexPath Condition="'$(FsLexPath)' == ''">$(ArtifactsDir)\bin\fslex\Release\net8.0\fslex.dll</FsLexPath>
23+
<FsLexPath Condition="'$(FsLexPath)' == ''">$(ArtifactsDir)\bin\fslex\Release\net9.0\linux-x64\fslex.dll</FsLexPath>
2424
</PropertyGroup>
2525

2626
<!-- Create the output directory -->
@@ -44,7 +44,7 @@
4444
BeforeTargets="CoreCompile">
4545

4646
<PropertyGroup>
47-
<FsYaccPath Condition="'$(FsYaccPath)' == ''">$(ArtifactsDir)\bin\fsyacc\Release\net8.0\fsyacc.dll</FsYaccPath>
47+
<FsYaccPath Condition="'$(FsYaccPath)' == ''">$(ArtifactsDir)\bin\fsyacc\Release\net9.0\linux-x64\fsyacc.dll</FsYaccPath>
4848
</PropertyGroup>
4949

5050
<!-- Create the output directory -->

buildtools/fslex/fslex.fsproj

-1
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@
33
<PropertyGroup>
44
<OutputType>Exe</OutputType>
55
<TargetFramework>$(FSharpNetCoreProductTargetFramework)</TargetFramework>
6-
<TargetFramework>net8.0</TargetFramework>
76
<DisableImplicitFSharpCoreReference>true</DisableImplicitFSharpCoreReference>
87
<RollForward Condition="'$(BUILDING_USING_DOTNET)' == 'true'">LatestMajor</RollForward>
98
<NoWarn>$(NoWarn);64;1182;1204</NoWarn> <!--Temporary fix for sourcebuild -->

buildtools/fsyacc/fsyacc.fsproj

-1
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@
33
<PropertyGroup>
44
<OutputType>Exe</OutputType>
55
<TargetFramework>$(FSharpNetCoreProductTargetFramework)</TargetFramework>
6-
<TargetFramework>net8.0</TargetFramework>
76
<DisableImplicitFSharpCoreReference>true</DisableImplicitFSharpCoreReference>
87
<RollForward Condition="'$(BUILDING_USING_DOTNET)' == 'true'">LatestMajor</RollForward>
98
<NoWarn>$(NoWarn);64;1182;1204</NoWarn> <!--Temporary fix for sourcebuild -->

fcs/build.sh

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
#!/usr/bin/env bash
22

3-
dotnet build -c Release buildtools
3+
dotnet build -c Release buildtools/fslex
4+
dotnet build -c Release buildtools/fsyacc
45
dotnet build -c Release src/Compiler
56
dotnet run -c Release --project fcs/fcs-test
67
echo "Binaries can be found here: /artifacts/bin/FSharp.Compiler.Service/Release/netstandard2.0/"

fcs/fcs-test/fcs-test.fsproj

+5-5
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
<PropertyGroup>
44
<OutputType>Exe</OutputType>
5-
<TargetFramework>net8.0</TargetFramework>
5+
<TargetFramework>net9.0</TargetFramework>
66
<DisableImplicitFSharpCoreReference>true</DisableImplicitFSharpCoreReference>
77
</PropertyGroup>
88

@@ -19,9 +19,9 @@
1919
</ItemGroup>
2020

2121
<ItemGroup>
22-
<!-- <PackageReference Include="FSharp.Core" Version="8.0.0" /> -->
23-
<PackageReference Include="Buildalyzer" Version="5.0.1" />
24-
<PackageReference Include="Fable.Core" Version="4.1.0" />
25-
<PackageReference Include="Fable.Import.Browser" Version="1.4.0" />
22+
<!-- <PackageReference Include="FSharp.Core" Version="9.0.0" /> -->
23+
<PackageReference Include="Buildalyzer" Version="*" />
24+
<PackageReference Include="Fable.Core" Version="*" />
25+
<PackageReference Include="Fable.Import.Browser" Version="*" />
2626
</ItemGroup>
2727
</Project>

fcs/service_slim.fs

+5-6
Original file line numberDiff line numberDiff line change
@@ -116,7 +116,7 @@ module internal ParseAndCheck =
116116
SimulatedMSBuildReferenceResolver.getResolver(),
117117
defaultFSharpBinariesDir = FSharpCheckerResultsSettings.defaultFSharpBinariesDir,
118118
reduceMemoryUsage = ReduceMemoryFlag.Yes,
119-
implicitIncludeDir = Path.GetDirectoryName(projectOptions.ProjectFileName),
119+
implicitIncludeDir = !! Path.GetDirectoryName(projectOptions.ProjectFileName),
120120
isInteractive = false,
121121
isInvalidationSupported = true,
122122
defaultCopyFSharpCore = CopyFSharpCoreFlag.No,
@@ -134,15 +134,14 @@ module internal ParseAndCheck =
134134
let dependencyProvider = new DependencyProvider()
135135
let! tcGlobals, tcImports =
136136
TcImports.BuildTcImports (tcConfigP, dependencyProvider)
137-
|> Async.AwaitNodeCode
138137

139138
// Handle type provider invalidation by resetting compiler state
140139
tcImports.GetCcusExcludingBase()
141140
|> Seq.iter (fun ccu ->
142141
ccu.Deref.InvalidateEvent.Add(fun _ -> reset())
143142
)
144143

145-
let assemblyName = projectOptions.ProjectFileName |> Path.GetFileNameWithoutExtension
144+
let assemblyName = !! Path.GetFileNameWithoutExtension(projectOptions.ProjectFileName)
146145
let tcInitial, openDecls0 = GetInitialTcEnv (assemblyName, rangeStartup, tcConfig, tcImports, tcGlobals)
147146
let tcInitialState = GetInitialTcState (rangeStartup, assemblyName, tcConfig, tcGlobals, tcImports, tcInitial, openDecls0)
148147

@@ -166,7 +165,7 @@ module internal ParseAndCheck =
166165
topAttrsOpt: TopAttribs option, tcImplFilesOpt: CheckedImplFile list option, compilerState) =
167166
let assemblyRef = mkSimpleAssemblyRef "stdin"
168167
let access = tcState.TcEnvFromImpls.AccessRights
169-
let symbolUses = Choice2Of2 TcSymbolUses.Empty
168+
let symbolUses = Choice2Of2 (async { return seq { } })
170169
let dependencyFiles = parseResults |> Seq.map (fun x -> x.DependencyFiles) |> Array.concat
171170
let getAssemblyData () = None
172171
let details = (compilerState.tcGlobals, compilerState.tcImports, tcState.Ccu, tcState.CcuSig, symbolUses, topAttrsOpt,
@@ -313,12 +312,12 @@ type InteractiveChecker internal (compilerStateCache) =
313312
let ctok = CompilationThreadToken()
314313
let flatErrors = compilerState.tcConfig.flatErrors
315314
let errors, diagnosticsLogger, _loggerProvider = CompileHelpers.mkCompilationDiagnosticsHandlers(flatErrors)
316-
let exitCode =
315+
let exnOpt =
317316
CompileHelpers.tryCompile diagnosticsLogger (fun exiter ->
318317
CompileFromTypedAst (ctok, compilerState.tcGlobals, compilerState.tcImports, tcState.Ccu,
319318
tcImplFiles, topAttrs, compilerState.tcConfig, outFile, diagnosticsLogger, exiter))
320319

321-
return errors.ToArray(), exitCode
320+
return errors.ToArray(), exnOpt
322321
}
323322

324323
/// Parses and checks the whole project, good for compilers (Fable etc.)

src/Compiler/Checking/NicePrint.fs

+1
Original file line numberDiff line numberDiff line change
@@ -1694,6 +1694,7 @@ module InfoMemberPrinting =
16941694
|> PrintTypes.layoutCsharpCodeAnalysisIlAttributes denv (mi.RawMetadata.Return.CustomAttrs) (squareAngleReturn >> (@@))
16951695
let paramLayouts =
16961696
minfo.GetParamDatas (amap, m, minst)
1697+
|> List.map (List.map fst)
16971698
|> List.head
16981699
|> List.zip (mi.ParamMetadata)
16991700
|> List.map(fun (ilParams,paramData) ->

src/Compiler/Driver/fsc.fs

+2-2
Original file line numberDiff line numberDiff line change
@@ -1276,14 +1276,14 @@ let CompileFromTypedAst
12761276
typedImplFiles,
12771277
topAttrs,
12781278
tcConfig: TcConfig,
1279-
outfile,
1279+
outfile: string,
12801280
diagnosticsLogger,
12811281
exiter: Exiter
12821282
) =
12831283

12841284
let tcImportsCapture = None
12851285
let dynamicAssemblyCreator = None
1286-
let assemblyName = Path.GetFileNameWithoutExtension(outfile)
1286+
let assemblyName = !! Path.GetFileNameWithoutExtension(outfile)
12871287
// Doubling here tcImports as frameworkTcImports, seems to work...
12881288
let frameworkTcImports = tcImports
12891289
let pdbfile = None

src/Compiler/Service/service.fsi

+1-1
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ open FSharp.Compiler.Driver
2323

2424
module internal CompileHelpers =
2525
val mkCompilationDiagnosticsHandlers: bool -> ResizeArray<FSharpDiagnostic> * DiagnosticsLogger * IDiagnosticsLoggerProvider
26-
val tryCompile: DiagnosticsLogger -> (StopProcessingExiter -> unit) -> int
26+
val tryCompile: DiagnosticsLogger -> (StopProcessingExiter -> unit) -> exn option
2727

2828
/// Used to parse and check F# source code.
2929
[<Sealed; AutoSerializable(false)>]

0 commit comments

Comments
 (0)