Hacker News new | ask | show | jobs
by G4BB3R 605 days ago
Are sigils (~) restricted to one char? To me seems ~Zig would be more clear and short enough.
1 comments

Erlang sigils are not, they can be any length, limited to characters allowed in atoms.

Elixir sigils also allow multiple characters in the name, but chars after the first must be upper case, according to the docs.

So for Elixir, it would have to be something like ~zIG

According to the docs, must be all upper case:

> Custom sigils may be either a single lowercase character, or an uppercase character followed by more uppercase characters and digits.

https://hexdocs.pm/elixir/sigils.html

Ah yeah, you're right.
Wait, erlang has sigils?
Yeah, there’s a bit of a developer experience push going on in erlang world, which is great!