What's the convention again for implementing Debug in Rust if you want to omit fields, but show that they do exist. Something like `.field("my_field", "...")` ?
-
-
Replying to @yoshuawuyts
I always go with "(omitted)" or "(private)" but I wouldn't say it's convention
1 reply 0 retweets 3 likes
Replying to @killercup @yoshuawuyts
Some also use <this style>, e.g. <unknown> in the debugit crate: https://docs.rs/debugit/0.1.2/src/debugit/lib.rs.html#60 … That might be inspired by gdb: <main>, argc=2, argv=0x7fffffffdfb8, init=<optimized out> <built-in>: No such file or directory. start_thread (arg=<optimized out>) at pthread_create.c:486
4:55 AM - 30 May 2019
0 replies
0 retweets
2 likes
Loading seems to be taking a while.
Twitter may be over capacity or experiencing a momentary hiccup. Try again or visit Twitter Status for more information.