Rollup merge of #37696 - arthurprs:patch-1, r=alexcrichton
Rollup merge of #37696 - arthurprs:patch-1, r=alexcrichton

Remove one bounds check from BufReader

Very minor thing. Otherwise the optimizer can't be sure that pos <= cap. Added a paranoid debug_assert to ensure correctness instead.

CC #37573

GBGamer/rust,GBGamer/rust,aidancully/rust,GBGamer/rust,GBGamer/rust,aidancully/rust,aidancully/rust,GBGamer/rust,GBGamer/rust,GBGamer/rust,graydon/rust,graydon/rust,graydon/rust,GBGamer/rust,aidancully/rust,graydon/rust,aidancully/rust,graydon/rust,graydon/rust,aidancully/rust