removed uses of feature gate
This commit is contained in:
parent
b908905b3d
commit
a32d2b43a2
26 changed files with 0 additions and 40 deletions
|
|
@ -2,8 +2,6 @@
|
|||
|
||||
// Test copy
|
||||
|
||||
#![feature(bindings_after_at)]
|
||||
|
||||
struct A { a: i32, b: i32 }
|
||||
struct B { a: i32, b: C }
|
||||
struct D { a: i32, d: C }
|
||||
|
|
|
|||
|
|
@ -2,8 +2,6 @@
|
|||
// It checks that you cannot use an AND-pattern (`binding @ pat`)
|
||||
// where one side is by-ref and the other is by-move.
|
||||
|
||||
#![feature(bindings_after_at)]
|
||||
|
||||
struct X {
|
||||
x: (),
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,7 +1,5 @@
|
|||
// See issue #12534.
|
||||
|
||||
#![feature(bindings_after_at)]
|
||||
|
||||
fn main() {}
|
||||
|
||||
struct A(Box<u8>);
|
||||
|
|
|
|||
|
|
@ -1,7 +1,5 @@
|
|||
// Test that moving on both sides of an `@` pattern is not allowed.
|
||||
|
||||
#![feature(bindings_after_at)]
|
||||
|
||||
fn main() {
|
||||
struct U; // Not copy!
|
||||
|
||||
|
|
|
|||
|
|
@ -2,7 +2,6 @@
|
|||
|
||||
// Test `@` patterns combined with `box` patterns.
|
||||
|
||||
#![feature(bindings_after_at)]
|
||||
#![feature(box_patterns)]
|
||||
|
||||
#[derive(Copy, Clone)]
|
||||
|
|
|
|||
|
|
@ -1,6 +1,5 @@
|
|||
// Test `@` patterns combined with `box` patterns.
|
||||
|
||||
#![feature(bindings_after_at)]
|
||||
#![feature(box_patterns)]
|
||||
|
||||
#[derive(Copy, Clone)]
|
||||
|
|
|
|||
|
|
@ -2,8 +2,6 @@
|
|||
|
||||
// Test `Copy` bindings in the rhs of `@` patterns.
|
||||
|
||||
#![feature(bindings_after_at)]
|
||||
|
||||
#[derive(Copy, Clone)]
|
||||
struct C;
|
||||
|
||||
|
|
|
|||
|
|
@ -1,8 +1,6 @@
|
|||
// Test that `by_move_binding @ pat_with_by_ref_bindings` is prevented even with promotion.
|
||||
// Currently this logic exists in THIR match checking as opposed to borrowck.
|
||||
|
||||
#![feature(bindings_after_at)]
|
||||
|
||||
fn main() {
|
||||
struct U;
|
||||
let a @ ref b = U; //~ ERROR borrow of moved value
|
||||
|
|
|
|||
|
|
@ -1,7 +1,5 @@
|
|||
// Test that `by_move_binding @ pat_with_by_ref_bindings` is prevented.
|
||||
|
||||
#![feature(bindings_after_at)]
|
||||
|
||||
fn main() {
|
||||
struct U;
|
||||
|
||||
|
|
|
|||
|
|
@ -1,7 +1,5 @@
|
|||
// Test that `ref mut? @ pat_with_by_move_bindings` is prevented.
|
||||
|
||||
#![feature(bindings_after_at)]
|
||||
|
||||
fn main() {
|
||||
struct U;
|
||||
|
||||
|
|
|
|||
|
|
@ -3,8 +3,6 @@
|
|||
// Test that `ref` patterns may be used on both sides
|
||||
// of an `@` pattern according to NLL borrowck.
|
||||
|
||||
#![feature(bindings_after_at)]
|
||||
|
||||
fn main() {
|
||||
struct U; // Not copy!
|
||||
|
||||
|
|
|
|||
|
|
@ -1,5 +1,3 @@
|
|||
#![feature(bindings_after_at)]
|
||||
|
||||
enum Option<T> {
|
||||
None,
|
||||
Some(T),
|
||||
|
|
|
|||
|
|
@ -1,7 +1,5 @@
|
|||
// Test that `ref mut x @ ref mut y` and varieties of that are not allowed.
|
||||
|
||||
#![feature(bindings_after_at)]
|
||||
|
||||
fn main() {
|
||||
struct U;
|
||||
|
||||
|
|
|
|||
|
|
@ -2,7 +2,6 @@
|
|||
|
||||
// run-pass
|
||||
|
||||
#![feature(bindings_after_at)]
|
||||
#![feature(box_patterns)]
|
||||
|
||||
#[derive(Debug, PartialEq)]
|
||||
|
|
|
|||
|
|
@ -1,7 +1,5 @@
|
|||
// Test that mixing `Copy` and non-`Copy` types in `@` patterns is forbidden.
|
||||
|
||||
#![feature(bindings_after_at)]
|
||||
|
||||
#[derive(Copy, Clone)]
|
||||
struct C;
|
||||
|
||||
|
|
|
|||
|
|
@ -7,7 +7,6 @@
|
|||
// If `binding` is allowed to influence `subpat`,
|
||||
// this would create problems for the generalization aforementioned.
|
||||
|
||||
#![feature(bindings_after_at)]
|
||||
|
||||
fn main() {
|
||||
struct NotCopy;
|
||||
|
|
|
|||
|
|
@ -1,6 +1,5 @@
|
|||
// check-pass
|
||||
|
||||
#![feature(bindings_after_at)]
|
||||
#![deny(unused_mut)]
|
||||
|
||||
fn main() {
|
||||
|
|
|
|||
|
|
@ -1,5 +1,3 @@
|
|||
#![feature(bindings_after_at)]
|
||||
|
||||
fn main() {
|
||||
let mut is_mut @ not_mut = 42;
|
||||
&mut is_mut;
|
||||
|
|
|
|||
|
|
@ -1,5 +1,3 @@
|
|||
#![feature(bindings_after_at)]
|
||||
|
||||
fn main() {
|
||||
let ref is_ref @ is_val = 42;
|
||||
*is_ref;
|
||||
|
|
|
|||
|
|
@ -1,6 +1,5 @@
|
|||
// run-pass
|
||||
|
||||
#![feature(bindings_after_at)]
|
||||
|
||||
struct A { a: u8, b: u8 }
|
||||
|
||||
|
|
|
|||
|
|
@ -1,7 +1,6 @@
|
|||
// Here we check that type ascription is syntactically invalid when
|
||||
// not in the top position of a ascribing a let binding or function parameter.
|
||||
|
||||
#![feature(bindings_after_at)]
|
||||
|
||||
// This has no effect.
|
||||
// We include it to demonstrate that this is the case:
|
||||
|
|
|
|||
|
|
@ -2,7 +2,6 @@
|
|||
|
||||
// run-pass
|
||||
|
||||
#![feature(bindings_after_at)]
|
||||
#![feature(box_patterns)]
|
||||
|
||||
#[derive(Debug, PartialEq)]
|
||||
|
|
|
|||
|
|
@ -2,7 +2,6 @@
|
|||
|
||||
// run-pass
|
||||
|
||||
#![feature(bindings_after_at)]
|
||||
|
||||
#[derive(Debug, PartialEq)]
|
||||
enum MatchArm {
|
||||
|
|
|
|||
|
|
@ -2,7 +2,6 @@
|
|||
|
||||
// run-pass
|
||||
|
||||
#![feature(bindings_after_at)]
|
||||
|
||||
#[derive(Debug, PartialEq)]
|
||||
enum MatchArm {
|
||||
|
|
|
|||
|
|
@ -1,7 +1,6 @@
|
|||
// Test that `binding @ subpat` acts as a product context with respect to duplicate binding names.
|
||||
// The code that is tested here lives in resolve (see `resolve_pattern_inner`).
|
||||
|
||||
#![feature(bindings_after_at)]
|
||||
|
||||
fn main() {
|
||||
fn f(a @ a @ a: ()) {}
|
||||
|
|
|
|||
|
|
@ -2,7 +2,6 @@
|
|||
|
||||
// run-pass
|
||||
|
||||
#![feature(bindings_after_at)]
|
||||
|
||||
#[derive(Debug, PartialEq)]
|
||||
enum MatchArm {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue