Fix Ref inhabitedness comment
This commit is contained in:
parent
64c2a310e1
commit
9f609f9fef
@ -1574,10 +1574,9 @@ impl<'a, 'gcx, 'tcx> TyS<'tcx> {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
ty::Ref(..) => {
|
ty::Ref(..) => {
|
||||||
// Though references to uninhabited types are trivially uninhabited
|
// References to uninitialised memory is valid for any type, including
|
||||||
// theoretically, null references are permitted in unsafe code (as
|
// uninhabited types, in unsafe code, so we treat all references as
|
||||||
// long as the value is not dereferenced), so we treat all references
|
// inhabited.
|
||||||
// as inhabited.
|
|
||||||
false
|
false
|
||||||
}
|
}
|
||||||
_ => false,
|
_ => false,
|
||||||
|
Loading…
x
Reference in New Issue
Block a user