diff options
| author | bors <bors@rust-lang.org> | 2014-06-11 06:02:10 -0700 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2014-06-11 06:02:10 -0700 |
| commit | ea41101b3522f2a7d121758be489404cbb0fde5a (patch) | |
| tree | 67a5e69caf2fe658536aee64bda7890e2c88ae00 | |
| parent | db9e0a1142ee1f57d27201f9bfb33d28e44f6355 (diff) | |
| parent | 9bead9b3f1da57d67b3297b073878c5caa150406 (diff) | |
| download | rust-ea41101b3522f2a7d121758be489404cbb0fde5a.tar.gz rust-ea41101b3522f2a7d121758be489404cbb0fde5a.zip | |
auto merge of #14788 : Sawyer47/rust/issue-13214, r=huonw
Closes #13214
| -rw-r--r-- | src/test/run-pass/issue-13214.rs | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/src/test/run-pass/issue-13214.rs b/src/test/run-pass/issue-13214.rs new file mode 100644 index 00000000000..8afaec16e45 --- /dev/null +++ b/src/test/run-pass/issue-13214.rs @@ -0,0 +1,29 @@ +// Copyright 2014 The Rust Project Developers. See the COPYRIGHT +// file at the top-level directory of this distribution and at +// http://rust-lang.org/COPYRIGHT. +// +// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or +// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license +// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your +// option. This file may not be copied, modified, or distributed +// except according to those terms. + +// defining static with struct that contains enum +// with &'static str variant used to cause ICE + +pub enum Foo { + Bar, + Baz(&'static str), +} + +pub static TEST: Test = Test { + foo: Bar, + c: 'a' +}; + +pub struct Test { + foo: Foo, + c: char, +} + +fn main() {} |
