If I interpret this earlier explanation correctly, it's that formatting is by itself considered an infallible operation (and thus Display
impls aren't supposed to produce errors on their own), but there is one reason it might fail: if an error is generated in the underlying writer itself, which only needs to be able to be propagated, hence the Result
return type. However, writing to a memory buffer is expected never to fail.
3 Likes