aboutsummaryrefslogtreecommitdiffstats
path: root/vm/errors.go
diff options
context:
space:
mode:
Diffstat (limited to 'vm/errors.go')
-rw-r--r--vm/errors.go51
1 files changed, 0 insertions, 51 deletions
diff --git a/vm/errors.go b/vm/errors.go
deleted file mode 100644
index ab011bd62..000000000
--- a/vm/errors.go
+++ /dev/null
@@ -1,51 +0,0 @@
-package vm
-
-import (
- "fmt"
- "math/big"
-)
-
-type OutOfGasError struct {
- req, has *big.Int
-}
-
-func OOG(req, has *big.Int) OutOfGasError {
- return OutOfGasError{req, has}
-}
-
-func (self OutOfGasError) Error() string {
- return fmt.Sprintf("out of gas! require %v, have %v", self.req, self.has)
-}
-
-func IsOOGErr(err error) bool {
- _, ok := err.(OutOfGasError)
- return ok
-}
-
-type StackError struct {
- req, has int
-}
-
-func StackErr(req, has int) StackError {
- return StackError{req, has}
-}
-
-func (self StackError) Error() string {
- return fmt.Sprintf("stack error! require %v, have %v", self.req, self.has)
-}
-
-func IsStack(err error) bool {
- _, ok := err.(StackError)
- return ok
-}
-
-type DepthError struct{}
-
-func (self DepthError) Error() string {
- return fmt.Sprintf("Max call depth exceeded (%d)", MaxCallDepth)
-}
-
-func IsDepthErr(err error) bool {
- _, ok := err.(DepthError)
- return ok
-}