package tezos-protocol-alpha

  1. Overview
  2. Docs
Legend:
Library
Module
Module type
Parameter
Class
Class type
type Tezos_protocol_environment_alpha.Error_monad.error +=
  1. | Unknown_primitive_name of string
type prim =
  1. | K_parameter
  2. | K_storage
  3. | K_code
  4. | K_view
  5. | D_False
  6. | D_Elt
  7. | D_Left
  8. | D_None
  9. | D_Pair
  10. | D_Right
  11. | D_Some
  12. | D_True
  13. | D_Unit
  14. | D_Ticket
  15. | D_Lambda_rec
  16. | I_PACK
  17. | I_UNPACK
  18. | I_BLAKE2B
  19. | I_SHA256
  20. | I_SHA512
  21. | I_ABS
  22. | I_ADD
  23. | I_AMOUNT
  24. | I_AND
  25. | I_BALANCE
  26. | I_CAR
  27. | I_CDR
  28. | I_CHAIN_ID
  29. | I_CHECK_SIGNATURE
  30. | I_COMPARE
  31. | I_CONCAT
  32. | I_CONS
  33. | I_CREATE_ACCOUNT
  34. | I_CREATE_CONTRACT
  35. | I_IMPLICIT_ACCOUNT
  36. | I_DIP
  37. | I_DROP
  38. | I_DUP
  39. | I_VIEW
  40. | I_EDIV
  41. | I_EMPTY_BIG_MAP
  42. | I_EMPTY_MAP
  43. | I_EMPTY_SET
  44. | I_EQ
  45. | I_EXEC
  46. | I_APPLY
  47. | I_FAILWITH
  48. | I_GE
  49. | I_GET
  50. | I_GET_AND_UPDATE
  51. | I_GT
  52. | I_HASH_KEY
  53. | I_IF
  54. | I_IF_CONS
  55. | I_IF_LEFT
  56. | I_IF_NONE
  57. | I_INT
  58. | I_LAMBDA
  59. | I_LAMBDA_REC
  60. | I_LE
  61. | I_LEFT
  62. | I_LEVEL
  63. | I_LOOP
  64. | I_LSL
  65. | I_LSR
  66. | I_LT
  67. | I_MAP
  68. | I_MEM
  69. | I_MUL
  70. | I_NEG
  71. | I_NEQ
  72. | I_NIL
  73. | I_NONE
  74. | I_NOT
  75. | I_NOW
  76. | I_MIN_BLOCK_TIME
  77. | I_OR
  78. | I_PAIR
  79. | I_UNPAIR
  80. | I_PUSH
  81. | I_RIGHT
  82. | I_SIZE
  83. | I_SOME
  84. | I_SOURCE
  85. | I_SENDER
  86. | I_SELF
  87. | I_SELF_ADDRESS
  88. | I_SLICE
  89. | I_STEPS_TO_QUOTA
  90. | I_SUB
  91. | I_SUB_MUTEZ
  92. | I_SWAP
  93. | I_TRANSFER_TOKENS
  94. | I_SET_DELEGATE
  95. | I_UNIT
  96. | I_UPDATE
  97. | I_XOR
  98. | I_ITER
  99. | I_LOOP_LEFT
  100. | I_ADDRESS
  101. | I_CONTRACT
  102. | I_ISNAT
  103. | I_CAST
  104. | I_RENAME
  105. | I_SAPLING_EMPTY_STATE
  106. | I_SAPLING_VERIFY_UPDATE
  107. | I_DIG
  108. | I_DUG
  109. | I_NEVER
  110. | I_VOTING_POWER
  111. | I_TOTAL_VOTING_POWER
  112. | I_KECCAK
  113. | I_SHA3
  114. | I_PAIRING_CHECK
  115. | I_TICKET
  116. | I_TICKET_DEPRECATED
  117. | I_READ_TICKET
  118. | I_SPLIT_TICKET
  119. | I_JOIN_TICKETS
  120. | I_OPEN_CHEST
  121. | I_EMIT
  122. | I_BYTES
  123. | I_NAT
  124. | T_bool
  125. | T_contract
  126. | T_int
  127. | T_key
  128. | T_key_hash
  129. | T_lambda
  130. | T_list
  131. | T_map
  132. | T_big_map
  133. | T_nat
  134. | T_option
  135. | T_or
  136. | T_pair
  137. | T_set
  138. | T_signature
  139. | T_string
  140. | T_bytes
  141. | T_mutez
  142. | T_timestamp
  143. | T_unit
  144. | T_operation
  145. | T_address
  146. | T_tx_rollup_l2_address
  147. | T_sapling_transaction
  148. | T_sapling_transaction_deprecated
  149. | T_sapling_state
  150. | T_chain_id
  151. | T_never
  152. | T_bls12_381_g1
  153. | T_bls12_381_g2
  154. | T_bls12_381_fr
  155. | T_ticket
  156. | T_chest_key
  157. | T_chest
  158. | H_constant

Types of nodes in Michelson's AST. They fall into 4 categories:

  • types (prefixed with T_);
  • constants (prefixed with D_);
  • instructions (prefixed with I_);
  • keywords (prefixed with K_).

Recall that Micheline is essentially just S-expressions with a few extra atom types for strings and numbers. This variant represents the values the Prim atoms in the Michelson subset of Micheline. Other types (such as 'a Micheline.canonical) are frequently parameterized by this type. This gives us a strongly-typed subset of Micheline while keeping the set of primitives independent from the definition of Micheline for easier changes.

Auxiliary types for error documentation. All the prim constructor prefixes must match their namespace.

type namespace =
  1. | Type_namespace
  2. | Constant_namespace
  3. | Instr_namespace
  4. | Keyword_namespace
  5. | Constant_hash_namespace
val namespace : prim -> namespace
val string_of_prim : prim -> string
val string_of_namespace : namespace -> string

The string corresponds to the constructor prefix from the given namespace (i.e. "T", "D", "I" or "K")

OCaml

Innovation. Community. Security.