diff options
author | Ankit Jain <radical@gmail.com> | 2019-02-22 16:00:41 +0300 |
---|---|---|
committer | Ludovic Henry <luhenry@microsoft.com> | 2019-02-22 16:00:41 +0300 |
commit | a4fada390083307269cde9430dafeb7e16066580 (patch) | |
tree | 136d79730c974dd994de60d2ea903008a4a87b63 /packaging | |
parent | 3be2390665fba6d9ce19b72e165d43d3a6915ba6 (diff) |
[fsharp] Fix a type inference error introduced by recent changes (#13109)
```
@/external/bockbuild/builds/fsharp-fsharp-6624925/src/scripts/fssrgen.fsx(334,28): error FS0041: A unique overload for method 'GetFileNameWithoutExtension' could not be determined based on type information prior to this program point.
A type annotation may be needed. Candidates: System.IO.Path.GetFileNameWithoutExtension(path: System.ReadOnlySpan<char>) : System.ReadOnlySpan<char>, System.IO.Path.GetFileNameWithoutExtension(path: string) : string
[@/external/bockbuild/builds/fsharp-fsharp-6624925/src/fsharp/FSharp.Build-proto/FSharp.Build-proto.fsproj]
```
Diffstat (limited to 'packaging')
-rw-r--r-- | packaging/MacSDK/fsharp.py | 3 | ||||
-rw-r--r-- | packaging/MacSDK/patches/fsharp-GetFileNameWithoutExtension-type-inference.patch | 13 |
2 files changed, 15 insertions, 1 deletions
diff --git a/packaging/MacSDK/fsharp.py b/packaging/MacSDK/fsharp.py index fc3520d937c..bc85ba33654 100644 --- a/packaging/MacSDK/fsharp.py +++ b/packaging/MacSDK/fsharp.py @@ -12,7 +12,8 @@ class FsharpPackage(GitHubTarballPackage): 'patches/fsharp-string-switchName.patch', 'patches/fsharp-path-overloads.patch', 'patches/fsharp-debug-pinvoke-fix.patch', - 'patches/fsharp-IsPathRooted-type-inference.patch']) + 'patches/fsharp-IsPathRooted-type-inference.patch', + 'patches/fsharp-GetFileNameWithoutExtension-type-inference.patch']) def prep(self): Package.prep(self) diff --git a/packaging/MacSDK/patches/fsharp-GetFileNameWithoutExtension-type-inference.patch b/packaging/MacSDK/patches/fsharp-GetFileNameWithoutExtension-type-inference.patch new file mode 100644 index 00000000000..14e9444b1de --- /dev/null +++ b/packaging/MacSDK/patches/fsharp-GetFileNameWithoutExtension-type-inference.patch @@ -0,0 +1,13 @@ +diff --git a/src/scripts/fssrgen.fsx b/src/scripts/fssrgen.fsx +index 0bee9b79e..e6ceda11e 100644 +--- a/src/scripts/fssrgen.fsx ++++ b/src/scripts/fssrgen.fsx +@@ -329,7 +329,7 @@ let StringBoilerPlate filename = + // END BOILERPLATE + " + +-let RunMain(filename, outFilename, outXmlFilenameOpt, projectNameOpt) = ++let RunMain(filename:string, outFilename, outXmlFilenameOpt, projectNameOpt) = + try + let justfilename = System.IO.Path.GetFileNameWithoutExtension(filename) + if justfilename |> Seq.exists (fun c -> not(System.Char.IsLetterOrDigit(c))) then |