Stashed shell state tied to the exact shell registration that produced it.
Shell state is safe to restore only into the same registered shell id, module, source, and generation. MingaEditor.Shell.Identity owns that comparison contract for registration, runtime, renderer, and stash paths.
Summary
Functions
Returns true when the stash belongs to the current exact registry entry.
Stores shell state with the exact registry identity that produced it.
Restores stored state only when the current registry entry has the same exact identity.
Retires a dead buffer from a stashed Traditional value without changing its identity.
Types
@type t() :: %MingaEditor.Shell.StateStash{ identity: MingaEditor.Shell.Identity.t(), state: MingaEditor.Shell.shell_state() }
Functions
@spec matches?(t(), MingaEditor.Shell.Entry.t()) :: boolean()
Returns true when the stash belongs to the current exact registry entry.
@spec new(MingaEditor.Shell.Entry.t(), MingaEditor.Shell.shell_state()) :: t()
Stores shell state with the exact registry identity that produced it.
@spec restore(t(), MingaEditor.Shell.Entry.t()) :: {:ok, MingaEditor.Shell.shell_state()} | :mismatch
Restores stored state only when the current registry entry has the same exact identity.
Retires a dead buffer from a stashed Traditional value without changing its identity.