summaryrefslogtreecommitdiff
path: root/spew/dumpcgo_test.go
diff options
context:
space:
mode:
authorDave Collins <[email protected]>2015-06-17 22:34:22 -0500
committerDave Collins <[email protected]>2015-06-19 15:29:34 -0500
commit2df174808ee097f90d259e432cc04442cf60be21 (patch)
tree137a52652745f1dc47abb8ab3d379cb556e6e632 /spew/dumpcgo_test.go
parentf9f629a1d082960e5d1747f33c2b378612615fea (diff)
Add support for limited mode without unsafe pkg.
This commit adds support for compiling spew without the unsafe package. When compiled without the unsafe package, some of the more advanced features such as invoking stringers on pointers from non-pointer variables and unexported struct fields are not available. By default, spew will be compiled in the limited mode for Google App Engine since the unsafe package is not available there. Additionally, spew can be compiled without the unsafe package manually by specifying the "disableunsafe" build tag. Finally, a new package-level constant named "UnsafeDisabled" has been exposed which can be used to programmatically determine if spew was compiled with access to the unsafe package.
Diffstat (limited to 'spew/dumpcgo_test.go')
-rw-r--r--spew/dumpcgo_test.go1
1 files changed, 1 insertions, 0 deletions
diff --git a/spew/dumpcgo_test.go b/spew/dumpcgo_test.go
index 9b8a358..18a3835 100644
--- a/spew/dumpcgo_test.go
+++ b/spew/dumpcgo_test.go
@@ -25,6 +25,7 @@ package spew_test
import (
"fmt"
+
"github.com/davecgh/go-spew/spew/testdata"
)