|
16 | 16 | //! will contain any fields attached to each event.
|
17 | 17 | //!
|
18 | 18 | //! `tracing` represents values as either one of a set of Rust primitives
|
19 |
| -//! (`i64`, `u64`, `f64`, `bool`, and `&str`) or using a `fmt::Display` or |
20 |
| -//! `fmt::Debug` implementation. `Subscriber`s are provided these primitive |
21 |
| -//! value types as `dyn Value` trait objects. |
| 19 | +//! (`i64`, `u64`, `f64`, `i128`, `u128`, `bool`, and `&str`) or using a |
| 20 | +//! `fmt::Display` or `fmt::Debug` implementation. `Subscriber`s are provided |
| 21 | +//! these primitive value types as `dyn Value` trait objects. |
22 | 22 | //!
|
23 | 23 | //! These trait objects can be formatted using `fmt::Debug`, but may also be
|
24 | 24 | //! recorded as typed data by calling the [`Value::record`] method on these
|
@@ -278,6 +278,16 @@ pub trait Visit {
|
278 | 278 | self.record_debug(field, &value)
|
279 | 279 | }
|
280 | 280 |
|
| 281 | + /// Visit a signed 128-bit integer value. |
| 282 | + fn record_i128(&mut self, field: &Field, value: i128) { |
| 283 | + self.record_debug(field, &value) |
| 284 | + } |
| 285 | + |
| 286 | + /// Visit an unsigned 128-bit integer value. |
| 287 | + fn record_u128(&mut self, field: &Field, value: u128) { |
| 288 | + self.record_debug(field, &value) |
| 289 | + } |
| 290 | + |
281 | 291 | /// Visit a boolean value.
|
282 | 292 | fn record_bool(&mut self, field: &Field, value: bool) {
|
283 | 293 | self.record_debug(field, &value)
|
@@ -490,6 +500,8 @@ impl_values! {
|
490 | 500 | record_u64(usize, u32, u16, u8 as u64),
|
491 | 501 | record_i64(i64),
|
492 | 502 | record_i64(isize, i32, i16, i8 as i64),
|
| 503 | + record_u128(u128), |
| 504 | + record_i128(i128), |
493 | 505 | record_bool(bool),
|
494 | 506 | record_f64(f64, f32 as f64)
|
495 | 507 | }
|
|
0 commit comments