fix comment
This commit is contained in:
parent
b37e645d80
commit
a42c0d79da
3 changed files with 3 additions and 4 deletions
|
@ -10,7 +10,7 @@ pub struct DropCheckOverflow<'tcx> {
|
|||
#[primary_span]
|
||||
pub span: Span,
|
||||
pub ty: Ty<'tcx>,
|
||||
pub note: String,
|
||||
pub overflow_ty: Ty<'tcx>,
|
||||
}
|
||||
|
||||
#[derive(SessionDiagnostic)]
|
||||
|
|
|
@ -117,8 +117,7 @@ pub struct DropckOutlivesResult<'tcx> {
|
|||
impl<'tcx> DropckOutlivesResult<'tcx> {
|
||||
pub fn report_overflows(&self, tcx: TyCtxt<'tcx>, span: Span, ty: Ty<'tcx>) {
|
||||
if let Some(overflow_ty) = self.overflows.get(0) {
|
||||
let note = format!("overflowed on {}", overflow_ty);
|
||||
tcx.sess.emit_err(DropCheckOverflow { span, ty, note });
|
||||
tcx.sess.emit_err(DropCheckOverflow { span, ty, overflow_ty: *overflow_ty });
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue