From 6fad55e2669ae7fa04ab82e33a9822aecaca151a Mon Sep 17 00:00:00 2001 From: Ole Johan Date: Sat, 7 Dec 2024 23:15:48 +0100 Subject: [PATCH] Improve documentation of Map.S.add_to_list Replace `v` with `data` for better readability --- stdlib/map.mli | 2 +- stdlib/moreLabels.mli | 2 +- stdlib/templates/map.template.mli | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/stdlib/map.mli b/stdlib/map.mli index 56f87d7c8f87..cfc904b938d6 100644 --- a/stdlib/map.mli +++ b/stdlib/map.mli @@ -88,7 +88,7 @@ module type S = val add_to_list: key -> 'a -> 'a list t -> 'a list t (** [add_to_list key data m] is [m] with [key] mapped to [l] such that [l] is [data :: Map.find key m] if [key] was bound in - [m] and [[v]] otherwise. + [m] and [[data]] otherwise. @since 5.1 *) val update: key -> ('a option -> 'a option) -> 'a t -> 'a t diff --git a/stdlib/moreLabels.mli b/stdlib/moreLabels.mli index 26993ff71c62..c33bb0a527d1 100644 --- a/stdlib/moreLabels.mli +++ b/stdlib/moreLabels.mli @@ -739,7 +739,7 @@ module Map : sig val add_to_list: key:key -> data:'a -> 'a list t -> 'a list t (** [add_to_list ~key ~data m] is [m] with [key] mapped to [l] such that [l] is [data :: Map.find key m] if [key] was bound in - [m] and [[v]] otherwise. + [m] and [[data]] otherwise. @since 5.1 *) val update: key:key -> f:('a option -> 'a option) -> 'a t -> 'a t diff --git a/stdlib/templates/map.template.mli b/stdlib/templates/map.template.mli index 4639853a215b..0def0dab484e 100644 --- a/stdlib/templates/map.template.mli +++ b/stdlib/templates/map.template.mli @@ -88,7 +88,7 @@ module type S = val add_to_list: key:key -> data:'a -> 'a list t -> 'a list t (** [add_to_list ~key ~data m] is [m] with [key] mapped to [l] such that [l] is [data :: Map.find key m] if [key] was bound in - [m] and [[v]] otherwise. + [m] and [[data]] otherwise. @since 5.1 *) val update: key:key -> f:('a option -> 'a option) -> 'a t -> 'a t