diff options
| author | Niko Matsakis <niko@alum.mit.edu> | 2018-03-23 04:58:18 -0400 |
|---|---|---|
| committer | Niko Matsakis <niko@alum.mit.edu> | 2018-04-23 13:28:14 -0400 |
| commit | cfbf62f7dfcf2f89d12b59140fe0d0f95dc5afbd (patch) | |
| tree | b623822b37b5670d15dbb6b897dcba74cfeccb7d /src | |
| parent | c8a52850cffd1e13e1f695451127f981345c72ec (diff) | |
| download | rust-cfbf62f7dfcf2f89d12b59140fe0d0f95dc5afbd.tar.gz rust-cfbf62f7dfcf2f89d12b59140fe0d0f95dc5afbd.zip | |
add `Goal::CannotProve` and extract `ProgramClause` struct
Diffstat (limited to 'src')
| -rw-r--r-- | src/librustc/ich/impls_ty.rs | 1 | ||||
| -rw-r--r-- | src/librustc/traits/mod.rs | 3 | ||||
| -rw-r--r-- | src/librustc/traits/structural_impls.rs | 2 |
3 files changed, 5 insertions, 1 deletions
diff --git a/src/librustc/ich/impls_ty.rs b/src/librustc/ich/impls_ty.rs index acb1d2272ef..322cfd55510 100644 --- a/src/librustc/ich/impls_ty.rs +++ b/src/librustc/ich/impls_ty.rs @@ -1413,6 +1413,7 @@ impl<'a, 'tcx> HashStable<StableHashingContext<'a>> for traits::Goal<'tcx> { quantifier.hash_stable(hcx, hasher); goal.hash_stable(hcx, hasher); }, + CannotProve => { }, } } } diff --git a/src/librustc/traits/mod.rs b/src/librustc/traits/mod.rs index 8d2398d3409..b05c4539f6a 100644 --- a/src/librustc/traits/mod.rs +++ b/src/librustc/traits/mod.rs @@ -286,7 +286,8 @@ pub enum Goal<'tcx> { And(&'tcx Goal<'tcx>, &'tcx Goal<'tcx>), Not(&'tcx Goal<'tcx>), DomainGoal(DomainGoal<'tcx>), - Quantified(QuantifierKind, ty::Binder<&'tcx Goal<'tcx>>) + Quantified(QuantifierKind, ty::Binder<&'tcx Goal<'tcx>>), + CannotProve, } impl<'tcx> Goal<'tcx> { diff --git a/src/librustc/traits/structural_impls.rs b/src/librustc/traits/structural_impls.rs index 31c5bf1bbad..1e3e4160de1 100644 --- a/src/librustc/traits/structural_impls.rs +++ b/src/librustc/traits/structural_impls.rs @@ -491,6 +491,7 @@ impl<'tcx> fmt::Display for traits::Goal<'tcx> { // FIXME: appropriate binder names write!(fmt, "{}<> {{ {} }}", qkind, goal.skip_binder()) } + CannotProve => write!(fmt, "CannotProve"), } } } @@ -557,6 +558,7 @@ EnumTypeFoldableImpl! { (traits::Goal::Not)(goal), (traits::Goal::DomainGoal)(domain_goal), (traits::Goal::Quantified)(qkind, goal), + (traits::Goal::CannotProve), } } |
