Sign in
rust
/
rust
/
HEAD
/
.
/
tests
/
ui
/
precondition-checks
/
char-from_u32_unchecked.rs
blob: 7c34d926d3e9fe34a77321deb2845d3eef36867c [
file
] [
log
] [
blame
]
//@ run-crash
//@ compile-flags: -Copt-level=3 -Cdebug-assertions=no -Zub-checks=yes
//@ error-pattern: unsafe precondition(s) violated: invalid value for `char`
fn
main
()
{
unsafe
{
char
::
from_u32_unchecked
(
0xD801
);
}
}