Skip to content
This repository was archived by the owner on Oct 26, 2021. It is now read-only.

Commit 174b481

Browse files
committed
Update rustc for this rust-lang/rust#81997
1 parent e285d60 commit 174b481

File tree

3 files changed

+3
-34
lines changed

3 files changed

+3
-34
lines changed

liquid-rust-core-cli/src/main.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,7 @@ fn diagnostics(
4545
err: ParseError,
4646
) -> Result<(), codespan_reporting::files::Error> {
4747
use lalrpop_util::ParseError::*;
48+
4849
let diagnostic: Diagnostic<()> = match err {
4950
User { error } => Diagnostic::error().with_message(error.to_string()),
5051

liquid-rust-typeck/src/refineck.rs

Lines changed: 1 addition & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,8 @@ use ast::{FnBody, StatementKind};
77
use liquid_rust_core::{
88
ast::{self, ContDef, FnDef, Rvalue, Statement},
99
names::*,
10-
ty::{self, pred, subst::Subst, BaseTy, ContTy, Heap, Pred, Ty, TyCtxt, TyKind, TyS},
10+
ty::{self, pred, subst::Subst, BaseTy, ContTy, Pred, Ty, TyCtxt},
1111
};
12-
use pred::Place;
1312

1413
use crate::env::Env;
1514

@@ -316,34 +315,3 @@ impl<'a> RefineChecker<'a> {
316315
self.errors.push(err);
317316
}
318317
}
319-
320-
pub fn subtyping(tcx: &TyCtxt, heap1: &Heap, ty1: &TyS, heap2: &Heap, ty2: &TyS) -> Constraint {
321-
match (ty1.kind(), ty2.kind()) {
322-
(TyKind::Tuple(tup1), TyKind::Tuple(tup2)) if tup1.len() == tup2.len() => tup1
323-
.iter()
324-
.zip(tup2.types())
325-
.rev()
326-
.fold(Constraint::True, |c, ((f, ty1), ty2)| {
327-
Constraint::Conj(vec![
328-
subtyping(tcx, heap1, ty1, heap2, ty2),
329-
Constraint::from_binding(*f, ty1.clone(), c),
330-
])
331-
}),
332-
// TODO check regions
333-
(TyKind::Ref(bk1, _, l1), TyKind::Ref(bk2, _, l2)) if bk1 >= bk2 => {
334-
let ty1 = &tcx.selfify(&heap1[l1], Place::from(*l1));
335-
let ty2 = &heap2[l2];
336-
subtyping(tcx, heap1, ty1, heap2, ty2)
337-
}
338-
(TyKind::OwnRef(l1), TyKind::OwnRef(l2)) => {
339-
let ty1 = &tcx.selfify(&heap1[l1], Place::from(*l1));
340-
let ty2 = &heap2[l2];
341-
subtyping(tcx, heap1, ty1, heap2, ty2)
342-
}
343-
(TyKind::Refine(bty1, refine1), TyKind::Refine(bty2, refine2)) if bty1 == bty2 => {
344-
Constraint::from_subtype(*bty1, refine1, refine2)
345-
}
346-
(_, TyKind::Uninit(n)) if ty1.size() == *n => Constraint::True,
347-
_ => bug!("{} {}", ty1, ty2),
348-
}
349-
}

rust-toolchain

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
[toolchain]
2-
channel = "nightly-2020-12-16"
2+
channel = "nightly-2021-02-15"
33
components = ["rust-src", "rustc-dev", "llvm-tools-preview"]
44

0 commit comments

Comments
 (0)