diff options
| author | Niko Matsakis <niko@alum.mit.edu> | 2014-08-27 21:46:52 -0400 |
|---|---|---|
| committer | Niko Matsakis <niko@alum.mit.edu> | 2014-08-27 21:46:52 -0400 |
| commit | 1b487a890695e7d6dfbfe5dcd7d4fa0e8ca8003f (patch) | |
| tree | 552fabade603ab0d148a49ae3cf1abd3f399740a /src/librbml | |
| parent | 3ee047ae1ffab454270bc1859b3beef3556ef8f9 (diff) | |
| download | rust-1b487a890695e7d6dfbfe5dcd7d4fa0e8ca8003f.tar.gz rust-1b487a890695e7d6dfbfe5dcd7d4fa0e8ca8003f.zip | |
Implement generalized object and type parameter bounds (Fixes #16462)
Diffstat (limited to 'src/librbml')
| -rw-r--r-- | src/librbml/lib.rs | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/src/librbml/lib.rs b/src/librbml/lib.rs index 4927a8293a4..a05c877a6a6 100644 --- a/src/librbml/lib.rs +++ b/src/librbml/lib.rs @@ -24,7 +24,7 @@ html_favicon_url = "http://www.rust-lang.org/favicon.ico", html_root_url = "http://doc.rust-lang.org/master/", html_playground_url = "http://play.rust-lang.org/")] -#![feature(macro_rules, phase)] +#![feature(macro_rules, phase, issue_5723_bootstrap)] #![allow(missing_doc)] extern crate serialize; @@ -662,11 +662,19 @@ pub mod writer { pub type EncodeResult = io::IoResult<()>; // rbml writing + #[cfg(stage0)] pub struct Encoder<'a, W> { pub writer: &'a mut W, size_positions: Vec<uint>, } + // rbml writing + #[cfg(not(stage0))] + pub struct Encoder<'a, W:'a> { + pub writer: &'a mut W, + size_positions: Vec<uint>, + } + fn write_sized_vuint<W: Writer>(w: &mut W, n: uint, size: uint) -> EncodeResult { match size { 1u => w.write(&[0x80u8 | (n as u8)]), |
