Skip to content

Commit

Permalink
Auto merge of #68929 - matprec:consistent-issue-references, r=Dylan-DPC
Browse files Browse the repository at this point in the history
Make issue references consistent

Fixes #62976

cc #63008

r? @varkor because you reviewed the original pr
  • Loading branch information
bors committed Feb 11, 2020
2 parents 0f0cdf6 + 7b55517 commit dc4242d
Show file tree
Hide file tree
Showing 266 changed files with 778 additions and 735 deletions.
10 changes: 5 additions & 5 deletions src/librustc/traits/error_reporting/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -702,11 +702,11 @@ impl<'a, 'tcx> InferCtxt<'a, 'tcx> {
if self.predicate_may_hold(&unit_obligation) {
err.note(
"the trait is implemented for `()`. \
Possibly this error has been caused by changes to \
Rust's type-inference algorithm \
(see: https://github.com/rust-lang/rust/issues/48950 \
for more info). Consider whether you meant to use the \
type `()` here instead.",
Possibly this error has been caused by changes to \
Rust's type-inference algorithm (see issue #48950 \
<https://github.com/rust-lang/rust/issues/48950> \
for more information). Consider whether you meant to use \
the type `()` here instead.",
);
}
}
Expand Down
6 changes: 3 additions & 3 deletions src/librustc/traits/error_reporting/suggestions.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1511,9 +1511,9 @@ impl<'a, 'tcx> InferCtxt<'a, 'tcx> {
);
if suggest_const_in_array_repeat_expressions {
err.note(
"this array initializer can be evaluated at compile-time, for more \
information, see issue \
https://github.com/rust-lang/rust/issues/49147",
"this array initializer can be evaluated at compile-time, see issue \
#48147 <https://github.com/rust-lang/rust/issues/49147> \
for more information",
);
if tcx.sess.opts.unstable_features.is_nightly_build() {
err.help(
Expand Down
5 changes: 3 additions & 2 deletions src/librustc/ty/error.rs
Original file line number Diff line number Diff line change
Expand Up @@ -483,8 +483,9 @@ impl Trait for X {
if ty.is_closure() || ty.is_generator() {
db.note(
"closures cannot capture themselves or take themselves as argument;\n\
this error may be the result of a recent compiler bug-fix,\n\
see https://github.com/rust-lang/rust/issues/46062 for more details",
this error may be the result of a recent compiler bug-fix,\n\
see issue #46062 <https://github.com/rust-lang/rust/issues/46062>\n\
for more information",
);
}
}
Expand Down
3 changes: 2 additions & 1 deletion src/librustc_ast_passes/ast_validation.rs
Original file line number Diff line number Diff line change
Expand Up @@ -996,7 +996,8 @@ impl<'a> Visitor<'a> for AstValidator<'a> {
)
.span_label(predicate.span, "not supported")
.note(
"for more information, see https://github.com/rust-lang/rust/issues/20041",
"see issue #20041 <https://github.com/rust-lang/rust/issues/20041> \
for more information",
)
.emit();
}
Expand Down
57 changes: 38 additions & 19 deletions src/librustc_lint/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -324,47 +324,58 @@ fn register_builtins(store: &mut LintStore, no_interleave_lints: bool) {
);
store.register_removed(
"hr_lifetime_in_assoc_type",
"converted into hard error, see https://github.com/rust-lang/rust/issues/33685",
"converted into hard error, see issue #33685 \
<https://github.com/rust-lang/rust/issues/33685> for more information",
);
store.register_removed(
"inaccessible_extern_crate",
"converted into hard error, see https://github.com/rust-lang/rust/issues/36886",
"converted into hard error, see issue #36886 \
<https://github.com/rust-lang/rust/issues/36886> for more information",
);
store.register_removed(
"super_or_self_in_global_path",
"converted into hard error, see https://github.com/rust-lang/rust/issues/36888",
"converted into hard error, see issue #36888 \
<https://github.com/rust-lang/rust/issues/36888> for more information",
);
store.register_removed(
"overlapping_inherent_impls",
"converted into hard error, see https://github.com/rust-lang/rust/issues/36889",
"converted into hard error, see issue #36889 \
<https://github.com/rust-lang/rust/issues/36889> for more information",
);
store.register_removed(
"illegal_floating_point_constant_pattern",
"converted into hard error, see https://github.com/rust-lang/rust/issues/36890",
"converted into hard error, see issue #36890 \
<https://github.com/rust-lang/rust/issues/36890> for more information",
);
store.register_removed(
"illegal_struct_or_enum_constant_pattern",
"converted into hard error, see https://github.com/rust-lang/rust/issues/36891",
"converted into hard error, see issue #36891 \
<https://github.com/rust-lang/rust/issues/36891> for more information",
);
store.register_removed(
"lifetime_underscore",
"converted into hard error, see https://github.com/rust-lang/rust/issues/36892",
"converted into hard error, see issue #36892 \
<https://github.com/rust-lang/rust/issues/36892> for more information",
);
store.register_removed(
"extra_requirement_in_impl",
"converted into hard error, see https://github.com/rust-lang/rust/issues/37166",
"converted into hard error, see issue #37166 \
<https://github.com/rust-lang/rust/issues/37166> for more information",
);
store.register_removed(
"legacy_imports",
"converted into hard error, see https://github.com/rust-lang/rust/issues/38260",
"converted into hard error, see issue #38260 \
<https://github.com/rust-lang/rust/issues/38260> for more information",
);
store.register_removed(
"coerce_never",
"converted into hard error, see https://github.com/rust-lang/rust/issues/48950",
"converted into hard error, see issue #48950 \
<https://github.com/rust-lang/rust/issues/48950> for more information",
);
store.register_removed(
"resolve_trait_on_defaulted_unit",
"converted into hard error, see https://github.com/rust-lang/rust/issues/48950",
"converted into hard error, see issue #48950 \
<https://github.com/rust-lang/rust/issues/48950> for more information",
);
store.register_removed(
"private_no_mangle_fns",
Expand All @@ -377,35 +388,43 @@ fn register_builtins(store: &mut LintStore, no_interleave_lints: bool) {
store.register_removed("bad_repr", "replaced with a generic attribute input check");
store.register_removed(
"duplicate_matcher_binding_name",
"converted into hard error, see https://github.com/rust-lang/rust/issues/57742",
"converted into hard error, see issue #57742 \
<https://github.com/rust-lang/rust/issues/57742> for more information",
);
store.register_removed(
"incoherent_fundamental_impls",
"converted into hard error, see https://github.com/rust-lang/rust/issues/46205",
"converted into hard error, see issue #46205 \
<https://github.com/rust-lang/rust/issues/46205> for more information",
);
store.register_removed(
"legacy_constructor_visibility",
"converted into hard error, see https://github.com/rust-lang/rust/issues/39207",
"converted into hard error, see issue #39207 \
<https://github.com/rust-lang/rust/issues/39207> for more information",
);
store.register_removed(
"legacy_directory_ownership",
"converted into hard error, see https://github.com/rust-lang/rust/issues/37872",
"converted into hard error, see issue #37872 \
<https://github.com/rust-lang/rust/issues/37872> for more information",
);
store.register_removed(
"safe_extern_statics",
"converted into hard error, see https://github.com/rust-lang/rust/issues/36247",
"converted into hard error, see issue #36247 \
<https://github.com/rust-lang/rust/issues/36247> for more information",
);
store.register_removed(
"parenthesized_params_in_types_and_modules",
"converted into hard error, see https://github.com/rust-lang/rust/issues/42238",
"converted into hard error, see issue #42238 \
<https://github.com/rust-lang/rust/issues/42238> for more information",
);
store.register_removed(
"duplicate_macro_exports",
"converted into hard error, see https://github.com/rust-lang/rust/issues/35896",
"converted into hard error, see issue #35896 \
<https://github.com/rust-lang/rust/issues/35896> for more information",
);
store.register_removed(
"nested_impl_trait",
"converted into hard error, see https://github.com/rust-lang/rust/issues/59014",
"converted into hard error, see issue #59014 \
<https://github.com/rust-lang/rust/issues/59014> for more information",
);
store.register_removed("plugin_as_library", "plugins have been deprecated and retired");
}
Expand Down
11 changes: 7 additions & 4 deletions src/librustc_mir/transform/check_consts/validation.rs
Original file line number Diff line number Diff line change
Expand Up @@ -565,7 +565,10 @@ impl Visitor<'tcx> for Validator<'_, 'mir, 'tcx> {

fn error_min_const_fn_violation(tcx: TyCtxt<'_>, span: Span, msg: Cow<'_, str>) {
struct_span_err!(tcx.sess, span, E0723, "{}", msg)
.note("for more information, see issue https://github.com/rust-lang/rust/issues/57563")
.note(
"see issue #57563 <https://github.com/rust-lang/rust/issues/57563> \
for more information",
)
.help("add `#![feature(const_fn)]` to the crate attributes to enable")
.emit();
}
Expand Down Expand Up @@ -593,9 +596,9 @@ fn check_short_circuiting_in_const_local(item: &Item<'_, 'tcx>) {
*span,
&format!(
"use of {} here does not actually short circuit due to \
the const evaluator presently not being able to do control flow. \
See https://github.com/rust-lang/rust/issues/49146 for more \
information.",
the const evaluator presently not being able to do control flow. \
See issue #49146 <https://github.com/rust-lang/rust/issues/49146> \
for more information.",
kind
),
);
Expand Down
5 changes: 3 additions & 2 deletions src/librustc_parse/lexer/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -248,8 +248,9 @@ impl<'a> StringReader<'a> {
a future release!",
)
.note(
"for more information, see issue #42326 \
<https://github.com/rust-lang/rust/issues/42326>",
"see issue #42326 \
<https://github.com/rust-lang/rust/issues/42326> \
for more information",
)
.emit();
None
Expand Down
4 changes: 2 additions & 2 deletions src/librustc_parse/parser/diagnostics.rs
Original file line number Diff line number Diff line change
Expand Up @@ -366,8 +366,8 @@ impl<'a> Parser<'a> {
type: `<expr>: <type>`",
);
err.note(
"for more information, see \
https://github.com/rust-lang/rust/issues/23416",
"see issue #23416 <https://github.com/rust-lang/rust/issues/23416> \
for more information",
);
}
}
Expand Down
5 changes: 4 additions & 1 deletion src/librustc_parse/parser/expr.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1295,7 +1295,10 @@ impl<'a> Parser<'a> {
`proc_macro::Literal::*_unsuffixed` for code that will desugar \
to tuple field access",
);
err.note("for more context, see https://github.com/rust-lang/rust/issues/60210");
err.note(
"see issue #60210 <https://github.com/rust-lang/rust/issues/60210> \
for more information",
);
err
} else {
self.struct_span_err(sp, &format!("suffixes on {} are invalid", kind))
Expand Down
4 changes: 2 additions & 2 deletions src/librustc_passes/check_attr.rs
Original file line number Diff line number Diff line change
Expand Up @@ -120,8 +120,8 @@ impl CheckAttrVisitor<'tcx> {
a future release!",
)
.note(
"for more information, see issue #65833 \
<https://github.com/rust-lang/rust/issues/65833>",
"see issue #65833 <https://github.com/rust-lang/rust/issues/65833> \
for more information",
)
.emit();
true
Expand Down
4 changes: 2 additions & 2 deletions src/librustc_session/parse.rs
Original file line number Diff line number Diff line change
Expand Up @@ -86,8 +86,8 @@ pub fn feature_err_issue<'a>(

