must_utils

package
v0.1.52 Latest Latest
Warning

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

Go to latest
Published: Mar 12, 2025 License: MIT Imports: 5 Imported by: 3

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AnyToErr added in v0.1.23

func AnyToErr(v any) error

func DoOrLog

func DoOrLog(
	f func(ctx context.Context) error,
	errorMsg string,
) func(ctx context.Context)

func DoOrLogWithStacktrace added in v0.1.3

func DoOrLogWithStacktrace(
	f func(ctx context.Context) error,
	errorMsg string,
) func(ctx context.Context)

func Must

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

func MustNoReturn added in v0.1.8

func MustNoReturn(err error)

func Unwrap added in v0.1.44

func Unwrap[T any](obj T, ok bool) T

Types

This section is empty.

Jump to

Keyboard shortcuts

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