You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

18 lines
260 B

  1. package common
  2. import (
  3. "fmt"
  4. )
  5. type StackError struct {
  6. Err interface{}
  7. Stack []byte
  8. }
  9. func (se StackError) String() string {
  10. return fmt.Sprintf("Error: %v\nStack: %s", se.Err, se.Stack)
  11. }
  12. func (se StackError) Error() string {
  13. return se.String()
  14. }