davecgh / go-spew

Implements a deep pretty printer for Go data structures to aid in debugging
ISC License
5.98k stars 361 forks source link

Ignore Stringer() interface #89

Closed pjebs closed 5 years ago

pjebs commented 5 years ago

Is there somewhere to configure Spew so that Sdump ignores Stringer interface.

jrick commented 5 years ago

It may be reasonable to avoid usage of Stringer by default. GoStringer would be a more appropriate choice.

millerlogic commented 5 years ago
spew.Config.DisableMethods = true

You can also make your own ConfigState and call Sdump on it.