summaryrefslogtreecommitdiff
path: root/tests/rustdoc-js-std/parser-errors.js
diff options
context:
space:
mode:
authorbors <bors@rust-lang.org>2023-01-17 17:39:48 +0000
committerbors <bors@rust-lang.org>2023-01-17 17:39:48 +0000
commit3984bc5833db8bfb0acc522c9775383e4171f3de (patch)
treeb7b857372290acb972e12be100108d730af854a4 /tests/rustdoc-js-std/parser-errors.js
parent38a76f33220c4b9d13dda1fa8f6c629c8a7bcc5d (diff)
parentf1255380ac1cb7be1b6b0ac0eda5b1274b29eff6 (diff)
downloadrust-3984bc5833db8bfb0acc522c9775383e4171f3de.tar.gz
Auto merge of #106294 - Nilstrieb:noundef-everything, r=nikic
Put `noundef` on all scalars that don't allow uninit Previously, it was only put on scalars with range validity invariants like bool, was uninit was obviously invalid for those. Since then, we have normatively declared all uninit primitives to be undefined behavior and can therefore put `noundef` on them. The remaining concern was the `mem::uninitialized` function, which cause quite a lot of UB in the older parts of the ecosystem. After #99182, this function now doesn't return uninit values anymore, making users of it safe from this change. The only real sources of UB where people could encounter uninit primitives are `MaybeUninit::uninit().assume_init()`, which has always be clear in the docs about being UB and from heap allocations (like reading from the spare capacity of a vec). This is hopefully rare enough to not break anything. cc `@nagisa` `@scottmcm` `@nikic`
Diffstat (limited to 'tests/rustdoc-js-std/parser-errors.js')
0 files changed, 0 insertions, 0 deletions