someone, somewhere, asked me about why `postcard::to_stdvec` returns a result, if pushing to a Vec can never fail. I told them it was probably an oversight, b/c...
bsky.app·20h·
Discuss: Bluesky
🔒Borrow Checker
Preview
Report Post

someone, somewhere, asked me about why postcard::to_stdvec returns a result, if pushing to a Vec can never fail. I told them it was probably an oversight, b/c I copied and pasted from the heapless version (where push CAN fail).

BUT, I was wrong. There is exactly ONE reasonable case this CAN fail:

Similar Posts

Loading similar posts...