lorentz-0.15.1: EDSL for the Michelson Language
Safe HaskellSafe-Inferred
LanguageHaskell2010

Lorentz.Instr.Framed

Description

This module is introduced to break some cycles in Lorentz.Lambda

Synopsis
  • framed :: forall s i o. (KnownList i, KnownList o) => (i :-> o) -> (i ++ s) :-> (o ++ s)

Documentation

framed :: forall s i o. (KnownList i, KnownList o) => (i :-> o) -> (i ++ s) :-> (o ++ s) Source #

Execute given instruction on truncated stack.

This instruction requires you to specify the piece of stack to truncate as type argument.

The complexity of this operation is linear in the number of instructions. If possible, avoid nested uses as that would imply multiple traversals. Worst case, complexity can become quadratic.