must

package
v0.5.3 Latest Latest
Warning

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

Go to latest
Published: Mar 15, 2024 License: Apache-2.0 Imports: 0 Imported by: 0

Documentation

Overview

Package must provides a generic Must function.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Must

func Must[T any](x T, err error) T

Must is a generic implementation of the Go Must idiom [1, 2]. It panics if the provided error is non-nil and returns x otherwise.

Types

This section is empty.

Jump to

Keyboard shortcuts

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