]> git.lizzy.rs Git - rust.git/blob - src/test/pretty/vec-comments.pp
Fix warnings it tests
[rust.git] / src / test / pretty / vec-comments.pp
1 // Copyright 2012 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 // Issue #679
12 // Testing that comments are correctly interleaved
13 // pp-exact:vec-comments.pp
14 fn main() {
15     let _v1 =
16         ~[
17           // Comment
18           0,
19           // Comment
20           1,
21           // Comment
22           2];
23     let _v2 =
24         ~[0, // Comment
25           1, // Comment
26           2]; // Comment
27     let _v3 =
28         ~[
29           /* Comment */
30           0,
31           /* Comment */
32           1,
33           /* Comment */
34           2];
35     let _v4 =
36         ~[0, /* Comment */
37           1, /* Comment */
38           2]; /* Comment */
39 }