Skip to content

Commit f5f4c7c

Browse files
committedJul 17, 2024
Specify u64 explicitly
Signed-off-by: Max Inden <mail@max-inden.de>
1 parent b1951ad commit f5f4c7c

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed
 

‎src/collector.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ use crate::encoding::DescriptorEncoder;
2323
///
2424
/// impl Collector for MyCollector {
2525
/// fn encode(&self, mut encoder: DescriptorEncoder) -> Result<(), std::fmt::Error> {
26-
/// let counter = ConstCounter::new(42);
26+
/// let counter = ConstCounter::new(42u64);
2727
/// let metric_encoder = encoder.encode_descriptor(
2828
/// "my_counter",
2929
/// "some help",

‎src/encoding/text.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1014,7 +1014,7 @@ mod tests {
10141014
&self,
10151015
mut encoder: crate::encoding::DescriptorEncoder,
10161016
) -> Result<(), std::fmt::Error> {
1017-
let counter = crate::metrics::counter::ConstCounter::new(42);
1017+
let counter = crate::metrics::counter::ConstCounter::new(42u64);
10181018
let metric_encoder = encoder.encode_descriptor(
10191019
&self.name,
10201020
"some help",

‎src/registry.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -185,7 +185,7 @@ impl Registry {
185185
///
186186
/// impl Collector for MyCollector {
187187
/// fn encode(&self, mut encoder: DescriptorEncoder) -> Result<(), std::fmt::Error> {
188-
/// let counter = ConstCounter::new(42);
188+
/// let counter = ConstCounter::new(42u64);
189189
/// let metric_encoder = encoder.encode_descriptor(
190190
/// "my_counter",
191191
/// "some help",

0 commit comments

Comments
 (0)