Typechecker error redundancy in the interpreter
Clarification and motivation
Currently, there are two ways to report typechecker error in the ExecutorError
datatype from Michelson.Runtime
:
- Constructors
EEIllTypedContract
,EEIllTypedStorage
andEEIllTypedParameter
ofExecutorError
- Constructors
IllTypedContract
,IllTypedParam
andIllTypedStorage
ofInterpretError
datatype fromMichelson.Interpreter
. This datatype is an argument forEEInterpreterFailed
constructor ofExecutorError
.
Such implementation difficulties pattern-matching over errors that can be produced from ExecutorM
, we basically have to
do the same handling twice for the same errors twice.
AFAIU, the main reason why IllTyped*
constructors appear in InterpretError
is existence of interpretUntyped
which is exported but isn't used anywhere.
Maybe it's a good idea to remove interpretUntyped
since its unused in this project and not used in any other our projects. However, this can break backward compatibility:(
Acceptance criteria
This typechecker error redundancy is removed.