Abacus.Runtime.Scope.get_in

You're seeing just the function get_in, go back to Abacus.Runtime.Scope module for more information.
Link to this function

get_in(subject, key_or_index, var_lookup \\ %{})

Specs

get_in(nil, key() | index(), map()) :: nil
get_in(map(), key(), map()) :: nil | term()
get_in(list(), index(), map()) :: nil | term()
get_in(list(), key(), map()) :: nil | term()

Tries to get values from a subject.

Subjects can be:

  • maps
  • keyword lists
  • lists (with integer keys)
  • nil (special case so access to undefined variables will not crash execution)

Keys can be:

  • strings
  • atoms (you can pass a resolve map that converts the given atom key into a string key)
  • positive integers (for lists only)

The Abacus parser will reference this function extensively like this:

a.b[2] will turn into

get_in(get_in(var0, :var1, var_lookup), 2, var_lookup)

in this case, var_lookup will be:

%{
  var1: "a",
  var2: "b"
}