debug

package
v8.0.1 Latest Latest
Warning

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

Go to latest
Published: Jul 14, 2022 License: Apache-2.0, BSD-2-Clause, BSD-3-Clause, + 8 more Imports: 0 Imported by: 0

Documentation

Overview

Package debug provides APIs for conditional runtime assertions and debug logging.

Using Assert

To enable runtime assertions, build with the assert tag. When the assert tag is omitted, the code for the assertion will be omitted from the binary.

Using Log

To enable runtime debug logs, build with the debug tag. When the debug tag is omitted, the code for logging will be omitted from the binary.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Assert

func Assert(cond bool, msg interface{})

Assert will panic with msg if cond is false.

msg must be a string, func() string or fmt.Stringer.

func Log

func Log(interface{})

Types

This section is empty.

Jump to

Keyboard shortcuts

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