diff options
author | Gavin McGimpsey <dev@gavinmcg.com> | 2023-10-16 22:57:05 -0700 |
---|---|---|
committer | Louis Pilfold <louis@lpil.uk> | 2023-10-19 10:37:49 +0100 |
commit | 577697a91a68dab115212127267b65b340aee6d6 (patch) | |
tree | eba5f4ae3e8ae104579cbb8e4fe26c22fbd374b9 /test/gleam_stdlib_test_ffi.mjs | |
parent | a63339014ba5ebd5ad50b34bea53fb39d105ec52 (diff) | |
download | gleam_stdlib-577697a91a68dab115212127267b65b340aee6d6.tar.gz gleam_stdlib-577697a91a68dab115212127267b65b340aee6d6.zip |
Update result.gleam to clarify try and add examples of use
I found result.try confusing when I had not realized that it could "replace" an `Ok` with an `Error`. I also did not understand its use in function chaining because I hadn't seen an example of a function call creating the result that it takes as input. This changes the language to offer a more specific description of what result.try does, and to show examples of use that will hopefully demonstrate its value more clearly.
Diffstat (limited to 'test/gleam_stdlib_test_ffi.mjs')
0 files changed, 0 insertions, 0 deletions