File tree Expand file tree Collapse file tree 3 files changed +6
-4
lines changed Expand file tree Collapse file tree 3 files changed +6
-4
lines changed Original file line number Diff line number Diff line change @@ -9,6 +9,7 @@ use std::io;
9
9
use std:: iter:: repeat;
10
10
use std:: os;
11
11
use std:: slice:: bytes;
12
+ use std:: c_str:: ToCStr ;
12
13
13
14
use { BestCompression , CompressionLevel , BestSpeed } ;
14
15
use crc:: { CrcReader , Crc } ;
@@ -385,7 +386,7 @@ impl<R: Reader> DecoderReader<R> {
385
386
pub fn header ( & self ) -> & Header { & self . header }
386
387
387
388
fn finish ( & mut self ) -> IoResult < ( ) > {
388
- let ref mut buf = [ 0u8 , .. 8 ] ;
389
+ let ref mut buf = [ 0u8 ; 8 ] ;
389
390
{
390
391
let flate = self . inner . inner ( ) ;
391
392
let len = {
Original file line number Diff line number Diff line change @@ -65,7 +65,7 @@ pub mod writer {
65
65
66
66
/// When compressing data, the compression level can be specified by a value in
67
67
/// this enum.
68
- #[ deriving ( Copy ) ]
68
+ #[ derive ( Copy ) ]
69
69
pub enum CompressionLevel {
70
70
/// No compression is to be performed, this may actually inflate data
71
71
/// slightly when encoding.
Original file line number Diff line number Diff line change @@ -4,6 +4,7 @@ use std::io;
4
4
use std:: mem;
5
5
use std:: io:: IoResult ;
6
6
use libc;
7
+ use std:: ops:: { Deref , DerefMut } ;
7
8
8
9
use { CompressionLevel , NoCompression } ;
9
10
use ffi;
@@ -272,13 +273,13 @@ impl Stream {
272
273
}
273
274
}
274
275
275
- impl Deref < ffi :: mz_stream > for Stream {
276
+ impl Deref for Stream {
276
277
fn deref < ' a > ( & ' a self ) -> & ' a ffi:: mz_stream {
277
278
let Stream ( ref inner, _) = * self ; inner
278
279
}
279
280
}
280
281
281
- impl DerefMut < ffi :: mz_stream > for Stream {
282
+ impl DerefMut for Stream {
282
283
fn deref_mut < ' a > ( & ' a mut self ) -> & ' a mut ffi:: mz_stream {
283
284
let Stream ( ref mut inner, _) = * self ; inner
284
285
}
You can’t perform that action at this time.
0 commit comments