2019-08-25 05:45:51 +02:00
|
|
|
// Test the suggestion to wrap an or-pattern as a function parameter in parens.
|
|
|
|
|
2024-02-16 20:02:50 +00:00
|
|
|
//@ run-rustfix
|
2019-08-25 05:45:51 +02:00
|
|
|
|
|
|
|
#![allow(warnings)]
|
|
|
|
|
|
|
|
fn main() {}
|
|
|
|
|
|
|
|
enum E { A, B }
|
|
|
|
use E::*;
|
|
|
|
|
|
|
|
#[cfg(FALSE)]
|
2021-02-12 18:04:37 -06:00
|
|
|
fn fun1((A | B): E) {} //~ ERROR top-level or-patterns are not allowed
|