Stack test
This commit is contained in:
parent
1c0579d065
commit
806f31b69d
5
pkg.go
5
pkg.go
@ -6,6 +6,7 @@ import (
|
|||||||
"fmt"
|
"fmt"
|
||||||
"path"
|
"path"
|
||||||
"runtime"
|
"runtime"
|
||||||
|
"runtime/debug"
|
||||||
)
|
)
|
||||||
|
|
||||||
type Error struct {
|
type Error struct {
|
||||||
@ -21,6 +22,10 @@ var (
|
|||||||
baseDirLength int
|
baseDirLength int
|
||||||
)
|
)
|
||||||
|
|
||||||
|
func init() {
|
||||||
|
debug.PrintStack()
|
||||||
|
}
|
||||||
|
|
||||||
func Init() {
|
func Init() {
|
||||||
_, file, _, _ := runtime.Caller(1)
|
_, file, _, _ := runtime.Caller(1)
|
||||||
fmt.Printf("--\nWRAPPED_ERROR: %s\n--\n", file)
|
fmt.Printf("--\nWRAPPED_ERROR: %s\n--\n", file)
|
||||||
|
Loading…
Reference in New Issue
Block a user