Skip to content

Commit 39fc195

Browse files
authored
Merge pull request #659 from prometheus/beorn7/nit
Use a cleaner initialization of `separatorByteSlice`
2 parents 9a2ab94 + 19af62d commit 39fc195

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

prometheus/metric.go

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,13 +18,12 @@ import (
1818
"time"
1919

2020
"github.com/golang/protobuf/proto"
21+
"github.com/prometheus/common/model"
2122

2223
dto "github.com/prometheus/client_model/go"
2324
)
2425

25-
const separatorByte byte = 255
26-
27-
var separatorByteSlice = []byte{255} // For convenient use with xxhash.
26+
var separatorByteSlice = []byte{model.SeparatorByte} // For convenient use with xxhash.
2827

2928
// A Metric models a single sample value with its meta data being exported to
3029
// Prometheus. Implementations of Metric in this package are Gauge, Counter,

0 commit comments

Comments
 (0)