Skip to content

Commit

Permalink
docs: prepare to release version 2.2.0 (#14)
Browse files Browse the repository at this point in the history
* docs: add version information

* docs(CHANGELOG): prepare for 2.2.0

* docs(README): tweak the examples
  • Loading branch information
favonia authored Aug 18, 2023
1 parent ed4b635 commit f7daa91
Show file tree
Hide file tree
Showing 6 changed files with 90 additions and 57 deletions.
37 changes: 17 additions & 20 deletions CHANGELOG.markdown
Original file line number Diff line number Diff line change
@@ -1,46 +1,43 @@
# [2.1.0](https://github.com/RedPRL/ocaml-bwd/compare/2.0.0...2.1.0) (2022-08-06)

# [2.2.0](https://github.com/RedPRL/ocaml-bwd/compare/2.1.0...2.2.0) (2023-08-18)

### Bug Fixes
### Features

* rename Bwd.Notation to Bwd.Infix ([#8](https://github.com/RedPRL/ocaml-bwd/issues/8)) ([4869bbd](https://github.com/RedPRL/ocaml-bwd/commit/4869bbd9ab8d304d94515428bf54f471fca03181))
- introduce new infix operators ([#13](https://github.com/RedPRL/ocaml-bwd/issues/13)) ([ed4b635](https://github.com/RedPRL/ocaml-bwd/commit/ed4b635059e0404029069f37b6c6ab0827bac2d1))

### Deprecations

- deprecate old infix operators ([#13](https://github.com/RedPRL/ocaml-bwd/issues/13)) ([ed4b635](https://github.com/RedPRL/ocaml-bwd/commit/ed4b635059e0404029069f37b6c6ab0827bac2d1))

# [2.0.0](https://github.com/RedPRL/ocaml-bwd/compare/1.2.0...2.0.0) (2022-05-02)
# [2.1.0](https://github.com/RedPRL/ocaml-bwd/compare/2.0.0...2.1.0) (2022-08-06)

### Bug Fixes

### Features
- rename Bwd.Notation to Bwd.Infix ([#8](https://github.com/RedPRL/ocaml-bwd/issues/8)) ([4869bbd](https://github.com/RedPRL/ocaml-bwd/commit/4869bbd9ab8d304d94515428bf54f471fca03181))

* add iter2 ([232e1d0](https://github.com/RedPRL/ocaml-bwd/commit/232e1d0048bc289a7c565eb017c664899349acf5))
* add many functions; remove concat ([7fa35e6](https://github.com/RedPRL/ocaml-bwd/commit/7fa35e65247adbcb45d48dab2f4f3f2ffb2c90bc))
* provide unlabeled versions ([0c67343](https://github.com/RedPRL/ocaml-bwd/commit/0c673432ff91723085410eedaf78dae5a23b87b1))
# [2.0.0](https://github.com/RedPRL/ocaml-bwd/compare/1.2.0...2.0.0) (2022-05-02)

### Features

- add iter2 ([232e1d0](https://github.com/RedPRL/ocaml-bwd/commit/232e1d0048bc289a7c565eb017c664899349acf5))
- add many functions; remove concat ([7fa35e6](https://github.com/RedPRL/ocaml-bwd/commit/7fa35e65247adbcb45d48dab2f4f3f2ffb2c90bc))
- provide unlabeled versions ([0c67343](https://github.com/RedPRL/ocaml-bwd/commit/0c673432ff91723085410eedaf78dae5a23b87b1))

# [1.2.0](https://github.com/RedPRL/ocaml-bwd/compare/1.1.0...1.2.0) (2022-04-09)


### Bug Fixes

* fix the completely incorrect `filter` ([d1c7aa8](https://github.com/RedPRL/ocaml-bwd/commit/d1c7aa8ac08f973d30032e6c2d615585f3e42452))

- fix the completely incorrect `filter` ([d1c7aa8](https://github.com/RedPRL/ocaml-bwd/commit/d1c7aa8ac08f973d30032e6c2d615585f3e42452))

### Features

* add `nth_opt` ([fdb18bb](https://github.com/RedPRL/ocaml-bwd/commit/fdb18bb914f2e6ab760141ef5492fe33e077ae02))


- add `nth_opt` ([fdb18bb](https://github.com/RedPRL/ocaml-bwd/commit/fdb18bb914f2e6ab760141ef5492fe33e077ae02))

# [1.1.0](https://github.com/RedPRL/ocaml-bwd/compare/1.0.0...1.1.0) (2022-03-30)


### Features

* enable `tail_mod_cons` ([9497927](https://github.com/RedPRL/ocaml-bwd/commit/9497927c9f794e0f196478267b748b6f2c3a38e7))


- enable `tail_mod_cons` ([9497927](https://github.com/RedPRL/ocaml-bwd/commit/9497927c9f794e0f196478267b748b6f2c3a38e7))

### Deprecations

* deprecate `concat_map` ([#3](https://github.com/RedPRL/ocaml-bwd/pull/3)) ([6c6efe2](https://github.com/RedPRL/ocaml-bwd/commit/6c6efe2b58fc2212f451d43acd802cf1aa1f03ac))
- deprecate `concat_map` ([#3](https://github.com/RedPRL/ocaml-bwd/pull/3)) ([6c6efe2](https://github.com/RedPRL/ocaml-bwd/commit/6c6efe2b58fc2212f451d43acd802cf1aa1f03ac))
18 changes: 9 additions & 9 deletions README.markdown
Original file line number Diff line number Diff line change
Expand Up @@ -41,21 +41,21 @@ let b1 : int bwd = Emp <: 1 <: 2 <: 3
(* The module [Bwd] is similar to the standard [List] but for backward lists.
It has most functions you would expect. For example, the following expression
gives the backward list corresponding to [4; 5; 6]. *)
let b2 : int bwd = Bwd.map (fun x -> x + 3) b1
gives the backward list corresponding to [2; 3; 4]. *)
let b2 : int bwd = Bwd.map (fun x -> x + 1) b1
(* Same as above, but using [BwdLabels] that mimics [ListLabels] instead. *)
let b2' : int bwd = BwdLabels.map ~f:(fun x -> x + 3) b1
let b2' : int bwd = BwdLabels.map ~f:(fun x -> x + 1) b1
(* bwd yoga 1: [<@] for moving elements from a forward list on the right
to a backward list on the left. The notation was inspired by Conor McBride.
The following gives the backward list corresponding to [4; 5; 6; 7; 8; 9]. *)
let b3 : int bwd = b2 <@ [7; 8] <@ [9]
to a backward list on the left. The following gives the backward list
corresponding to [1; 2; 3; 4; 5; 6]. *)
let b3 : int bwd = b1 <@ [4; 5; 6]
(* bwd yoga 2: [@>] for moving elements from a backward list on the left
to a forward list on the right. The notation was inspired by Conor McBride.
The following gives the forward list [1; 2; 3; 4; 5; 6; 7; 8; 9; 10]. *)
let l4 : int list = b1 @> b3 @> [10]
to a forward list on the right. The following gives the forward list
[1; 2; 3; 4; 5; 6; 7; 8; 9]. *)
let l4 : int list = b3 @> [7; 8; 9]
```

## Philosophy
Expand Down
2 changes: 1 addition & 1 deletion src/Bwd.mli
Original file line number Diff line number Diff line change
Expand Up @@ -10,5 +10,5 @@ module BwdLabels : module type of BwdLabels

(**/**)

(** An alias of {!module:Bwd.Notation} for infix notation. *)
(** An alias of {!module:Bwd.Infix} for infix notation. *)
module BwdNotation : module type of BwdNotation [@@ocaml.alert deprecated "Use Bwd.Infix instead"]
42 changes: 30 additions & 12 deletions src/BwdLabels.mli
Original file line number Diff line number Diff line change
Expand Up @@ -100,26 +100,44 @@ val of_list : 'a list -> 'a t

(** {1 Infix notation} *)

(** Notation inspired by Conor McBride. *)
module Infix :
sig
val (#<) : 'a t -> 'a -> 'a t [@@ocaml.alert deprecated "Use (<:) instead"]
(** An alias of {!val:BwdLabels.snoc}. *)

val (<><) : 'a t -> 'a list -> 'a t [@@ocaml.alert deprecated "Use (<@) instead"]
(** An alias of {!val:BwdLabels.append}. *)

val (<>>) : 'a t -> 'a list -> 'a list [@@ocaml.alert deprecated "Use (@>) instead"]
(** An alias of {!val:BwdLabels.prepend}. *)
(** {1 Infix notation} *)

val (<:) : 'a t -> 'a -> 'a t
(** An alias of {!val:BwdLabels.snoc}. *)
(** An alias of {!val:BwdLabels.snoc}.
@since 2.2.0 *)

val (<@) : 'a t -> 'a list -> 'a t
(** An alias of {!val:BwdLabels.append}. *)
(** An alias of {!val:BwdLabels.append}.
@since 2.2.0 *)

val (@>) : 'a t -> 'a list -> 'a list
(** An alias of {!val:BwdLabels.prepend}. *)
(** An alias of {!val:BwdLabels.prepend}.
@since 2.2.0 *)

(** {1 Deprecated infix notation} *)

val (#<) : 'a t -> 'a -> 'a t
[@@ocaml.alert deprecated "Use (<:) instead"]
(** An alias of {!val:BwdLabels.snoc}.
@deprecated Use [(<:)] *)

val (<><) : 'a t -> 'a list -> 'a t
[@@ocaml.alert deprecated "Use (<@) instead"]
(** An alias of {!val:BwdLabels.append}.
@deprecated Use [(<@)] *)

val (<>>) : 'a t -> 'a list -> 'a list
[@@ocaml.alert deprecated "Use (@>) instead"]
(** An alias of {!val:BwdLabels.prepend}.
@deprecated Use [(@>)] *)
end

(**/**)
Expand Down
6 changes: 3 additions & 3 deletions src/BwdNoLabels.ml
Original file line number Diff line number Diff line change
Expand Up @@ -344,12 +344,12 @@ let of_list xs =

module Infix =
struct
let (#<) = snoc
let (<><) = append
let (<>>) = prepend
let (<:) = snoc
let (<@) = append
let (@>) = prepend
let (#<) = snoc
let (<><) = append
let (<>>) = prepend
end

module Notation = Infix
42 changes: 30 additions & 12 deletions src/BwdNoLabels.mli
Original file line number Diff line number Diff line change
Expand Up @@ -100,26 +100,44 @@ val of_list : 'a list -> 'a t

(** {1 Infix notation} *)

(** Notation inspired by Conor McBride. *)
module Infix :
sig
val (#<) : 'a t -> 'a -> 'a t [@@ocaml.alert deprecated "Use (<:) instead"]
(** An alias of {!val:Bwd.snoc}. *)

val (<><) : 'a t -> 'a list -> 'a t [@@ocaml.alert deprecated "Use (<@) instead"]
(** An alias of {!val:Bwd.append}. *)

val (<>>) : 'a t -> 'a list -> 'a list [@@ocaml.alert deprecated "Use (@>) instead"]
(** An alias of {!val:Bwd.prepend}. *)
(** {1 Infix notation} *)

val (<:) : 'a t -> 'a -> 'a t
(** An alias of {!val:Bwd.snoc}. *)
(** An alias of {!val:Bwd.snoc}.
@since 2.2.0 *)

val (<@) : 'a t -> 'a list -> 'a t
(** An alias of {!val:Bwd.append}. *)
(** An alias of {!val:Bwd.append}.
@since 2.2.0 *)

val (@>) : 'a t -> 'a list -> 'a list
(** An alias of {!val:Bwd.prepend}. *)
(** An alias of {!val:Bwd.prepend}.
@since 2.2.0 *)

(** {1 Deprecated infix notation} *)

val (#<) : 'a t -> 'a -> 'a t
[@@ocaml.alert deprecated "Use (<:) instead"]
(** An alias of {!val:Bwd.snoc}.
@deprecated Use [(<:)] *)

val (<><) : 'a t -> 'a list -> 'a t
[@@ocaml.alert deprecated "Use (<@) instead"]
(** An alias of {!val:Bwd.append}.
@deprecated Use [(<@)] *)

val (<>>) : 'a t -> 'a list -> 'a list
[@@ocaml.alert deprecated "Use (@>) instead"]
(** An alias of {!val:Bwd.prepend}.
@deprecated Use [(@>)] *)
end

(**/**)
Expand Down

0 comments on commit f7daa91

Please sign in to comment.