on master help sign in
Merge pull request #4111 from msmorgan/alternative-infixr
fddb326Ahmad Salim Al-Sibahi
CHANGELOG.md+1
@@ -19,6 +19,7 @@
19+ Added `discriminate` and `construct` tactics to Pruviloj.
19+ Added `discriminate` and `construct` tactics to Pruviloj.
20+ Added `IsSucc` type to `Prelude`, which proves that a `Nat` is a successor.
20+ Added `IsSucc` type to `Prelude`, which proves that a `Nat` is a successor.
21+ Added `Data.IOArray`, containing primitives for mutable arrays.
21+ Added `Data.IOArray`, containing primitives for mutable arrays.
22++ The operator `<|>` is now right-associative (it retains the same precedence).
22
23
23## Tool Updates
24## Tool Updates
24+ Private functions are no longer visible in the REPL except for modules
25+ Private functions are no longer visible in the REPL except for modules
libs/prelude/Prelude/Applicative.idr+1−1
@@ -38,7 +38,7 @@ liftA2 f a b = (map f a) <*> b
38liftA3 : Applicative f => (a -> b -> c -> d) -> f a -> f b -> f c -> f d
38liftA3 : Applicative f => (a -> b -> c -> d) -> f a -> f b -> f c -> f d
39liftA3 f a b c = (map f a) <*> b <*> c
39liftA3 f a b c = (map f a) <*> b <*> c
40
40
41−infixl 3 <|>
41+infixr 3 <|>
42interface Applicative f => Alternative (f : Type -> Type) where
42interface Applicative f => Alternative (f : Type -> Type) where
43 empty : f a
43 empty : f a
44 (<|>) : f a -> f a -> f a
44 (<|>) : f a -> f a -> f a