Skip to content

Commit 4a64826

Browse files
authored
Merge branch 'main' into main
2 parents a857a3f + ea81036 commit 4a64826

File tree

7 files changed

+43
-17
lines changed

7 files changed

+43
-17
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ You find a version of this plugin pre-packaged with the FOSS debugger from Samsu
2525

2626
# Requirements
2727

28-
* .NET 6.0/7.0 SDK - https://dotnet.microsoft.com/download/dotnet/7.0
28+
* .NET 8.0/9.0 SDK - https://dotnet.microsoft.com/download/dotnet/7.0
2929

3030
* VS Code C# plugin - Ionide's debugging capabilities rely on either the [Omnisharp](https://github.com/OmniSharp/omnisharp-vscode) debugger or [netcoredbg](https://github.com/muhammadsammy/free-omnisharp-vscode).
3131

RELEASE_NOTES.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,9 @@
1+
### 7.23.0 - 09.02.2024
2+
3+
* [Update watcher.fsx to support nullness](https://github.com/ionide/ionide-vscode-fsharp/commit/5fcad2926ccf09d7c987ab6a409c481dda2c4610) from @isaacabraham
4+
* [Enable unnecessary parentheses analyzer by default](https://github.com/ionide/ionide-vscode-fsharp/pull/2057) from @brianrourkeboll
5+
* Update to FSAC 0.76.2 . Check out the [release notes](https://github.com/fsharp/FsAutoComplete/releases/tag/v0.76.1) for more details.
6+
17
### 7.22.0 - 24.11.2024
28

39
* Update to FSAC 0.75.0. This release adds support for F# 9 language features and .NET 9 SDKs and tooling.

paket.lock

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -241,4 +241,4 @@ STORAGE: PACKAGES
241241
RESTRICTION: == netstandard2.0
242242
NUGET
243243
remote: https://api.nuget.org/v3/index.json
244-
fsautocomplete (0.75)
244+
fsautocomplete (0.76.2)

release/CHANGELOG.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,9 @@
1+
### 7.23.0 - 09.02.2024
2+
3+
* [Update watcher.fsx to support nullness](https://github.com/ionide/ionide-vscode-fsharp/commit/5fcad2926ccf09d7c987ab6a409c481dda2c4610) from @isaacabraham
4+
* [Enable unnecessary parentheses analyzer by default](https://github.com/ionide/ionide-vscode-fsharp/pull/2057) from @brianrourkeboll
5+
* Update to FSAC 0.76.2 . Check out the [release notes](https://github.com/fsharp/FsAutoComplete/releases/tag/v0.76.1) for more details.
6+
17
### 7.22.0 - 24.11.2024
28

39
* Update to FSAC 0.75.0. This release adds support for F# 9 language features and .NET 9 SDKs and tooling.

release/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ You find a version of this plugin pre-packaged with the FOSS debugger from Samsu
2525

2626
# Requirements
2727

28-
* .NET 6.0/7.0 SDK - https://dotnet.microsoft.com/download/dotnet/7.0
28+
* .NET 8.0/9.0 SDK - https://dotnet.microsoft.com/download/dotnet/7.0
2929

3030
* VS Code C# plugin - Ionide's debugging capabilities rely on either the [Omnisharp](https://github.com/OmniSharp/omnisharp-vscode) debugger or [netcoredbg](https://github.com/muhammadsammy/free-omnisharp-vscode).
3131

release/package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -863,7 +863,7 @@
863863
]
864864
},
865865
"FSharp.unnecessaryParenthesesAnalyzer": {
866-
"default": false,
866+
"default": true,
867867
"description": "Enables detection of unnecessary parentheses",
868868
"type": "boolean"
869869
},
@@ -1831,5 +1831,5 @@
18311831
"type": "git",
18321832
"url": "https://github.com/ionide/ionide-vscode-fsharp.git"
18331833
},
1834-
"version": "7.22.0"
1834+
"version": "7.23.0"
18351835
}

release/watcher/watcher.fsx

Lines changed: 26 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -2,13 +2,20 @@ fsi.AddPrinter (fun (_: obj) ->
22
let fsiAsm = "FSI-ASSEMBLY"
33

44
let asmNum (asm:System.Reflection.Assembly) =
5-
asm.GetName().Name.Replace(fsiAsm, "") |> System.Int32.TryParse |> fun (b,v) -> if b then v else 0
5+
match asm.GetName().Name with
6+
| null -> 0
7+
| name -> name.Replace(fsiAsm, "") |> System.Int32.TryParse |> fun (b,v) -> if b then v else 0
68

79
let fsiAssemblies =
810
// use multiple assemblies (FSI-ASSEMBLY1, FSI-ASSEMBLY2...) if single isn't found
911
let fsiAsms =
1012
System.AppDomain.CurrentDomain.GetAssemblies()
11-
|> Array.filter (fun asm -> asm.GetName().Name.StartsWith fsiAsm)
13+
|> Array.filter (fun asm ->
14+
match asm.GetName().Name with
15+
| null -> false
16+
| name -> name.StartsWith fsiAsm
17+
)
18+
1219
fsiAsms
1320
|> Array.tryFind (fun asm -> asm.GetName().Name = fsiAsm)
1421
|> function
@@ -30,9 +37,14 @@ fsi.AddPrinter (fun (_: obj) ->
3037
|> Seq.sortBy (fun (_, (i, _)) -> i) //order by original index
3138
|> Seq.map (fun (_, (_, pi)) -> pi.Name, pi.GetValue(null, Array.empty), pi.PropertyType) //discard ordering index, project usuable watch value
3239

40+
let isFsiAssembly (ty:System.Type) =
41+
match ty.FullName with
42+
| null -> false
43+
| name -> name.StartsWith("FSI")
44+
3345
let getRecords (fsiAssembly:System.Reflection.Assembly) =
3446
fsiAssembly.GetTypes()
35-
|> Seq.filter (fun ty -> ty.FullName.StartsWith("FSI"))
47+
|> Seq.filter isFsiAssembly
3648
|> Seq.filter (Reflection.FSharpType.IsRecord)
3749
|> Seq.map (fun ty ->
3850
let flds =
@@ -43,9 +55,12 @@ fsi.AddPrinter (fun (_: obj) ->
4355

4456
let getUnions (fsiAssembly:System.Reflection.Assembly) =
4557
fsiAssembly.GetTypes()
46-
|> Seq.filter (fun ty -> ty.FullName.StartsWith("FSI"))
58+
|> Seq.filter isFsiAssembly
4759
|> Seq.filter (Reflection.FSharpType.IsUnion)
48-
|> Seq.filter (fun ty -> ty.BaseType.Name = "Object") //find DU declaration not DU cases
60+
|> Seq.filter (fun ty ->
61+
match ty.BaseType with
62+
| null -> false
63+
| ty -> ty.Name = "Object") //find DU declaration not DU cases
4964
|> Seq.map (fun ty ->
5065
let flds =
5166
Reflection.FSharpType.GetUnionCases ty
@@ -60,7 +75,7 @@ fsi.AddPrinter (fun (_: obj) ->
6075

6176
let getFuncs (fsiAssembly:System.Reflection.Assembly) =
6277
fsiAssembly.GetTypes()
63-
|> Seq.filter (fun ty -> ty.FullName.StartsWith("FSI"))
78+
|> Seq.filter isFsiAssembly
6479
|> Seq.filter (Reflection.FSharpType.IsModule)
6580
|> Seq.choose (fun ty ->
6681
let meth =
@@ -97,10 +112,9 @@ fsi.AddPrinter (fun (_: obj) ->
97112

98113
let fromAssemblies folder =
99114
fsiAssemblies
100-
|> Array.toList
101-
|> Seq.map (fun asm -> asmNum asm, asm)
102-
|> Seq.sortByDescending fst // assume later/higher assembly # always shadows
103-
|> Seq.fold folder (Set.empty, Seq.empty)
115+
|> Array.map (fun asm -> asmNum asm, asm)
116+
|> Array.sortByDescending fst // assume later/higher assembly # always shadows
117+
|> Array.fold folder (Set.empty, Seq.empty)
104118
|> snd
105119

106120
let arrangeVars (state: Set<string> * seq<string>) (step, asm) =
@@ -123,7 +137,7 @@ fsi.AddPrinter (fun (_: obj) ->
123137
let shadowed = (fst state).Contains name
124138
let parms =
125139
parms
126-
|> Seq.map (fun (n, t) -> n + ": " + t)
140+
|> Seq.map (fun (n, t) -> $"{n}: {t}")
127141
|> String.concat "; "
128142
formatVarsAndFuncs name parms typ step shadowed, name)
129143
let names =
@@ -199,4 +213,4 @@ fsi.AddPrinter (fun (_: obj) ->
199213
}
200214
|> Async.Start
201215

202-
null)
216+
"")

0 commit comments

Comments
 (0)