mirror of
https://github.com/prometheus/prometheus.git
synced 2025-03-05 20:59:13 -08:00
Merge pull request #1510 from prometheus/beorn7/fix
Work around compiler bug
This commit is contained in:
commit
eb183ce154
|
@ -759,7 +759,12 @@ func (c varbitChunk) addZeroBit(offset uint16) uint16 {
|
||||||
// Just increase the offset.
|
// Just increase the offset.
|
||||||
return offset + 1
|
return offset + 1
|
||||||
}
|
}
|
||||||
c[offset/8] &^= bitMask[1][offset%8]
|
newByte := c[offset/8] &^ bitMask[1][offset%8]
|
||||||
|
c[offset/8] = newByte
|
||||||
|
// TODO(beorn7): The two lines above could be written as
|
||||||
|
// c[offset/8] &^= bitMask[1][offset%8]
|
||||||
|
// However, that tickles a compiler bug with GOARCH=386.
|
||||||
|
// See https://github.com/prometheus/prometheus/issues/1509
|
||||||
return offset + 1
|
return offset + 1
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue