enum-stringer

command
v0.0.0-...-eb9e24c Latest Latest
Warning

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

Go to latest
Published: Jul 9, 2024 License: Apache-2.0 Imports: 4 Imported by: 0

README

Enum Stringer

This example shows how anytype can be used for enums. It requires Go stringer tool to be installed.

  1. Install stringer go install golang.org/x/tools/cmd/stringer@latest
  2. Regenerate stringer files if needed go generate
  3. Run go run . --pill Placebo --jar Aspirin --jar Ibuprofen, and see it prints:
Placebo
[Aspirin Ibuprofen]

Documentation

The Go Gopher

There is no documentation for this package.

Jump to

Keyboard shortcuts

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