Nock (Anoma v0.29.0)

Nock, a universal function on nouns.

Summary

Types

t()

I contain environmental information on how Nock shall be evaluated.

Types

@type t() :: %Nock{
  gas_limit: non_neg_integer() | nil,
  meter_pid: pid() | nil,
  scry_function: (term() -> {:ok, term()} | :error),
  stdio: any()
}

I contain environmental information on how Nock shall be evaluated.

For example Ι contain information on jettedness to determine if we should be using jets or not

Functions

@spec cons(Noun.t(), Noun.t()) :: Noun.t()
Link to this function

decrement_arm()

@spec decrement_arm() :: Noun.t()
Link to this function

decrement_core()

@spec decrement_core() :: Noun.t()
Link to this function

gas_limit(limit, pid, gas)

@spec gas_meter() :: non_neg_integer()
@spec gas_meter(non_neg_integer()) :: non_neg_integer()
Link to this function

get_jet(battery_mug)

@spec get_jet(Noun.t()) ::
  {:ok,
   {String.t(), non_neg_integer(), non_neg_integer(),
    (Noun.t() -> :error | {:ok, Noun.t()}), atom(), non_neg_integer()}}
  | :error
@spec logics_core() :: Noun.t()
Link to this function

metered_nock(subject, formula)

@spec metered_nock(Noun.t(), Noun.t()) ::
  {:ok, Noun.t(), non_neg_integer()} | {:error, non_neg_integer()}
Link to this function

metered_nock(subject, formula, environment)

@spec metered_nock(Noun.t(), Noun.t(), t()) ::
  {:ok, Noun.t(), non_neg_integer()} | {:error, non_neg_integer()}
Link to this function

naive_nock(subject, formula)

@spec naive_nock(Noun.t(), Noun.t()) :: {:ok, Noun.t()} | :error
Link to this function

naive_nock(subject, formula, environment)

@spec naive_nock(Noun.t(), Noun.t(), t()) :: {:ok, Noun.t()} | :error
Link to this function

nock(subject, formula)

@spec nock(Noun.t(), Noun.t()) :: {:ok, Noun.t()} | :error
Link to this function

nock(subject, formula, env)

@spec nock(Noun.t(), Noun.t(), t()) :: {:ok, Noun.t()} | :error
@spec nock_0(Noun.t()) :: Noun.t()
Link to this function

nock_1(constant)

@spec nock_1(Noun.t()) :: Noun.t()
Link to this function

nock_2(subject_formula, formula_formula)

@spec nock_2(Noun.t(), Noun.t()) :: Noun.t()
Link to this function

nock_3(sub_formula)

@spec nock_3(Noun.t()) :: Noun.t()
Link to this function

nock_4(sub_formula)

@spec nock_4(Noun.t()) :: Noun.t()
Link to this function

nock_5(formula_1, formula_2)

@spec nock_5(Noun.t(), Noun.t()) :: Noun.t()
Link to this function

nock_6(cond, true_branch, false_branch)

@spec nock_6(Noun.t(), Noun.t(), Noun.t()) :: Noun.t()
Link to this function

nock_7(subject_formula, sub_formula)

@spec nock_7(Noun.t(), Noun.t()) :: Noun.t()
Link to this function

nock_8(push_formula, sub_formula)

@spec nock_8(Noun.t(), Noun.t()) :: Noun.t()
Link to this function

nock_9(axis, sub_formula)

@spec nock_9(Noun.t(), Noun.t()) :: Noun.t()
Link to this function

nock_10(axis, replacement_formula, sub_formula)

@spec nock_10(Noun.t(), Noun.t(), Noun.t()) :: Noun.t()
Link to this function

nock_11(hint_noun, sub_formula)

@spec nock_11(Noun.t(), Noun.t()) :: Noun.t()
Link to this function

nock_11(hint_noun, hint_formula, sub_formula)

@spec nock_11(Noun.t(), Noun.t(), Noun.t()) :: Noun.t()
Link to this function

process_hint(_)

@spec process_hint(Noun.t()) :: term()
Link to this function

process_hint(puts, hint_result, environment)

@spec process_hint(Noun.t(), Noun.t(), t()) :: term()
Link to this function

put_jet(battery_mug, jet_info)

@spec put_jet(Noun.t(), any()) :: any()
Link to this function

read_with_id(id_key_list, env)

@spec read_with_id(Noun.t(), t()) :: {:ok, Noun.t()} | :error
@spec rm_core() :: Noun.t()
Link to this function

scry_forbidden(_)

@spec scry_forbidden(Noun.t()) :: :error | {:ok, Noun.t()}
@spec stdlib_core() :: Noun.t()
Link to this function

stdlib_layers()

@spec stdlib_layers() :: non_neg_integer()

Gives the total numbers of layers in the standard library