This commit is contained in:
Ralf Jung 2018-07-11 11:58:10 +02:00
parent f511c5ea4a
commit f68323b28a

View File

@ -202,8 +202,8 @@ impl<'a, 'tcx> Visitor<'tcx> for UnsafetyChecker<'a, 'tcx> {
self.source_info.span) {
self.require_unsafe(
"assignment to non-`Copy` union field",
"the previous content of the field may be dropped, which \
cause undefined behavior if the field was not properly \
"the previous content of the field will be dropped, which \
causes undefined behavior if the field was not properly \
initialized")
} else {
// write to non-move union, safe