-module(given@internal@examples). -compile([no_auto_import, nowarn_unused_vars, nowarn_unused_function, nowarn_nomatch]). -export([given_example/0, not_given_example/0, given_ok_in_example/0, given_error_in_example/0, given_some_in_example/0, given_none_in_example/0, given_none_in_another_example/0, main/0]). -file("/Volumes/Gleam/gleam-given/src/given/internal/examples.gleam", 3). -spec given_example() -> binary(). given_example() -> User_understood = false, given:given( User_understood, fun() -> <<"💡 Bright!"/utf8>> end, fun() -> <<"🤯 Woof!"/utf8>> end ). -file("/Volumes/Gleam/gleam-given/src/given/internal/examples.gleam", 12). -spec not_given_example() -> binary(). not_given_example() -> Has_admin_role = true, given:not_given( Has_admin_role, fun() -> <<"✋ Denied!"/utf8>> end, fun() -> <<"👌 Access granted..."/utf8>> end ). -file("/Volumes/Gleam/gleam-given/src/given/internal/examples.gleam", 22). -spec given_ok_in_example() -> binary(). given_ok_in_example() -> A_result = {ok, <<"Hello Joe!"/utf8>>}, given:ok_in( A_result, fun(Error_value) -> Error_value end, fun(Ok_value) -> Ok_value end ). -file("/Volumes/Gleam/gleam-given/src/given/internal/examples.gleam", 33). -spec given_error_in_example() -> binary(). given_error_in_example() -> A_result = {error, <<"Memory exhausted!"/utf8>>}, given:error_in( A_result, fun(Ok_value) -> Ok_value end, fun(Error_value) -> Error_value end ). -file("/Volumes/Gleam/gleam-given/src/given/internal/examples.gleam", 45). -spec given_some_in_example() -> binary(). given_some_in_example() -> An_option = {some, <<"One Penny"/utf8>>}, given:some_in( An_option, fun() -> <<"Woof!"/utf8>> end, fun(Some_value) -> Some_value end ). -file("/Volumes/Gleam/gleam-given/src/given/internal/examples.gleam", 54). -spec given_none_in_example() -> binary(). given_none_in_example() -> An_option = none, given:none_in( An_option, fun(Some_value) -> Some_value end, fun() -> <<"Nothing at all"/utf8>> end ). -file("/Volumes/Gleam/gleam-given/src/given/internal/examples.gleam", 63). -spec given_none_in_another_example() -> binary(). given_none_in_another_example() -> An_option = none, given:none_in( An_option, fun(Else_some_value) -> Else_some_value end, fun() -> <<"None here"/utf8>> end ). -file("/Volumes/Gleam/gleam-given/src/given/internal/examples.gleam", 74). -spec main() -> binary(). main() -> _pipe = given_example(), gleam@io:debug(_pipe), _pipe@1 = not_given_example(), gleam@io:debug(_pipe@1), _pipe@2 = given_ok_in_example(), gleam@io:debug(_pipe@2), _pipe@3 = given_error_in_example(), gleam@io:debug(_pipe@3), _pipe@4 = given_some_in_example(), gleam@io:debug(_pipe@4), _pipe@5 = given_none_in_example(), gleam@io:debug(_pipe@5).