if let Some(n) = find_feature_issue(feature, issue) {
err.note(&format!(
"for more information, see https://github.com/rust-lang/rust/issues/{}",
n,
"see issue #{} <https://github.com/rust-lang/rust/issues/{}> for more information",
n, n,
));
}

Expand Down
3 changes: 2 additions & 1 deletion src/librustc_session/session.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1125,7 +1125,8 @@ fn validate_commandline_args_with_session_available(sess: &Session) {
sess.err(
"Profile-guided optimization does not yet work in conjunction \
with `-Cpanic=unwind` on Windows when targeting MSVC. \
See https://github.com/rust-lang/rust/issues/61002 for details.",
See issue #61002 <https://github.com/rust-lang/rust/issues/61002> \
for more information.",
);
}

Expand Down
7 changes: 4 additions & 3 deletions src/librustc_typeck/check/demand.rs
Original file line number Diff line number Diff line change
Expand Up @@ -798,9 +798,10 @@ impl<'a, 'tcx> FnCtxt<'a, 'tcx> {
);
err.warn(
"if the rounded value cannot be represented by the target \
integer type, including `Inf` and `NaN`, casting will cause \
undefined behavior \
(https://github.com/rust-lang/rust/issues/10184)",
integer type, including `Inf` and `NaN`, casting will cause \
undefined behavior \
(see issue #10184 <https://github.com/rust-lang/rust/issues/10184> \
for more information)",
);
}
true
Expand Down
5 changes: 4 additions & 1 deletion src/librustc_typeck/collect.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2440,7 +2440,10 @@ fn associated_item_predicates(
trait_item.span,
&format!("{}-generic associated types are not yet implemented", arg_kind),
)
.note("for more information, see https://github.com/rust-lang/rust/issues/44265")
.note(
"for more information, see issue #44265 \
<https://github.com/rust-lang/rust/issues/44265> for more information",
)
.emit();
had_error = true;
}
Expand Down
5 changes: 4 additions & 1 deletion src/librustdoc/config.rs
Original file line number Diff line number Diff line change
Expand Up @@ -570,7 +570,10 @@ fn check_deprecated_options(matches: &getopts::Matches, diag: &rustc_errors::Han
if matches.opt_present(flag) {
let mut err =
diag.struct_warn(&format!("the '{}' flag is considered deprecated", flag));
err.warn("please see https://github.com/rust-lang/rust/issues/44136");
err.warn(
"see issue #44136 <https://github.com/rust-lang/rust/issues/44136> \
for more information",
);

if *flag == "no-defaults" {
err.help("you may want to use --document-private-items");
Expand Down
5 changes: 4 additions & 1 deletion src/librustdoc/core.rs
Original file line number Diff line number Diff line change
Expand Up @@ -416,7 +416,10 @@ pub fn run_core(options: RustdocOptions) -> (clean::Crate, RenderInfo, RenderOpt
considered deprecated",
name
));
msg.warn("please see https://github.com/rust-lang/rust/issues/44136");
msg.warn(
"see issue #44136 <https://github.com/rust-lang/rust/issues/44136> \
for more information",
);

if name == "no_default_passes" {
msg.help("you may want to use `#![doc(document_private_items)]`");
Expand Down
4 changes: 2 additions & 2 deletions src/test/rustdoc-ui/deprecated-attrs.stderr
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
warning: the `#![doc(no_default_passes)]` attribute is considered deprecated
|
= warning: please see https://github.com/rust-lang/rust/issues/44136
= warning: see issue #44136 <https://github.com/rust-lang/rust/issues/44136> for more information
= help: you may want to use `#![doc(document_private_items)]`

warning: the `#![doc(passes = "...")]` attribute is considered deprecated
|
= warning: please see https://github.com/rust-lang/rust/issues/44136
= warning: see issue #44136 <https://github.com/rust-lang/rust/issues/44136> for more information

2 changes: 1 addition & 1 deletion src/test/ui-fulldeps/feature-gate-plugin.stderr
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ error[E0658]: compiler plugins are deprecated
LL | #![plugin(empty_plugin)]
| ^^^^^^^^^^^^^^^^^^^^^^^^
|
= note: for more information, see https://github.com/rust-lang/rust/issues/29597
= note: see issue #29597 <https://github.com/rust-lang/rust/issues/29597> for more information
= help: add `#![feature(plugin)]` to the crate attributes to enable

warning: use of deprecated attribute `plugin`: compiler plugins are deprecated. See https://github.com/rust-lang/rust/pull/64675
Expand Down
2 changes: 1 addition & 1 deletion src/test/ui-fulldeps/gated-plugin.stderr
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ error[E0658]: compiler plugins are deprecated
LL | #![plugin(empty_plugin)]
| ^^^^^^^^^^^^^^^^^^^^^^^^
|
= note: for more information, see https://github.com/rust-lang/rust/issues/29597
= note: see issue #29597 <https://github.com/rust-lang/rust/issues/29597> for more information
= help: add `#![feature(plugin)]` to the crate attributes to enable

warning: use of deprecated attribute `plugin`: compiler plugins are deprecated. See https://github.com/rust-lang/rust/pull/64675
Expand Down
Loading

0 comments on commit dc4242d

Please sign in to comment.