Auto merge of #62507 - petrochenkov:macunstab, r=alexcrichton

Remove derives `Encodable`/`Decodable` and unstabilize attribute `#[bench]`

`Encodable` and `Decodable` were deprecated before 1.0 and emitted an unsuppressable warning all this time.
`#[bench]` is a part of the custom test framework feature and cannot be used meaningfully on stable, only as `cfg(false)`.

Crater results can be found in https://github.com/rust-lang/rust/pull/62507#issuecomment-513850732 and below.

This PR also reroutes the tracking issue for `feature(test)` from #27812 (compiler internals) to #50297 (custom test frameworks).

Closes https://github.com/rust-lang/rust/issues/62048
This commit is contained in:
bors 2019-08-01 11:07:26 +00:00
commit f23a5f208d
22 changed files with 226 additions and 298 deletions

View file

@ -32,6 +32,7 @@
// check-pass
#![feature(test)]
#![warn(unused_attributes, unknown_lints)]
// UNGATED WHITE-LISTED BUILT-IN ATTRIBUTES

View file

@ -2,6 +2,8 @@
//! Test that makes sure wrongly-typed bench functions aren't ignored
#![feature(test)]
#[bench]
fn foo() { } //~ ERROR functions used as benches

View file

@ -1,11 +1,11 @@
error: functions used as benches must have signature `fn(&mut Bencher) -> impl Termination`
--> $DIR/issue-12997-1.rs:6:1
--> $DIR/issue-12997-1.rs:8:1
|
LL | fn foo() { }
| ^^^^^^^^^^^^
error: functions used as benches must have signature `fn(&mut Bencher) -> impl Termination`
--> $DIR/issue-12997-1.rs:9:1
--> $DIR/issue-12997-1.rs:11:1
|
LL | fn bar(x: isize, y: isize) { }
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

View file

@ -2,6 +2,8 @@
//! Test that makes sure wrongly-typed bench functions are rejected
#![feature(test)]
#[bench]
fn bar(x: isize) { }
//~^ ERROR mismatched types

View file

@ -1,5 +1,5 @@
error[E0308]: mismatched types
--> $DIR/issue-12997-2.rs:6:1
--> $DIR/issue-12997-2.rs:8:1
|
LL | fn bar(x: isize) { }
| ^^^^^^^^^^^^^^^^^^^^ expected isize, found mutable reference

View file

@ -1,4 +1,5 @@
// build-pass
// ignore-pass (different metadata emitted in different modes)
// compile-flags: --json=diagnostic-short --json artifacts --error-format=json
#![crate_type = "lib"]

View file

@ -1,4 +1,5 @@
// build-pass
// ignore-pass (different metadata emitted in different modes)
// compile-flags: --json=diagnostic-short,artifacts --error-format=json
#![crate_type = "lib"]