From 6bbb758837a91ae41c9c0b9a29dd130980e4af5a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Daniel=20D=C3=ADaz?= <diaz_carrete@yahoo.com> Date: Thu, 18 Jul 2024 12:25:56 +0200 Subject: [PATCH] Clarify the meaning of "exactly once" in LinearTypes Solves documentaion issue #25084. (cherry picked from commit 535a2117239f0d0e4588c6616fcd8deed725cfc0) --- docs/users_guide/exts/linear_types.rst | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/docs/users_guide/exts/linear_types.rst b/docs/users_guide/exts/linear_types.rst index 7fd3ef01f5c..6c69b618d58 100644 --- a/docs/users_guide/exts/linear_types.rst +++ b/docs/users_guide/exts/linear_types.rst @@ -28,8 +28,9 @@ once*, then its argument is consumed *exactly once*. Intuitively, it means that in every branch of the definition of ``f``, its argument ``x`` must be used exactly once. Which can be done by -* Returning ``x`` unmodified -* Passing ``x`` to a *linear* function +* Returning ``x`` unmodified. +* Passing ``x`` to a *linear* function and using the result exactly once + in the same fashion. * Pattern-matching on ``x`` and using each argument exactly once in the same fashion. * Calling it as a function and using the result exactly once in the same -- GitLab