MCPcopy
hub / github.com/marmotedu/iam / Value

Struct Value

tools/codegen/codegen.go:308–320  ·  view source on GitHub ↗

Value represents a declared constant.

Source from the content-addressed store, hash-verified

306
307// Value represents a declared constant.
308type Value struct {
309 comment string
310 originalName string // The name of the constant.
311 name string // The name with trimmed prefix.
312 // The value is stored as a bit pattern alone. The boolean tells us
313 // whether to interpret it as an int64 or a uint64; the only place
314 // this matters is when sorting.
315 // Much of the time the str field is all we need; it is printed
316 // by Value.String.
317 value uint64 // Will be converted to int64 when needed.
318 signed bool // Whether the constant is a signed type.
319 str string // The string representation given by the "go/constant" package.
320}
321
322func (v *Value) String() string {
323 return v.str

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected