From 12dde21957b9807dbdd8bb37de34cd5e7702b3a1 Mon Sep 17 00:00:00 2001 From: Nicolas Ayache Date: Thu, 23 Feb 2023 13:32:24 +0100 Subject: [PATCH] Doc/Michelson: redirect operations on unions to interactive reference. --- docs/alpha/michelson.rst | 41 +++++----------------------------------- 1 file changed, 5 insertions(+), 36 deletions(-) diff --git a/docs/alpha/michelson.rst b/docs/alpha/michelson.rst index 65358465fb8f..9b5bd1e1f379 100644 --- a/docs/alpha/michelson.rst +++ b/docs/alpha/michelson.rst @@ -851,43 +851,12 @@ A detailed description of the following instructions can be found in the `intera Operations on unions ~~~~~~~~~~~~~~~~~~~~ -- ``LEFT 'b``: Pack a value in a union (left case). - -:: - - :: 'a : 'S -> or 'a 'b : 'S - - > LEFT / v : S => (Left v) : S - -- ``RIGHT 'a``: Pack a value in a union (right case). - -:: - - :: 'b : 'S -> or 'a 'b : 'S - - > RIGHT / v : S => (Right v) : S - -- ``IF_LEFT bt bf``: Inspect a value of a union. - -:: - - :: or 'a 'b : 'A -> 'B - iff bt :: [ 'a : 'A -> 'B] - bf :: [ 'b : 'A -> 'B] - - > IF_LEFT bt bf / (Left a) : S => bt / a : S - > IF_LEFT bt bf / (Right b) : S => bf / b : S - -- ``COMPARE``: Unions comparison - -:: - - :: or 'a 'b : or 'a 'b : 'S -> int : 'S +A detailed description of the following instructions can be found in the `interactive Michelson reference manual `__. - > COMPARE / (Left a) : (Left b) : S => COMPARE / a : b : S - > COMPARE / (Left _) : (Right _) : S => -1 : S - > COMPARE / (Right _) : (Left _) : S => 1 : S - > COMPARE / (Right a) : (Right b) : S => COMPARE / a : b : S +- ``LEFT 'b``: Pack a value in a union (left case) (`documentation `__). +- ``RIGHT 'a``: Pack a value in a union (right case) (`documentation `__). +- ``IF_LEFT bt bf``: Inspect a value of a union (`documentation `__). +- ``COMPARE``: Unions comparison (`documentation `__). Operations on lists ~~~~~~~~~~~~~~~~~~~ -- GitLab