Sigils are very different from containers such as tuples, lists and binaries.
Yes. But the parser does not add meaning to this. You can also write this:
iex(1)> quote do: <<x :: def(foo, do: 1)>>
{:<<>>, [],
[{:::, [],
[{:x, [], Elixir},
{:def, [context: Elixir, import: Kernel],
[{:foo, [context: Elixir], Elixir}, [do: 1]]}]}]}
Therefore, syntax wise, <<>> can mean anything. That’s why I said you won’t find the documentation for what <<1::byte>> means in the syntax reference. The syntax allows you to put whatever you want on the right side of ::, the meaning comes from elsewhere.
This is a big contrast to other languages, such as Erlang, where what is allowed inside <<>> is a directly known by the parser.






















