Commit a2e4b2a5 authored by Pinto Pasquale's avatar Pinto Pasquale Committed by Raphaël Cauderlier

Doc/Michelson: update annotation's regular expression

parent 9279f79a
......@@ -2499,8 +2499,11 @@ Syntax
Primitive applications can receive one or many annotations.
An annotation is a sequence of characters that matches the regular
expression ``[@:%](|@|%|%%|[_a-zA-Z][_0-9a-zA-Z\.]*)``. They come after
the primitive name and before its potential arguments.
expression ``@%|@%%|%@|[@:%][_a-zA-Z][_0-9a-zA-Z\.%@]*``.
Note however that ``@%``, ``@%%`` and ``%@`` are
:ref:`special annotations <SpecialAnnotations>` and are not allowed everywhere.
Annotations come after the primitive name and before its potential arguments.
::
......@@ -2657,6 +2660,7 @@ type (which can be changed). For instance the annotated typing rule for
Special annotations
~~~~~~~~~~~~~~~~~~~
.. _SpecialAnnotations:
The special variable annotations ``@%`` and ``@%%`` can be used on instructions
``CAR`` and ``CDR``. It means to use the accessed field name (if any) as
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment