env memory

This commit is contained in:
Svyatoslav Nikolsky
2017-05-04 12:01:21 +03:00
parent b4215aed3c
commit 9a5ed312ec
2 changed files with 17 additions and 4 deletions

View File

@ -25,6 +25,8 @@ pub enum Error {
Value(String),
/// Interpreter (code) error.
Interpreter(String),
/// Env module error.
Env(String),
/// Trap.
Trap(String),
}
@ -43,6 +45,7 @@ impl Into<String> for Error {
Error::Stack(s) => s,
Error::Interpreter(s) => s,
Error::Value(s) => s,
Error::Env(s) => s,
Error::Trap(s) => format!("trap: {}", s),
}
}