From db4818f3253254bafac707d58ec3d13def0e6f86 Mon Sep 17 00:00:00 2001 From: Mazdak Farrokhzad Date: Sat, 21 Dec 2019 03:32:54 +0100 Subject: [PATCH] span_suggestion_hidden -> tool_only_span_suggestion --- src/librustc_parse/parser/ty.rs | 2 +- src/test/ui/issues/issue-58857.stderr | 2 -- src/test/ui/parser/issue-33418.stderr | 10 ---------- ...67146-negative-outlives-bound-syntactic-fail.stderr | 6 ------ 4 files changed, 1 insertion(+), 19 deletions(-) diff --git a/src/librustc_parse/parser/ty.rs b/src/librustc_parse/parser/ty.rs index b83ec71124d..9f5fd6d0a36 100644 --- a/src/librustc_parse/parser/ty.rs +++ b/src/librustc_parse/parser/ty.rs @@ -407,7 +407,7 @@ fn error_negative_bounds( } new_bound_list = new_bound_list.replacen(" +", ":", 1); } - err.span_suggestion_hidden( + err.tool_only_span_suggestion( bound_list, &format!("remove the bound{}", pluralize!(negative_bounds_len)), new_bound_list, diff --git a/src/test/ui/issues/issue-58857.stderr b/src/test/ui/issues/issue-58857.stderr index 9bc80cc270b..e2acec47e5a 100644 --- a/src/test/ui/issues/issue-58857.stderr +++ b/src/test/ui/issues/issue-58857.stderr @@ -3,8 +3,6 @@ error: negative bounds are not supported | LL | impl Conj{} | ^^^^^^^^ negative bounds are not supported - | - = help: remove the bound error: aborting due to previous error diff --git a/src/test/ui/parser/issue-33418.stderr b/src/test/ui/parser/issue-33418.stderr index 7f361dbe271..9a8733e8929 100644 --- a/src/test/ui/parser/issue-33418.stderr +++ b/src/test/ui/parser/issue-33418.stderr @@ -3,24 +3,18 @@ error: negative bounds are not supported | LL | trait Tr: !SuperA {} | ^^^^^^^^^ negative bounds are not supported - | - = help: remove the bound error: negative bounds are not supported --> $DIR/issue-33418.rs:5:19 | LL | trait Tr2: SuperA + !SuperB {} | ^^^^^^^^^ negative bounds are not supported - | - = help: remove the bound error: negative bounds are not supported --> $DIR/issue-33418.rs:7:10 | LL | trait Tr3: !SuperA + SuperB {} | ^^^^^^^^^ negative bounds are not supported - | - = help: remove the bound error: negative bounds are not supported --> $DIR/issue-33418.rs:9:10 @@ -29,8 +23,6 @@ LL | trait Tr4: !SuperA + SuperB | ^^^^^^^^^ LL | + !SuperC + SuperD {} | ^^^^^^^^^ negative bounds are not supported - | - = help: remove the bounds error: negative bounds are not supported --> $DIR/issue-33418.rs:12:10 @@ -39,8 +31,6 @@ LL | trait Tr5: !SuperA | ^^^^^^^^^ LL | + !SuperB {} | ^^^^^^^^^ negative bounds are not supported - | - = help: remove the bounds error: aborting due to 5 previous errors diff --git a/src/test/ui/parser/issue-67146-negative-outlives-bound-syntactic-fail.stderr b/src/test/ui/parser/issue-67146-negative-outlives-bound-syntactic-fail.stderr index 74437c1a008..4dc06347304 100644 --- a/src/test/ui/parser/issue-67146-negative-outlives-bound-syntactic-fail.stderr +++ b/src/test/ui/parser/issue-67146-negative-outlives-bound-syntactic-fail.stderr @@ -3,24 +3,18 @@ error: negative bounds are not supported | LL | fn f1() {} | ^^^^^^^^^^ negative bounds are not supported - | - = help: remove the bound error: negative bounds are not supported --> $DIR/issue-67146-negative-outlives-bound-syntactic-fail.rs:9:18 | LL | fn f2<'a, T: Ord + !'a>() {} | ^^^^^ negative bounds are not supported - | - = help: remove the bound error: negative bounds are not supported --> $DIR/issue-67146-negative-outlives-bound-syntactic-fail.rs:11:12 | LL | fn f3<'a, T: !'a + Ord>() {} | ^^^^^ negative bounds are not supported - | - = help: remove the bound error: aborting due to 3 previous errors -- 2.44.0