Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/master' into v1.3
Browse files Browse the repository at this point in the history
  • Loading branch information
wallymathieu committed Feb 5, 2023
2 parents 6d7976a + c525bcb commit 87cde45
Show file tree
Hide file tree
Showing 4 changed files with 20 additions and 16 deletions.
3 changes: 3 additions & 0 deletions RELEASE_NOTES.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
#### 1.3.3 - February 4 2023
- Fix missing zero overload for voption

#### 1.3.2 - December 2 2022
- Applicative Computation Expressions
- Support for ValueOption, ValueTask and ValueTuple
Expand Down
18 changes: 2 additions & 16 deletions RELEASE_NOTES.txt
Original file line number Diff line number Diff line change
@@ -1,18 +1,4 @@
Release Notes for FSharpPlus 1.3.2 - December 2 2022
Release Notes for FSharpPlus 1.3.3 - February 4 2023
-----------------------------------------------------

Applicative Computation Expressions
Support for ValueOption, ValueTask and ValueTuple
Possibility to use explicit type parameters (plus, Seq.sum, guard, ofBytes, ofBytesWithOptions, ofBytesBE, parse, tryParse)
Use InlineIfLambda attribute in CEs
Small fixes (add lift3 for tuples, fix join for ref tuple and Free.map3)
Small improvements in type inference
Use F# Core 6.0.6
Speed up List and Array extensions using Collectors
Use FSharp.Core implementations for old functions that were adopted there
Add some missing Option, Result zip functions
Add explicit type parameters
Speed up by using InlineIfLambda attribute in CEs
Some missing Option, Result zip functions
Add NonEmptyList.sequence
Improve null handling for Array extensions
Fix missing zero overload for voption
1 change: 1 addition & 0 deletions src/FSharpPlus/Control/Numeric.fs
Original file line number Diff line number Diff line change
Expand Up @@ -136,6 +136,7 @@ type Zero =
static member Zero (_: DmStruct , _: Zero ) = Unchecked.defaultof<DmStruct>
static member Zero (_: list<'a> , _: Zero ) = [] : list<'a>
static member Zero (_: option<'a> , _: Zero ) = None : option<'a>
static member Zero (_: voption<'a> , _: Zero ) = ValueNone : voption<'a>
static member Zero (_: array<'a> , _: Zero ) = [||] : array<'a>
static member Zero (_: string , _: Zero ) = ""
static member Zero (_: StringBuilder , _: Zero ) = new StringBuilder ()
Expand Down
14 changes: 14 additions & 0 deletions tests/FSharpPlus.Tests/General.fs
Original file line number Diff line number Diff line change
Expand Up @@ -1704,6 +1704,20 @@ module Numerics =

Assert.AreEqual (argBigRational, r09 * r19)

[<Struct>]
type GuidId<'t> =
| Id of Guid

[<Test>]
let zeroOfDifferentTypes () =
let _01 = zero<int option>
areEqual None _01
let _02 = zero<GuidId<int> option>
areEqual None _02
let _03 = zero<int voption>
areEqual ValueNone _03
let _04 = zero<GuidId<int> voption>
areEqual ValueNone _04



Expand Down

0 comments on commit 87cde45

Please sign in to comment.