about summary refs log tree commit diff
path: root/compiler/rustc_trait_selection/src/traits/codegen.rs
diff options
context:
space:
mode:
authorMichael Goulet <michael@errs.io>2022-01-17 20:38:38 -0800
committerMichael Goulet <michael@errs.io>2022-01-17 21:13:43 -0800
commitb651d5a1f4b3b8ab54926d4f5dd0390a94f5bac3 (patch)
tree1ba6ee0576696720278ff309eebcfbbb768bd8e2 /compiler/rustc_trait_selection/src/traits/codegen.rs
parentee5d8d37baaf5b5a81a98396952839c73ae41c68 (diff)
downloadrust-b651d5a1f4b3b8ab54926d4f5dd0390a94f5bac3.tar.gz
rust-b651d5a1f4b3b8ab54926d4f5dd0390a94f5bac3.zip
Fix Inline MIR pass on a function with un-satisfiable bounds
Diffstat (limited to 'compiler/rustc_trait_selection/src/traits/codegen.rs')
-rw-r--r--compiler/rustc_trait_selection/src/traits/codegen.rs2
1 files changed, 2 insertions, 0 deletions
diff --git a/compiler/rustc_trait_selection/src/traits/codegen.rs b/compiler/rustc_trait_selection/src/traits/codegen.rs
index 848aba7c912..a0c60898c15 100644
--- a/compiler/rustc_trait_selection/src/traits/codegen.rs
+++ b/compiler/rustc_trait_selection/src/traits/codegen.rs
@@ -65,6 +65,8 @@ pub fn codegen_fulfill_obligation<'tcx>(
             Err(Unimplemented) => {
                 // This can trigger when we probe for the source of a `'static` lifetime requirement
                 // on a trait object: `impl Foo for dyn Trait {}` has an implicit `'static` bound.
+                // This can also trigger when we have a global bound that is not actually satisfied,
+                // but was included during typeck due to the trivial_bounds feature.
                 infcx.tcx.sess.delay_span_bug(
                     rustc_span::DUMMY_SP,
                     &format!(