From 429ae93c09055a1fde14ef4cbf807bdfcbe65584 Mon Sep 17 00:00:00 2001 From: toidiu Date: Thu, 26 Jul 2018 20:32:01 -0400 Subject: [PATCH] some comment about not infering static lifetimes test --- src/test/ui/rfc-2093-infer-outlives/dont-infer-static.rs | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/test/ui/rfc-2093-infer-outlives/dont-infer-static.rs b/src/test/ui/rfc-2093-infer-outlives/dont-infer-static.rs index c70170112778..72d5127c294d 100644 --- a/src/test/ui/rfc-2093-infer-outlives/dont-infer-static.rs +++ b/src/test/ui/rfc-2093-infer-outlives/dont-infer-static.rs @@ -12,8 +12,14 @@ #![feature(infer_outlives_requirements)] +/* + * We don't infer `T: 'static` outlives relationships by default. + * Instead an additional feature gate `infer_static_outlives_requirements` + * is required. + */ + struct Foo { - bar: Bar //~ ERROR 16:5: 16:16: the parameter type `U` may not live long enough [E0310] + bar: Bar //~ ERROR 22:5: 22:16: the parameter type `U` may not live long enough [E0310] } struct Bar { x: T,