]> git.lizzy.rs Git - rust.git/blob - src/test/run-pass/issue-41213.rs
Rollup merge of #41249 - GuillaumeGomez:rustdoc-render, r=steveklabnik,frewsxcv
[rust.git] / src / test / run-pass / issue-41213.rs
1 // Copyright 2017 The Rust Project Developers. See the COPYRIGHT
2 // file at the top-level directory of this distribution and at
3 // http://rust-lang.org/COPYRIGHT.
4 //
5 // Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
6 // http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
7 // <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
8 // option. This file may not be copied, modified, or distributed
9 // except according to those terms.
10
11 enum A {
12     A1,
13     A2,
14     A3,
15 }
16
17 enum B {
18     B1(String, String),
19     B2(String, String),
20 }
21
22 fn main() {
23     let a = A::A1;
24     loop {
25         let _ctor = match a {
26             A::A3 => break,
27             A::A1 => B::B1,
28             A::A2 => B::B2,
29         };
30         break;
31     }
32 }