spew

package
v2.5.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 26, 2026 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Overview

Package spew implements a deep pretty printer for Go data structures to aid in debugging.

It exposes the pretty-printer used internally by github.com/go-openapi/testify/v2.

This a modernized version of the well-known github.com/davecgh/go-spew.

The original software is Copyright: 2012-2016 Dave Collins, under an ISC license.

Index

Constants

This section is empty.

Variables

View Source
var Config = ConfigState{
	Indent:             " ",
	EnableTimeStringer: true,
}

Config is the active configuration of the top-level functions.

This is an independent copy that does not affect the internal testify configuration. The configuration can be changed by modifying the contents of spew.Config.

Functions

func Dump

func Dump(a ...any)

Dump displays the passed parameters to standard out with newlines, customizable indentation, and additional debug information such as complete types and all pointer addresses used to indirect to the final value.

func Fdump

func Fdump(w io.Writer, a ...any)

Fdump formats and displays the passed arguments to io.Writer w. It formats exactly the same as Dump.

func Sdump

func Sdump(a ...any) string

Sdump returns a string with the passed arguments formatted exactly the same as Dump.

Types

type ConfigState

type ConfigState = ispew.ConfigState

ConfigState houses the configuration options used by spew to format and display values.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL