Conversation
Variants of Version are known at compile time so requiring a Debug format is not necessary.
|
Thanks for the PR! My feeling is that an The way I would solve this myself in another crate is to just |
|
Yep, I'm doing the match statement right now. :) I thought it might be useful for others to have access to the mapping currently within debug, but statically. The RFCs standardizing HTTP seem to use the The function doesn't need to be called |
Stringifications of the variants of the
Versionare known at compile time so requiring aDebugformat is not necessary.This is nice for me specifically because I want to record the HTTP version of queries using
metricscrate. This crate allows users to record labels as either aStringor&'static str, and given I didn't want to allocate aStringwith theDebugformat I had to copy-paste the lookup.