Skip to content

Instantly share code, notes, and snippets.

Created December 10, 2015 21:24
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save anonymous/e5165c443f6bdf0f0780 to your computer and use it in GitHub Desktop.
Save anonymous/e5165c443f6bdf0f0780 to your computer and use it in GitHub Desktop.
-module(tt).
-export([go/0]).
-type glory() :: 'glory' | 'hello'.
go() ->
boop(hello).
-spec boop(X :: glory()) -> glory().
boop(X) ->
case (random:uniform() > 0.5) of
true ->
X;
_ ->
'micronauts'
end.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment