You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I was delighted to learn that the pattern aliases described here are also supported for strings, however, I ran into this problem when trying to run my code with Erlang as the target. I pared it way
down to this minimal example - it's nonsense, but it seems clear where the problem is:
case <<""/utf8>> of
<<""/utf8 = A, _/binary>> ->
nil;
_ ->
nilend,
it seems like pattern aliases and string prefixes do not play nicely together.
should pattern aliases be available for string prefixes in the first place? their value is a known constant.
I was delighted to learn that the pattern aliases described here are also supported for strings, however, I ran into this problem when trying to run my code with Erlang as the target. I pared it way
down to this minimal example - it's nonsense, but it seems clear where the problem is:
..which produces the following when run with
gleam run
:It runs as expected with
gleam run -t js
. My Gleam version is 1.0.0, installed from here. I'll add the generated Erlang for good measure:The text was updated successfully, but these errors were encountered: