Skip to content

Commit

Permalink
gauge: fix unaligned 64-bit atomic operation panic on 32-bit archit…
Browse files Browse the repository at this point in the history
…ectures
  • Loading branch information
hagen1778 committed Dec 22, 2023
1 parent fa3e542 commit 49f6df7
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions gauge.go
Original file line number Diff line number Diff line change
Expand Up @@ -28,11 +28,11 @@ func NewGauge(name string, f func() float64) *Gauge {

// Gauge is a float64 gauge.
type Gauge struct {
// f is a callback, which is called for returning the gauge value.
f func() float64

// valueBits contains uint64 representation of float64 passed to Gauge.Set.
valueBits uint64

// f is a callback, which is called for returning the gauge value.
f func() float64
}

// Get returns the current value for g.
Expand Down

0 comments on commit 49f6df7

Please sign in to comment.