[Git][ghc/ghc][master] Clarify the meaning of "exactly once" in LinearTypes
Marge Bot (@marge-bot)
gitlab at gitlab.haskell.org
Sun Oct 6 13:52:12 UTC 2024
Marge Bot pushed to branch master at Glasgow Haskell Compiler / GHC
Commits:
535a2117 by Daniel Díaz at 2024-10-06T09:51:46-04:00
Clarify the meaning of "exactly once" in LinearTypes
Solves documentaion issue #25084.
- - - - -
1 changed file:
- docs/users_guide/exts/linear_types.rst
Changes:
=====================================
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
View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/commit/535a2117239f0d0e4588c6616fcd8deed725cfc0
--
View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/commit/535a2117239f0d0e4588c6616fcd8deed725cfc0
You're receiving this email because of your account on gitlab.haskell.org.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.haskell.org/pipermail/ghc-commits/attachments/20241006/5afb97e8/attachment.html>
More information about the ghc-commits
mailing list