Skip to content
On this page

Never ​

This notion is both quite advanced and almost useless.

sp.never(expression)
Values of type sp.TNever cannot occur in a well-typed program. However, they can be abstracted in the parameter declaration of a contractβ€”or by using the Lambda operationβ€”thus indicating that the corresponding branches in the code are forbidden.

The corresponding type in Michelson is

Michelson never.

Close a forbidden branch, where expression is of type sp.TNever.

Example ​

python
sp.never(expression)

See reference Never template.

The corresponding instruction in Michelson is

Michelson NEVER.