Bug 1421275 - Update Cargo lockfiles and re-vendor rust dependencies. r?jrmuizel draft
authorKartikaya Gupta <kgupta@mozilla.com>
Fri, 01 Dec 2017 09:50:52 -0500
changeset 706234 81058551b9c4a69abfdfac539140224e2e1c3584
parent 706233 f54057eeed9e68f3c8171e27041329c2be2b9317
child 706235 cee0d01763c619a636e507405f98d38bd6b1e09e
push id91747
push userkgupta@mozilla.com
push dateFri, 01 Dec 2017 14:53:26 +0000
reviewersjrmuizel
bugs1421275
milestone59.0a1
Bug 1421275 - Update Cargo lockfiles and re-vendor rust dependencies. r?jrmuizel MozReview-Commit-ID: Jaty3RGfffU
third_party/rust/byteorder-1.0.0/.cargo-checksum.json
third_party/rust/byteorder-1.0.0/.travis.yml
third_party/rust/byteorder-1.0.0/COPYING
third_party/rust/byteorder-1.0.0/Cargo.toml
third_party/rust/byteorder-1.0.0/LICENSE-MIT
third_party/rust/byteorder-1.0.0/README.md
third_party/rust/byteorder-1.0.0/UNLICENSE
third_party/rust/byteorder-1.0.0/benches/bench.rs
third_party/rust/byteorder-1.0.0/src/lib.rs
third_party/rust/byteorder-1.0.0/src/new.rs
third_party/rust/byteorder-1.1.0/.cargo-checksum.json
third_party/rust/byteorder-1.1.0/.travis.yml
third_party/rust/byteorder-1.1.0/CHANGELOG.md
third_party/rust/byteorder-1.1.0/COPYING
third_party/rust/byteorder-1.1.0/Cargo.toml
third_party/rust/byteorder-1.1.0/LICENSE-MIT
third_party/rust/byteorder-1.1.0/README.md
third_party/rust/byteorder-1.1.0/UNLICENSE
third_party/rust/byteorder-1.1.0/benches/bench.rs
third_party/rust/byteorder-1.1.0/src/io.rs
third_party/rust/byteorder-1.1.0/src/lib.rs
third_party/rust/byteorder/.cargo-checksum.json
third_party/rust/byteorder/CHANGELOG.md
third_party/rust/byteorder/Cargo.toml
third_party/rust/byteorder/README.md
third_party/rust/byteorder/src/io.rs
third_party/rust/byteorder/src/lib.rs
third_party/rust/dwrote/.cargo-checksum.json
third_party/rust/dwrote/Cargo.toml
third_party/rust/dwrote/src/font_face.rs
third_party/rust/dwrote/src/lib.rs
third_party/rust/gleam/.cargo-checksum.json
third_party/rust/gleam/Cargo.toml
third_party/rust/gleam/build.rs
third_party/rust/gleam/src/gl_fns.rs
third_party/rust/gleam/src/gles_fns.rs
toolkit/library/gtest/rust/Cargo.lock
toolkit/library/rust/Cargo.lock
deleted file mode 100644
--- a/third_party/rust/byteorder-1.0.0/.cargo-checksum.json
+++ /dev/null
@@ -1,1 +0,0 @@
-{"files":{".travis.yml":"c8243fb884ca390f5a7b8cc45e1c0d5bbbdd7e4e82ada2dc1880b3a904c9ce12","COPYING":"01c266bced4a434da0051174d6bee16a4c82cf634e2679b6155d40d75012390f","Cargo.toml":"b6cd79e1f2a93cd8a5c6e6dd7985c46fc26e442ae5b8ed4a0ff37a4ad4708023","LICENSE-MIT":"0f96a83840e146e43c0ec96a22ec1f392e0680e6c1226e6f3ba87e0740af850f","README.md":"0559514b9d7488e96fb7a2f3c043a62fadf3495a1e10602d109ce79ee67da998","UNLICENSE":"7e12e5df4bae12cb21581ba157ced20e1986a0508dd10d0e8a4ab9a4cf94e85c","benches/bench.rs":"f583692d829c8dfe19b1d5b9e968ccf5c74d6733367ca183edff74041a6afedd","src/lib.rs":"b038b8a84b2b7b2143b2835185b3cbbacaf056fa8a2f03bec84bfd79c913c726","src/new.rs":"161c21b7ebb5668c7cc70b46b0eb37709e06bb9c854f2fdfc6ce3d3babcbf3de"},"package":"c40977b0ee6b9885c9013cd41d9feffdd22deb3bb4dc3a71d901cc7a77de18c8"}
\ No newline at end of file
deleted file mode 100644
--- a/third_party/rust/byteorder-1.0.0/.travis.yml
+++ /dev/null
@@ -1,15 +0,0 @@
-language: rust
-rust:
-  - 1.12.0
-  - stable
-  - beta
-  - nightly
-script:
-  - cargo build --verbose
-  - cargo doc
-  - cargo test --verbose
-  - cargo test --verbose --no-default-features --lib
-  - if [ "$TRAVIS_RUST_VERSION" = "nightly" ]; then
-      cargo bench --verbose;
-      cargo bench --verbose --no-default-features;
-    fi
deleted file mode 100644
--- a/third_party/rust/byteorder-1.0.0/Cargo.toml
+++ /dev/null
@@ -1,26 +0,0 @@
-[package]
-name = "byteorder"
-version = "1.0.0"  #:version
-authors = ["Andrew Gallant <jamslam@gmail.com>"]
-description = "Library for reading/writing numbers in big-endian and little-endian."
-documentation = "https://docs.rs/byteorder"
-homepage = "https://github.com/BurntSushi/byteorder"
-repository = "https://github.com/BurntSushi/byteorder"
-readme = "README.md"
-keywords = ["byte", "endian", "big-endian", "little-endian", "binary"]
-license = "Unlicense/MIT"
-
-[lib]
-name = "byteorder"
-bench = false
-
-[dev-dependencies]
-quickcheck = "0.4"
-rand = "0.3"
-
-[features]
-default = ["std"]
-std = []
-
-[profile.bench]
-opt-level = 3
deleted file mode 100644
--- a/third_party/rust/byteorder-1.0.0/benches/bench.rs
+++ /dev/null
@@ -1,148 +0,0 @@
-#![feature(test)]
-
-extern crate byteorder;
-extern crate test;
-
-macro_rules! bench_num {
-    ($name:ident, $read:ident, $bytes:expr, $data:expr) => (
-        mod $name {
-            use byteorder::{ByteOrder, BigEndian, NativeEndian, LittleEndian};
-            use super::test::Bencher;
-            use super::test::black_box as bb;
-
-            const NITER: usize = 100_000;
-
-            #[bench]
-            fn read_big_endian(b: &mut Bencher) {
-                let buf = $data;
-                b.iter(|| {
-                    for _ in 0..NITER {
-                        bb(BigEndian::$read(&buf, $bytes));
-                    }
-                });
-            }
-
-            #[bench]
-            fn read_little_endian(b: &mut Bencher) {
-                let buf = $data;
-                b.iter(|| {
-                    for _ in 0..NITER {
-                        bb(LittleEndian::$read(&buf, $bytes));
-                    }
-                });
-            }
-
-            #[bench]
-            fn read_native_endian(b: &mut Bencher) {
-                let buf = $data;
-                b.iter(|| {
-                    for _ in 0..NITER {
-                        bb(NativeEndian::$read(&buf, $bytes));
-                    }
-                });
-            }
-        }
-    );
-    ($ty:ident, $max:ident,
-     $read:ident, $write:ident, $size:expr, $data:expr) => (
-        mod $ty {
-            use std::$ty;
-            use byteorder::{ByteOrder, BigEndian, NativeEndian, LittleEndian};
-            use super::test::Bencher;
-            use super::test::black_box as bb;
-
-            const NITER: usize = 100_000;
-
-            #[bench]
-            fn read_big_endian(b: &mut Bencher) {
-                let buf = $data;
-                b.iter(|| {
-                    for _ in 0..NITER {
-                        bb(BigEndian::$read(&buf));
-                    }
-                });
-            }
-
-            #[bench]
-            fn read_little_endian(b: &mut Bencher) {
-                let buf = $data;
-                b.iter(|| {
-                    for _ in 0..NITER {
-                        bb(LittleEndian::$read(&buf));
-                    }
-                });
-            }
-
-            #[bench]
-            fn read_native_endian(b: &mut Bencher) {
-                let buf = $data;
-                b.iter(|| {
-                    for _ in 0..NITER {
-                        bb(NativeEndian::$read(&buf));
-                    }
-                });
-            }
-
-            #[bench]
-            fn write_big_endian(b: &mut Bencher) {
-                let mut buf = $data;
-                let n = $ty::$max;
-                b.iter(|| {
-                    for _ in 0..NITER {
-                        bb(BigEndian::$write(&mut buf, n));
-                    }
-                });
-            }
-
-            #[bench]
-            fn write_little_endian(b: &mut Bencher) {
-                let mut buf = $data;
-                let n = $ty::$max;
-                b.iter(|| {
-                    for _ in 0..NITER {
-                        bb(LittleEndian::$write(&mut buf, n));
-                    }
-                });
-            }
-
-            #[bench]
-            fn write_native_endian(b: &mut Bencher) {
-                let mut buf = $data;
-                let n = $ty::$max;
-                b.iter(|| {
-                    for _ in 0..NITER {
-                        bb(NativeEndian::$write(&mut buf, n));
-                    }
-                });
-            }
-        }
-    );
-}
-
-bench_num!(u16, MAX, read_u16, write_u16, 2, [1, 2]);
-bench_num!(i16, MAX, read_i16, write_i16, 2, [1, 2]);
-bench_num!(u32, MAX, read_u32, write_u32, 4, [1, 2, 3, 4]);
-bench_num!(i32, MAX, read_i32, write_i32, 4, [1, 2, 3, 4]);
-bench_num!(u64, MAX, read_u64, write_u64, 8, [1, 2, 3, 4, 5, 6, 7, 8]);
-bench_num!(i64, MAX, read_i64, write_i64, 8, [1, 2, 3, 4, 5, 6, 7, 8]);
-bench_num!(f32, MAX, read_f32, write_f32, 4, [1, 2, 3, 4]);
-bench_num!(f64, MAX, read_f64, write_f64, 8,
-           [1, 2, 3, 4, 5, 6, 7, 8]);
-
-bench_num!(uint_1, read_uint, 1, [1]);
-bench_num!(uint_2, read_uint, 2, [1, 2]);
-bench_num!(uint_3, read_uint, 3, [1, 2, 3]);
-bench_num!(uint_4, read_uint, 4, [1, 2, 3, 4]);
-bench_num!(uint_5, read_uint, 5, [1, 2, 3, 4, 5]);
-bench_num!(uint_6, read_uint, 6, [1, 2, 3, 4, 5, 6]);
-bench_num!(uint_7, read_uint, 7, [1, 2, 3, 4, 5, 6, 7]);
-bench_num!(uint_8, read_uint, 8, [1, 2, 3, 4, 5, 6, 7, 8]);
-
-bench_num!(int_1, read_int, 1, [1]);
-bench_num!(int_2, read_int, 2, [1, 2]);
-bench_num!(int_3, read_int, 3, [1, 2, 3]);
-bench_num!(int_4, read_int, 4, [1, 2, 3, 4]);
-bench_num!(int_5, read_int, 5, [1, 2, 3, 4, 5]);
-bench_num!(int_6, read_int, 6, [1, 2, 3, 4, 5, 6]);
-bench_num!(int_7, read_int, 7, [1, 2, 3, 4, 5, 6, 7]);
-bench_num!(int_8, read_int, 8, [1, 2, 3, 4, 5, 6, 7, 8]);
deleted file mode 100644
--- a/third_party/rust/byteorder-1.0.0/src/lib.rs
+++ /dev/null
@@ -1,820 +0,0 @@
-/*!
-This crate provides convenience methods for encoding and decoding numbers
-in either big-endian or little-endian order.
-
-The organization of the crate is pretty simple. A trait, `ByteOrder`, specifies
-byte conversion methods for each type of number in Rust (sans numbers that have
-a platform dependent size like `usize` and `isize`). Two types, `BigEndian`
-and `LittleEndian` implement these methods. Finally, `ReadBytesExt` and
-`WriteBytesExt` provide convenience methods available to all types that
-implement `Read` and `Write`.
-
-# Examples
-
-Read unsigned 16 bit big-endian integers from a `Read` type:
-
-```rust
-use std::io::Cursor;
-use byteorder::{BigEndian, ReadBytesExt};
-
-let mut rdr = Cursor::new(vec![2, 5, 3, 0]);
-// Note that we use type parameters to indicate which kind of byte order
-// we want!
-assert_eq!(517, rdr.read_u16::<BigEndian>().unwrap());
-assert_eq!(768, rdr.read_u16::<BigEndian>().unwrap());
-```
-
-Write unsigned 16 bit little-endian integers to a `Write` type:
-
-```rust
-use byteorder::{LittleEndian, WriteBytesExt};
-
-let mut wtr = vec![];
-wtr.write_u16::<LittleEndian>(517).unwrap();
-wtr.write_u16::<LittleEndian>(768).unwrap();
-assert_eq!(wtr, vec![5, 2, 0, 3]);
-```
-*/
-
-#![deny(missing_docs)]
-#![cfg_attr(not(feature = "std"), no_std)]
-
-#[cfg(feature = "std")]
-extern crate core;
-
-use core::fmt::Debug;
-use core::hash::Hash;
-use core::mem::transmute;
-use core::ptr::copy_nonoverlapping;
-
-#[cfg(feature = "std")]
-pub use new::{ReadBytesExt, WriteBytesExt};
-
-#[cfg(feature = "std")]
-mod new;
-
-#[inline]
-fn extend_sign(val: u64, nbytes: usize) -> i64 {
-    let shift = (8 - nbytes) * 8;
-    (val << shift) as i64 >> shift
-}
-
-#[inline]
-fn unextend_sign(val: i64, nbytes: usize) -> u64 {
-    let shift = (8 - nbytes) * 8;
-    (val << shift) as u64 >> shift
-}
-
-#[inline]
-fn pack_size(n: u64) -> usize {
-    if n < 1 << 8 {
-        1
-    } else if n < 1 << 16 {
-        2
-    } else if n < 1 << 24 {
-        3
-    } else if n < 1 << 32 {
-        4
-    } else if n < 1 << 40 {
-        5
-    } else if n < 1 << 48 {
-        6
-    } else if n < 1 << 56 {
-        7
-    } else {
-        8
-    }
-}
-
-/// ByteOrder describes types that can serialize integers as bytes.
-///
-/// Note that `Self` does not appear anywhere in this trait's definition!
-/// Therefore, in order to use it, you'll need to use syntax like
-/// `T::read_u16(&[0, 1])` where `T` implements `ByteOrder`.
-///
-/// This crate provides two types that implement `ByteOrder`: `BigEndian`
-/// and `LittleEndian`.
-///
-/// # Examples
-///
-/// Write and read `u32` numbers in little endian order:
-///
-/// ```rust
-/// use byteorder::{ByteOrder, LittleEndian};
-///
-/// let mut buf = [0; 4];
-/// LittleEndian::write_u32(&mut buf, 1_000_000);
-/// assert_eq!(1_000_000, LittleEndian::read_u32(&buf));
-/// ```
-///
-/// Write and read `i16` numbers in big endian order:
-///
-/// ```rust
-/// use byteorder::{ByteOrder, BigEndian};
-///
-/// let mut buf = [0; 2];
-/// BigEndian::write_i16(&mut buf, -50_000);
-/// assert_eq!(-50_000, BigEndian::read_i16(&buf));
-/// ```
-pub trait ByteOrder
-    : Clone + Copy + Debug + Default + Eq + Hash + Ord + PartialEq + PartialOrd {
-    /// Reads an unsigned 16 bit integer from `buf`.
-    ///
-    /// Panics when `buf.len() < 2`.
-    fn read_u16(buf: &[u8]) -> u16;
-
-    /// Reads an unsigned 32 bit integer from `buf`.
-    ///
-    /// Panics when `buf.len() < 4`.
-    fn read_u32(buf: &[u8]) -> u32;
-
-    /// Reads an unsigned 64 bit integer from `buf`.
-    ///
-    /// Panics when `buf.len() < 8`.
-    fn read_u64(buf: &[u8]) -> u64;
-
-    /// Reads an unsigned n-bytes integer from `buf`.
-    ///
-    /// Panics when `nbytes < 1` or `nbytes > 8` or
-    /// `buf.len() < nbytes`
-    fn read_uint(buf: &[u8], nbytes: usize) -> u64;
-
-    /// Writes an unsigned 16 bit integer `n` to `buf`.
-    ///
-    /// Panics when `buf.len() < 2`.
-    fn write_u16(buf: &mut [u8], n: u16);
-
-    /// Writes an unsigned 32 bit integer `n` to `buf`.
-    ///
-    /// Panics when `buf.len() < 4`.
-    fn write_u32(buf: &mut [u8], n: u32);
-
-    /// Writes an unsigned 64 bit integer `n` to `buf`.
-    ///
-    /// Panics when `buf.len() < 8`.
-    fn write_u64(buf: &mut [u8], n: u64);
-
-    /// Writes an unsigned integer `n` to `buf` using only `nbytes`.
-    ///
-    /// If `n` is not representable in `nbytes`, or if `nbytes` is `> 8`, then
-    /// this method panics.
-    fn write_uint(buf: &mut [u8], n: u64, nbytes: usize);
-
-    /// Reads a signed 16 bit integer from `buf`.
-    ///
-    /// Panics when `buf.len() < 2`.
-    #[inline]
-    fn read_i16(buf: &[u8]) -> i16 {
-        Self::read_u16(buf) as i16
-    }
-
-    /// Reads a signed 32 bit integer from `buf`.
-    ///
-    /// Panics when `buf.len() < 4`.
-    #[inline]
-    fn read_i32(buf: &[u8]) -> i32 {
-        Self::read_u32(buf) as i32
-    }
-
-    /// Reads a signed 64 bit integer from `buf`.
-    ///
-    /// Panics when `buf.len() < 8`.
-    #[inline]
-    fn read_i64(buf: &[u8]) -> i64 {
-        Self::read_u64(buf) as i64
-    }
-
-    /// Reads a signed n-bytes integer from `buf`.
-    ///
-    /// Panics when `nbytes < 1` or `nbytes > 8` or
-    /// `buf.len() < nbytes`
-    #[inline]
-    fn read_int(buf: &[u8], nbytes: usize) -> i64 {
-        extend_sign(Self::read_uint(buf, nbytes), nbytes)
-    }
-
-    /// Reads a IEEE754 single-precision (4 bytes) floating point number.
-    ///
-    /// Panics when `buf.len() < 4`.
-    #[inline]
-    fn read_f32(buf: &[u8]) -> f32 {
-        unsafe { transmute(Self::read_u32(buf)) }
-    }
-
-    /// Reads a IEEE754 double-precision (8 bytes) floating point number.
-    ///
-    /// Panics when `buf.len() < 8`.
-    #[inline]
-    fn read_f64(buf: &[u8]) -> f64 {
-        unsafe { transmute(Self::read_u64(buf)) }
-    }
-
-    /// Writes a signed 16 bit integer `n` to `buf`.
-    ///
-    /// Panics when `buf.len() < 2`.
-    #[inline]
-    fn write_i16(buf: &mut [u8], n: i16) {
-        Self::write_u16(buf, n as u16)
-    }
-
-    /// Writes a signed 32 bit integer `n` to `buf`.
-    ///
-    /// Panics when `buf.len() < 4`.
-    #[inline]
-    fn write_i32(buf: &mut [u8], n: i32) {
-        Self::write_u32(buf, n as u32)
-    }
-
-    /// Writes a signed 64 bit integer `n` to `buf`.
-    ///
-    /// Panics when `buf.len() < 8`.
-    #[inline]
-    fn write_i64(buf: &mut [u8], n: i64) {
-        Self::write_u64(buf, n as u64)
-    }
-
-    /// Writes a signed integer `n` to `buf` using only `nbytes`.
-    ///
-    /// If `n` is not representable in `nbytes`, or if `nbytes` is `> 8`, then
-    /// this method panics.
-    #[inline]
-    fn write_int(buf: &mut [u8], n: i64, nbytes: usize) {
-        Self::write_uint(buf, unextend_sign(n, nbytes), nbytes)
-    }
-
-    /// Writes a IEEE754 single-precision (4 bytes) floating point number.
-    ///
-    /// Panics when `buf.len() < 4`.
-    #[inline]
-    fn write_f32(buf: &mut [u8], n: f32) {
-        Self::write_u32(buf, unsafe { transmute(n) })
-    }
-
-    /// Writes a IEEE754 double-precision (8 bytes) floating point number.
-    ///
-    /// Panics when `buf.len() < 8`.
-    #[inline]
-    fn write_f64(buf: &mut [u8], n: f64) {
-        Self::write_u64(buf, unsafe { transmute(n) })
-    }
-}
-
-/// Defines big-endian serialization.
-///
-/// Note that this type has no value constructor. It is used purely at the
-/// type level.
-#[derive(Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd)]
-pub enum BigEndian {}
-
-impl Default for BigEndian {
-    fn default() -> BigEndian {
-        unreachable!()
-    }
-}
-
-/// Defines little-endian serialization.
-///
-/// Note that this type has no value constructor. It is used purely at the
-/// type level.
-#[derive(Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd)]
-pub enum LittleEndian {}
-
-impl Default for LittleEndian {
-    fn default() -> LittleEndian {
-        unreachable!()
-    }
-}
-
-/// Defines network byte order serialization.
-///
-/// Network byte order is defined by [RFC 1700][1] to be big-endian, and is
-/// referred to in several protocol specifications.  This type is an alias of
-/// BigEndian.
-///
-/// [1]: https://tools.ietf.org/html/rfc1700
-///
-/// Note that this type has no value constructor. It is used purely at the
-/// type level.
-pub type NetworkEndian = BigEndian;
-
-/// Defines system native-endian serialization.
-///
-/// Note that this type has no value constructor. It is used purely at the
-/// type level.
-#[cfg(target_endian = "little")]
-pub type NativeEndian = LittleEndian;
-
-/// Defines system native-endian serialization.
-///
-/// Note that this type has no value constructor. It is used purely at the
-/// type level.
-#[cfg(target_endian = "big")]
-pub type NativeEndian = BigEndian;
-
-macro_rules! read_num_bytes {
-    ($ty:ty, $size:expr, $src:expr, $which:ident) => ({
-        assert!($size == ::core::mem::size_of::<$ty>());
-        assert!($size <= $src.len());
-        let mut data: $ty = 0;
-        unsafe {
-            copy_nonoverlapping(
-                $src.as_ptr(),
-                &mut data as *mut $ty as *mut u8,
-                $size);
-        }
-        data.$which()
-    });
-}
-
-macro_rules! write_num_bytes {
-    ($ty:ty, $size:expr, $n:expr, $dst:expr, $which:ident) => ({
-        assert!($size <= $dst.len());
-        unsafe {
-            // N.B. https://github.com/rust-lang/rust/issues/22776
-            let bytes = transmute::<_, [u8; $size]>($n.$which());
-            copy_nonoverlapping((&bytes).as_ptr(), $dst.as_mut_ptr(), $size);
-        }
-    });
-}
-
-impl ByteOrder for BigEndian {
-    #[inline]
-    fn read_u16(buf: &[u8]) -> u16 {
-        read_num_bytes!(u16, 2, buf, to_be)
-    }
-
-    #[inline]
-    fn read_u32(buf: &[u8]) -> u32 {
-        read_num_bytes!(u32, 4, buf, to_be)
-    }
-
-    #[inline]
-    fn read_u64(buf: &[u8]) -> u64 {
-        read_num_bytes!(u64, 8, buf, to_be)
-    }
-
-    #[inline]
-    fn read_uint(buf: &[u8], nbytes: usize) -> u64 {
-        assert!(1 <= nbytes && nbytes <= 8 && nbytes <= buf.len());
-        let mut out = [0u8; 8];
-        let ptr_out = out.as_mut_ptr();
-        unsafe {
-            copy_nonoverlapping(
-                buf.as_ptr(), ptr_out.offset((8 - nbytes) as isize), nbytes);
-            (*(ptr_out as *const u64)).to_be()
-        }
-    }
-
-    #[inline]
-    fn write_u16(buf: &mut [u8], n: u16) {
-        write_num_bytes!(u16, 2, n, buf, to_be);
-    }
-
-    #[inline]
-    fn write_u32(buf: &mut [u8], n: u32) {
-        write_num_bytes!(u32, 4, n, buf, to_be);
-    }
-
-    #[inline]
-    fn write_u64(buf: &mut [u8], n: u64) {
-        write_num_bytes!(u64, 8, n, buf, to_be);
-    }
-
-    #[inline]
-    fn write_uint(buf: &mut [u8], n: u64, nbytes: usize) {
-        assert!(pack_size(n) <= nbytes && nbytes <= 8);
-        assert!(nbytes <= buf.len());
-        unsafe {
-            let bytes: [u8; 8] = transmute(n.to_be());
-            copy_nonoverlapping(
-                bytes.as_ptr().offset((8 - nbytes) as isize),
-                buf.as_mut_ptr(),
-                nbytes);
-        }
-    }
-}
-
-impl ByteOrder for LittleEndian {
-    #[inline]
-    fn read_u16(buf: &[u8]) -> u16 {
-        read_num_bytes!(u16, 2, buf, to_le)
-    }
-
-    #[inline]
-    fn read_u32(buf: &[u8]) -> u32 {
-        read_num_bytes!(u32, 4, buf, to_le)
-    }
-
-    #[inline]
-    fn read_u64(buf: &[u8]) -> u64 {
-        read_num_bytes!(u64, 8, buf, to_le)
-    }
-
-    #[inline]
-    fn read_uint(buf: &[u8], nbytes: usize) -> u64 {
-        assert!(1 <= nbytes && nbytes <= 8 && nbytes <= buf.len());
-        let mut out = [0u8; 8];
-        let ptr_out = out.as_mut_ptr();
-        unsafe {
-            copy_nonoverlapping(buf.as_ptr(), ptr_out, nbytes);
-            (*(ptr_out as *const u64)).to_le()
-        }
-    }
-
-    #[inline]
-    fn write_u16(buf: &mut [u8], n: u16) {
-        write_num_bytes!(u16, 2, n, buf, to_le);
-    }
-
-    #[inline]
-    fn write_u32(buf: &mut [u8], n: u32) {
-        write_num_bytes!(u32, 4, n, buf, to_le);
-    }
-
-    #[inline]
-    fn write_u64(buf: &mut [u8], n: u64) {
-        write_num_bytes!(u64, 8, n, buf, to_le);
-    }
-
-    #[inline]
-    fn write_uint(buf: &mut [u8], n: u64, nbytes: usize) {
-        assert!(pack_size(n as u64) <= nbytes && nbytes <= 8);
-        assert!(nbytes <= buf.len());
-        unsafe {
-            let bytes: [u8; 8] = transmute(n.to_le());
-            copy_nonoverlapping(bytes.as_ptr(), buf.as_mut_ptr(), nbytes);
-        }
-    }
-}
-
-#[cfg(test)]
-mod test {
-    extern crate quickcheck;
-    extern crate rand;
-
-    use self::rand::thread_rng;
-    use self::quickcheck::{QuickCheck, StdGen, Testable};
-
-    pub const U64_MAX: u64 = ::core::u64::MAX;
-    pub const I64_MAX: u64 = ::core::i64::MAX as u64;
-
-    pub fn qc_sized<A: Testable>(f: A, size: u64) {
-        QuickCheck::new()
-            .gen(StdGen::new(thread_rng(), size as usize))
-            .tests(1_00)
-            .max_tests(10_000)
-            .quickcheck(f);
-    }
-
-    macro_rules! qc_byte_order {
-        ($name:ident, $ty_int:ident, $max:expr,
-         $bytes:expr, $read:ident, $write:ident) => (
-            mod $name {
-                use {BigEndian, ByteOrder, NativeEndian, LittleEndian};
-                use super::qc_sized;
-
-                #[test]
-                fn big_endian() {
-                    let max = ($max - 1) >> (8 * (8 - $bytes));
-                    fn prop(n: $ty_int) -> bool {
-                        let mut buf = [0; 8];
-                        BigEndian::$write(&mut buf, n, $bytes);
-                        n == BigEndian::$read(&mut buf[..$bytes], $bytes)
-                    }
-                    qc_sized(prop as fn($ty_int) -> bool, max);
-                }
-
-                #[test]
-                fn little_endian() {
-                    let max = ($max - 1) >> (8 * (8 - $bytes));
-                    fn prop(n: $ty_int) -> bool {
-                        let mut buf = [0; 8];
-                        LittleEndian::$write(&mut buf, n, $bytes);
-                        n == LittleEndian::$read(&mut buf[..$bytes], $bytes)
-                    }
-                    qc_sized(prop as fn($ty_int) -> bool, max);
-                }
-
-                #[test]
-                fn native_endian() {
-                    let max = ($max - 1) >> (8 * (8 - $bytes));
-                    fn prop(n: $ty_int) -> bool {
-                        let mut buf = [0; 8];
-                        NativeEndian::$write(&mut buf, n, $bytes);
-                        n == NativeEndian::$read(&mut buf[..$bytes], $bytes)
-                    }
-                    qc_sized(prop as fn($ty_int) -> bool, max);
-                }
-            }
-        );
-        ($name:ident, $ty_int:ident, $max:expr,
-         $read:ident, $write:ident) => (
-            mod $name {
-                use core::mem::size_of;
-                use {BigEndian, ByteOrder, NativeEndian, LittleEndian};
-                use super::qc_sized;
-
-                #[test]
-                fn big_endian() {
-                    fn prop(n: $ty_int) -> bool {
-                        let bytes = size_of::<$ty_int>();
-                        let mut buf = [0; 8];
-                        BigEndian::$write(&mut buf[8 - bytes..], n);
-                        n == BigEndian::$read(&mut buf[8 - bytes..])
-                    }
-                    qc_sized(prop as fn($ty_int) -> bool, $max - 1);
-                }
-
-                #[test]
-                fn little_endian() {
-                    fn prop(n: $ty_int) -> bool {
-                        let bytes = size_of::<$ty_int>();
-                        let mut buf = [0; 8];
-                        LittleEndian::$write(&mut buf[..bytes], n);
-                        n == LittleEndian::$read(&mut buf[..bytes])
-                    }
-                    qc_sized(prop as fn($ty_int) -> bool, $max - 1);
-                }
-
-                #[test]
-                fn native_endian() {
-                    fn prop(n: $ty_int) -> bool {
-                        let bytes = size_of::<$ty_int>();
-                        let mut buf = [0; 8];
-                        NativeEndian::$write(&mut buf[..bytes], n);
-                        n == NativeEndian::$read(&mut buf[..bytes])
-                    }
-                    qc_sized(prop as fn($ty_int) -> bool, $max - 1);
-                }
-            }
-        );
-    }
-
-    qc_byte_order!(prop_u16, u16, ::core::u16::MAX as u64, read_u16, write_u16);
-    qc_byte_order!(prop_i16, i16, ::core::i16::MAX as u64, read_i16, write_i16);
-    qc_byte_order!(prop_u32, u32, ::core::u32::MAX as u64, read_u32, write_u32);
-    qc_byte_order!(prop_i32, i32, ::core::i32::MAX as u64, read_i32, write_i32);
-    qc_byte_order!(prop_u64, u64, ::core::u64::MAX as u64, read_u64, write_u64);
-    qc_byte_order!(prop_i64, i64, ::core::i64::MAX as u64, read_i64, write_i64);
-    qc_byte_order!(prop_f32, f32, ::core::u64::MAX as u64, read_f32, write_f32);
-    qc_byte_order!(prop_f64, f64, ::core::i64::MAX as u64, read_f64, write_f64);
-
-    qc_byte_order!(prop_uint_1, u64, super::U64_MAX, 1, read_uint, write_uint);
-    qc_byte_order!(prop_uint_2, u64, super::U64_MAX, 2, read_uint, write_uint);
-    qc_byte_order!(prop_uint_3, u64, super::U64_MAX, 3, read_uint, write_uint);
-    qc_byte_order!(prop_uint_4, u64, super::U64_MAX, 4, read_uint, write_uint);
-    qc_byte_order!(prop_uint_5, u64, super::U64_MAX, 5, read_uint, write_uint);
-    qc_byte_order!(prop_uint_6, u64, super::U64_MAX, 6, read_uint, write_uint);
-    qc_byte_order!(prop_uint_7, u64, super::U64_MAX, 7, read_uint, write_uint);
-    qc_byte_order!(prop_uint_8, u64, super::U64_MAX, 8, read_uint, write_uint);
-
-    qc_byte_order!(prop_int_1, i64, super::I64_MAX, 1, read_int, write_int);
-    qc_byte_order!(prop_int_2, i64, super::I64_MAX, 2, read_int, write_int);
-    qc_byte_order!(prop_int_3, i64, super::I64_MAX, 3, read_int, write_int);
-    qc_byte_order!(prop_int_4, i64, super::I64_MAX, 4, read_int, write_int);
-    qc_byte_order!(prop_int_5, i64, super::I64_MAX, 5, read_int, write_int);
-    qc_byte_order!(prop_int_6, i64, super::I64_MAX, 6, read_int, write_int);
-    qc_byte_order!(prop_int_7, i64, super::I64_MAX, 7, read_int, write_int);
-    qc_byte_order!(prop_int_8, i64, super::I64_MAX, 8, read_int, write_int);
-
-    // Test that all of the byte conversion functions panic when given a
-    // buffer that is too small.
-    //
-    // These tests are critical to ensure safety, otherwise we might end up
-    // with a buffer overflow.
-    macro_rules! too_small {
-        ($name:ident, $maximally_small:expr, $zero:expr,
-         $read:ident, $write:ident) => (
-            mod $name {
-                use {BigEndian, ByteOrder, NativeEndian, LittleEndian};
-
-                #[test]
-                #[should_panic]
-                fn read_big_endian() {
-                    let buf = [0; $maximally_small];
-                    BigEndian::$read(&buf);
-                }
-
-                #[test]
-                #[should_panic]
-                fn read_little_endian() {
-                    let buf = [0; $maximally_small];
-                    LittleEndian::$read(&buf);
-                }
-
-                #[test]
-                #[should_panic]
-                fn read_native_endian() {
-                    let buf = [0; $maximally_small];
-                    NativeEndian::$read(&buf);
-                }
-
-                #[test]
-                #[should_panic]
-                fn write_big_endian() {
-                    let mut buf = [0; $maximally_small];
-                    BigEndian::$write(&mut buf, $zero);
-                }
-
-                #[test]
-                #[should_panic]
-                fn write_little_endian() {
-                    let mut buf = [0; $maximally_small];
-                    LittleEndian::$write(&mut buf, $zero);
-                }
-
-                #[test]
-                #[should_panic]
-                fn write_native_endian() {
-                    let mut buf = [0; $maximally_small];
-                    NativeEndian::$write(&mut buf, $zero);
-                }
-            }
-        );
-        ($name:ident, $maximally_small:expr, $read:ident) => (
-            mod $name {
-                use {BigEndian, ByteOrder, NativeEndian, LittleEndian};
-
-                #[test]
-                #[should_panic]
-                fn read_big_endian() {
-                    let buf = [0; $maximally_small];
-                    BigEndian::$read(&buf, $maximally_small + 1);
-                }
-
-                #[test]
-                #[should_panic]
-                fn read_little_endian() {
-                    let buf = [0; $maximally_small];
-                    LittleEndian::$read(&buf, $maximally_small + 1);
-                }
-
-                #[test]
-                #[should_panic]
-                fn read_native_endian() {
-                    let buf = [0; $maximally_small];
-                    NativeEndian::$read(&buf, $maximally_small + 1);
-                }
-            }
-        );
-    }
-
-    too_small!(small_u16, 1, 0, read_u16, write_u16);
-    too_small!(small_i16, 1, 0, read_i16, write_i16);
-    too_small!(small_u32, 3, 0, read_u32, write_u32);
-    too_small!(small_i32, 3, 0, read_i32, write_i32);
-    too_small!(small_u64, 7, 0, read_u64, write_u64);
-    too_small!(small_i64, 7, 0, read_i64, write_i64);
-    too_small!(small_f32, 3, 0.0, read_f32, write_f32);
-    too_small!(small_f64, 7, 0.0, read_f64, write_f64);
-
-    too_small!(small_uint_1, 1, read_uint);
-    too_small!(small_uint_2, 2, read_uint);
-    too_small!(small_uint_3, 3, read_uint);
-    too_small!(small_uint_4, 4, read_uint);
-    too_small!(small_uint_5, 5, read_uint);
-    too_small!(small_uint_6, 6, read_uint);
-    too_small!(small_uint_7, 7, read_uint);
-
-    too_small!(small_int_1, 1, read_int);
-    too_small!(small_int_2, 2, read_int);
-    too_small!(small_int_3, 3, read_int);
-    too_small!(small_int_4, 4, read_int);
-    too_small!(small_int_5, 5, read_int);
-    too_small!(small_int_6, 6, read_int);
-    too_small!(small_int_7, 7, read_int);
-
-    #[test]
-    fn uint_bigger_buffer() {
-        use {ByteOrder, LittleEndian};
-        let n = LittleEndian::read_uint(&[1, 2, 3, 4, 5, 6, 7, 8], 5);
-        assert_eq!(n, 0x0504030201);
-    }
-}
-
-#[cfg(test)]
-#[cfg(feature = "std")]
-mod stdtests {
-    macro_rules! qc_bytes_ext {
-        ($name:ident, $ty_int:ident, $max:expr,
-         $bytes:expr, $read:ident, $write:ident) => (
-            mod $name {
-                use std::io::Cursor;
-                use {
-                    ReadBytesExt, WriteBytesExt,
-                    BigEndian, NativeEndian, LittleEndian,
-                };
-                use test::qc_sized;
-
-                #[test]
-                fn big_endian() {
-                    let max = ($max - 1) >> (8 * (8 - $bytes));
-                    fn prop(n: $ty_int) -> bool {
-                        let mut wtr = vec![];
-                        wtr.$write::<BigEndian>(n).unwrap();
-                        let mut rdr = Vec::new();
-                        rdr.extend(wtr[8 - $bytes..].iter().map(|&x|x));
-                        let mut rdr = Cursor::new(rdr);
-                        n == rdr.$read::<BigEndian>($bytes).unwrap()
-                    }
-                    qc_sized(prop as fn($ty_int) -> bool, max);
-                }
-
-                #[test]
-                fn little_endian() {
-                    let max = ($max - 1) >> (8 * (8 - $bytes));
-                    fn prop(n: $ty_int) -> bool {
-                        let mut wtr = vec![];
-                        wtr.$write::<LittleEndian>(n).unwrap();
-                        let mut rdr = Cursor::new(wtr);
-                        n == rdr.$read::<LittleEndian>($bytes).unwrap()
-                    }
-                    qc_sized(prop as fn($ty_int) -> bool, max);
-                }
-
-                #[test]
-                fn native_endian() {
-                    let max = ($max - 1) >> (8 * (8 - $bytes));
-                    fn prop(n: $ty_int) -> bool {
-                        let mut wtr = vec![];
-                        wtr.$write::<NativeEndian>(n).unwrap();
-                        let mut rdr = Cursor::new(wtr);
-                        n == rdr.$read::<NativeEndian>($bytes).unwrap()
-                    }
-                    qc_sized(prop as fn($ty_int) -> bool, max);
-                }
-            }
-        );
-        ($name:ident, $ty_int:ident, $max:expr, $read:ident, $write:ident) => (
-            mod $name {
-                use std::io::Cursor;
-                use {
-                    ReadBytesExt, WriteBytesExt,
-                    BigEndian, NativeEndian, LittleEndian,
-                };
-                use test::qc_sized;
-
-                #[test]
-                fn big_endian() {
-                    fn prop(n: $ty_int) -> bool {
-                        let mut wtr = vec![];
-                        wtr.$write::<BigEndian>(n).unwrap();
-                        let mut rdr = Cursor::new(wtr);
-                        n == rdr.$read::<BigEndian>().unwrap()
-                    }
-                    qc_sized(prop as fn($ty_int) -> bool, $max - 1);
-                }
-
-                #[test]
-                fn little_endian() {
-                    fn prop(n: $ty_int) -> bool {
-                        let mut wtr = vec![];
-                        wtr.$write::<LittleEndian>(n).unwrap();
-                        let mut rdr = Cursor::new(wtr);
-                        n == rdr.$read::<LittleEndian>().unwrap()
-                    }
-                    qc_sized(prop as fn($ty_int) -> bool, $max - 1);
-                }
-
-                #[test]
-                fn native_endian() {
-                    fn prop(n: $ty_int) -> bool {
-                        let mut wtr = vec![];
-                        wtr.$write::<NativeEndian>(n).unwrap();
-                        let mut rdr = Cursor::new(wtr);
-                        n == rdr.$read::<NativeEndian>().unwrap()
-                    }
-                    qc_sized(prop as fn($ty_int) -> bool, $max - 1);
-                }
-            }
-        );
-    }
-
-    qc_bytes_ext!(prop_ext_u16, u16, ::std::u16::MAX as u64, read_u16, write_u16);
-    qc_bytes_ext!(prop_ext_i16, i16, ::std::i16::MAX as u64, read_i16, write_i16);
-    qc_bytes_ext!(prop_ext_u32, u32, ::std::u32::MAX as u64, read_u32, write_u32);
-    qc_bytes_ext!(prop_ext_i32, i32, ::std::i32::MAX as u64, read_i32, write_i32);
-    qc_bytes_ext!(prop_ext_u64, u64, ::std::u64::MAX as u64, read_u64, write_u64);
-    qc_bytes_ext!(prop_ext_i64, i64, ::std::i64::MAX as u64, read_i64, write_i64);
-    qc_bytes_ext!(prop_ext_f32, f32, ::std::u64::MAX as u64, read_f32, write_f32);
-    qc_bytes_ext!(prop_ext_f64, f64, ::std::i64::MAX as u64, read_f64, write_f64);
-
-    qc_bytes_ext!(prop_ext_uint_1, u64, ::test::U64_MAX, 1, read_uint, write_u64);
-    qc_bytes_ext!(prop_ext_uint_2, u64, ::test::U64_MAX, 2, read_uint, write_u64);
-    qc_bytes_ext!(prop_ext_uint_3, u64, ::test::U64_MAX, 3, read_uint, write_u64);
-    qc_bytes_ext!(prop_ext_uint_4, u64, ::test::U64_MAX, 4, read_uint, write_u64);
-    qc_bytes_ext!(prop_ext_uint_5, u64, ::test::U64_MAX, 5, read_uint, write_u64);
-    qc_bytes_ext!(prop_ext_uint_6, u64, ::test::U64_MAX, 6, read_uint, write_u64);
-    qc_bytes_ext!(prop_ext_uint_7, u64, ::test::U64_MAX, 7, read_uint, write_u64);
-    qc_bytes_ext!(prop_ext_uint_8, u64, ::test::U64_MAX, 8, read_uint, write_u64);
-
-    qc_bytes_ext!(prop_ext_int_1, i64, ::test::I64_MAX, 1, read_int, write_i64);
-    qc_bytes_ext!(prop_ext_int_2, i64, ::test::I64_MAX, 2, read_int, write_i64);
-    qc_bytes_ext!(prop_ext_int_3, i64, ::test::I64_MAX, 3, read_int, write_i64);
-    qc_bytes_ext!(prop_ext_int_4, i64, ::test::I64_MAX, 4, read_int, write_i64);
-    qc_bytes_ext!(prop_ext_int_5, i64, ::test::I64_MAX, 5, read_int, write_i64);
-    qc_bytes_ext!(prop_ext_int_6, i64, ::test::I64_MAX, 6, read_int, write_i64);
-    qc_bytes_ext!(prop_ext_int_7, i64, ::test::I64_MAX, 7, read_int, write_i64);
-    qc_bytes_ext!(prop_ext_int_8, i64, ::test::I64_MAX, 8, read_int, write_i64);
-}
-
deleted file mode 100644
--- a/third_party/rust/byteorder-1.0.0/src/new.rs
+++ /dev/null
@@ -1,269 +0,0 @@
-use std::io::{self, Result};
-
-use ByteOrder;
-
-/// Extends `Read` with methods for reading numbers. (For `std::io`.)
-///
-/// Most of the methods defined here have an unconstrained type parameter that
-/// must be explicitly instantiated. Typically, it is instantiated with either
-/// the `BigEndian` or `LittleEndian` types defined in this crate.
-///
-/// # Examples
-///
-/// Read unsigned 16 bit big-endian integers from a `Read`:
-///
-/// ```rust
-/// use std::io::Cursor;
-/// use byteorder::{BigEndian, ReadBytesExt};
-///
-/// let mut rdr = Cursor::new(vec![2, 5, 3, 0]);
-/// assert_eq!(517, rdr.read_u16::<BigEndian>().unwrap());
-/// assert_eq!(768, rdr.read_u16::<BigEndian>().unwrap());
-/// ```
-pub trait ReadBytesExt: io::Read {
-    /// Reads an unsigned 8 bit integer from the underlying reader.
-    ///
-    /// Note that since this reads a single byte, no byte order conversions
-    /// are used. It is included for completeness.
-    #[inline]
-    fn read_u8(&mut self) -> Result<u8> {
-        let mut buf = [0; 1];
-        try!(self.read_exact(&mut buf));
-        Ok(buf[0])
-    }
-
-    /// Reads a signed 8 bit integer from the underlying reader.
-    ///
-    /// Note that since this reads a single byte, no byte order conversions
-    /// are used. It is included for completeness.
-    #[inline]
-    fn read_i8(&mut self) -> Result<i8> {
-        let mut buf = [0; 1];
-        try!(self.read_exact(&mut buf));
-        Ok(buf[0] as i8)
-    }
-
-    /// Reads an unsigned 16 bit integer from the underlying reader.
-    #[inline]
-    fn read_u16<T: ByteOrder>(&mut self) -> Result<u16> {
-        let mut buf = [0; 2];
-        try!(self.read_exact(&mut buf));
-        Ok(T::read_u16(&buf))
-    }
-
-    /// Reads a signed 16 bit integer from the underlying reader.
-    #[inline]
-    fn read_i16<T: ByteOrder>(&mut self) -> Result<i16> {
-        let mut buf = [0; 2];
-        try!(self.read_exact(&mut buf));
-        Ok(T::read_i16(&buf))
-    }
-
-    /// Reads an unsigned 32 bit integer from the underlying reader.
-    #[inline]
-    fn read_u32<T: ByteOrder>(&mut self) -> Result<u32> {
-        let mut buf = [0; 4];
-        try!(self.read_exact(&mut buf));
-        Ok(T::read_u32(&buf))
-    }
-
-    /// Reads a signed 32 bit integer from the underlying reader.
-    #[inline]
-    fn read_i32<T: ByteOrder>(&mut self) -> Result<i32> {
-        let mut buf = [0; 4];
-        try!(self.read_exact(&mut buf));
-        Ok(T::read_i32(&buf))
-    }
-
-    /// Reads an unsigned 64 bit integer from the underlying reader.
-    #[inline]
-    fn read_u64<T: ByteOrder>(&mut self) -> Result<u64> {
-        let mut buf = [0; 8];
-        try!(self.read_exact(&mut buf));
-        Ok(T::read_u64(&buf))
-    }
-
-    /// Reads a signed 64 bit integer from the underlying reader.
-    #[inline]
-    fn read_i64<T: ByteOrder>(&mut self) -> Result<i64> {
-        let mut buf = [0; 8];
-        try!(self.read_exact(&mut buf));
-        Ok(T::read_i64(&buf))
-    }
-
-    /// Reads an unsigned n-bytes integer from the underlying reader.
-    #[inline]
-    fn read_uint<T: ByteOrder>(&mut self, nbytes: usize) -> Result<u64> {
-        let mut buf = [0; 8];
-        try!(self.read_exact(&mut buf[..nbytes]));
-        Ok(T::read_uint(&buf[..nbytes], nbytes))
-    }
-
-    /// Reads a signed n-bytes integer from the underlying reader.
-    #[inline]
-    fn read_int<T: ByteOrder>(&mut self, nbytes: usize) -> Result<i64> {
-        let mut buf = [0; 8];
-        try!(self.read_exact(&mut buf[..nbytes]));
-        Ok(T::read_int(&buf[..nbytes], nbytes))
-    }
-
-    /// Reads a IEEE754 single-precision (4 bytes) floating point number from
-    /// the underlying reader.
-    #[inline]
-    fn read_f32<T: ByteOrder>(&mut self) -> Result<f32> {
-        let mut buf = [0; 4];
-        try!(self.read_exact(&mut buf));
-        Ok(T::read_f32(&buf))
-    }
-
-    /// Reads a IEEE754 double-precision (8 bytes) floating point number from
-    /// the underlying reader.
-    #[inline]
-    fn read_f64<T: ByteOrder>(&mut self) -> Result<f64> {
-        let mut buf = [0; 8];
-        try!(self.read_exact(&mut buf));
-        Ok(T::read_f64(&buf))
-    }
-}
-
-/// All types that implement `Read` get methods defined in `ReadBytesExt`
-/// for free.
-impl<R: io::Read + ?Sized> ReadBytesExt for R {}
-
-/// Extends `Write` with methods for writing numbers. (For `std::io`.)
-///
-/// Most of the methods defined here have an unconstrained type parameter that
-/// must be explicitly instantiated. Typically, it is instantiated with either
-/// the `BigEndian` or `LittleEndian` types defined in this crate.
-///
-/// # Examples
-///
-/// Write unsigned 16 bit big-endian integers to a `Write`:
-///
-/// ```rust
-/// use byteorder::{BigEndian, WriteBytesExt};
-///
-/// let mut wtr = vec![];
-/// wtr.write_u16::<BigEndian>(517).unwrap();
-/// wtr.write_u16::<BigEndian>(768).unwrap();
-/// assert_eq!(wtr, vec![2, 5, 3, 0]);
-/// ```
-pub trait WriteBytesExt: io::Write {
-    /// Writes an unsigned 8 bit integer to the underlying writer.
-    ///
-    /// Note that since this writes a single byte, no byte order conversions
-    /// are used. It is included for completeness.
-    #[inline]
-    fn write_u8(&mut self, n: u8) -> Result<()> {
-        self.write_all(&[n])
-    }
-
-    /// Writes a signed 8 bit integer to the underlying writer.
-    ///
-    /// Note that since this writes a single byte, no byte order conversions
-    /// are used. It is included for completeness.
-    #[inline]
-    fn write_i8(&mut self, n: i8) -> Result<()> {
-        self.write_all(&[n as u8])
-    }
-
-    /// Writes an unsigned 16 bit integer to the underlying writer.
-    #[inline]
-    fn write_u16<T: ByteOrder>(&mut self, n: u16) -> Result<()> {
-        let mut buf = [0; 2];
-        T::write_u16(&mut buf, n);
-        self.write_all(&buf)
-    }
-
-    /// Writes a signed 16 bit integer to the underlying writer.
-    #[inline]
-    fn write_i16<T: ByteOrder>(&mut self, n: i16) -> Result<()> {
-        let mut buf = [0; 2];
-        T::write_i16(&mut buf, n);
-        self.write_all(&buf)
-    }
-
-    /// Writes an unsigned 32 bit integer to the underlying writer.
-    #[inline]
-    fn write_u32<T: ByteOrder>(&mut self, n: u32) -> Result<()> {
-        let mut buf = [0; 4];
-        T::write_u32(&mut buf, n);
-        self.write_all(&buf)
-    }
-
-    /// Writes a signed 32 bit integer to the underlying writer.
-    #[inline]
-    fn write_i32<T: ByteOrder>(&mut self, n: i32) -> Result<()> {
-        let mut buf = [0; 4];
-        T::write_i32(&mut buf, n);
-        self.write_all(&buf)
-    }
-
-    /// Writes an unsigned 64 bit integer to the underlying writer.
-    #[inline]
-    fn write_u64<T: ByteOrder>(&mut self, n: u64) -> Result<()> {
-        let mut buf = [0; 8];
-        T::write_u64(&mut buf, n);
-        self.write_all(&buf)
-    }
-
-    /// Writes a signed 64 bit integer to the underlying writer.
-    #[inline]
-    fn write_i64<T: ByteOrder>(&mut self, n: i64) -> Result<()> {
-        let mut buf = [0; 8];
-        T::write_i64(&mut buf, n);
-        self.write_all(&buf)
-    }
-
-    /// Writes an unsigned n-bytes integer to the underlying writer.
-    ///
-    /// If the given integer is not representable in the given number of bytes,
-    /// this method panics. If `nbytes > 8`, this method panics.
-    #[inline]
-    fn write_uint<T: ByteOrder>(
-        &mut self,
-        n: u64,
-        nbytes: usize,
-    ) -> Result<()> {
-        let mut buf = [0; 8];
-        T::write_uint(&mut buf, n, nbytes);
-        self.write_all(&buf[0..nbytes])
-    }
-
-    /// Writes a signed n-bytes integer to the underlying writer.
-    ///
-    /// If the given integer is not representable in the given number of bytes,
-    /// this method panics. If `nbytes > 8`, this method panics.
-    #[inline]
-    fn write_int<T: ByteOrder>(
-        &mut self,
-        n: i64,
-        nbytes: usize,
-    ) -> Result<()> {
-        let mut buf = [0; 8];
-        T::write_int(&mut buf, n, nbytes);
-        self.write_all(&buf[0..nbytes])
-    }
-
-    /// Writes a IEEE754 single-precision (4 bytes) floating point number to
-    /// the underlying writer.
-    #[inline]
-    fn write_f32<T: ByteOrder>(&mut self, n: f32) -> Result<()> {
-        let mut buf = [0; 4];
-        T::write_f32(&mut buf, n);
-        self.write_all(&buf)
-    }
-
-    /// Writes a IEEE754 double-precision (8 bytes) floating point number to
-    /// the underlying writer.
-    #[inline]
-    fn write_f64<T: ByteOrder>(&mut self, n: f64) -> Result<()> {
-        let mut buf = [0; 8];
-        T::write_f64(&mut buf, n);
-        self.write_all(&buf)
-    }
-}
-
-/// All types that implement `Write` get methods defined in `WriteBytesExt`
-/// for free.
-impl<W: io::Write + ?Sized> WriteBytesExt for W {}
new file mode 100644
--- /dev/null
+++ b/third_party/rust/byteorder-1.1.0/.cargo-checksum.json
@@ -0,0 +1,1 @@
+{"files":{".travis.yml":"a798200a7a2a7b499b4c44f0e516cd8975dc5f4b933144d1e2b1523087330b95","CHANGELOG.md":"caa17ca58eafcd282ed7b8bd47ef0670ce30a20aad339bf2758469f09fa4559d","COPYING":"01c266bced4a434da0051174d6bee16a4c82cf634e2679b6155d40d75012390f","Cargo.toml":"0e636678a02b111d1ebdfdc8ac5a835a2a41370028eeadf6d5fbfd3239f531f8","LICENSE-MIT":"0f96a83840e146e43c0ec96a22ec1f392e0680e6c1226e6f3ba87e0740af850f","README.md":"0559514b9d7488e96fb7a2f3c043a62fadf3495a1e10602d109ce79ee67da998","UNLICENSE":"7e12e5df4bae12cb21581ba157ced20e1986a0508dd10d0e8a4ab9a4cf94e85c","benches/bench.rs":"250d46461a0529a856d76a6421fd45c499bccba2c532e05dbf438c94582a8eac","src/io.rs":"5429f522221b3cce8a5c90fba7ad98b0ddad4fab44acc39763e6adabd511c021","src/lib.rs":"d31f218ca1892bea2812dd575ceb700779de704dc8bf1b9a778315ab75343c5d"},"package":"ff81738b726f5d099632ceaffe7fb65b90212e8dce59d518729e7e8634032d3d"}
\ No newline at end of file
new file mode 100644
--- /dev/null
+++ b/third_party/rust/byteorder-1.1.0/.travis.yml
@@ -0,0 +1,22 @@
+language: rust
+rust:
+  - 1.12.0
+  - stable
+  - beta
+  - nightly
+script:
+  - cargo build --verbose
+  - cargo doc
+  - cargo test --verbose
+  - cargo test --verbose --no-default-features --lib
+  - if [ "$TRAVIS_RUST_VERSION" = "nightly" ]; then
+      cargo test --verbose --features i128;
+      cargo test --verbose --no-default-features --features i128 --lib;
+      cargo bench --verbose --no-run;
+      cargo bench --verbose --no-run --no-default-features;
+      cargo bench --verbose --no-run --features i128;
+      cargo bench --verbose --no-run --no-default-features --features i128;
+    fi
+branches:
+  only:
+    - master
new file mode 100644
--- /dev/null
+++ b/third_party/rust/byteorder-1.1.0/CHANGELOG.md
@@ -0,0 +1,36 @@
+1.1.0
+=====
+This release of `byteorder` features a number of fixes and improvements, mostly
+as a result of the
+[Litz Blitz evaluation](https://public.etherpad-mozilla.org/p/rust-crate-eval-byteorder).
+
+Feature enhancements:
+
+* [FEATURE #63](https://github.com/BurntSushi/byteorder/issues/63):
+  Add methods for reading/writing slices of numbers for a specific
+  endianness.
+* [FEATURE #65](https://github.com/BurntSushi/byteorder/issues/65):
+  Add support for `u128`/`i128` types. (Behind the nightly only `i128`
+  feature.)
+* [FEATURE #72](https://github.com/BurntSushi/byteorder/issues/72):
+  Add "panics" and "errors" sections for each relevant public API item.
+* [FEATURE #74](https://github.com/BurntSushi/byteorder/issues/74):
+  Add CI badges to Cargo.toml.
+* [FEATURE #75](https://github.com/BurntSushi/byteorder/issues/75):
+  Add more examples to public API items.
+* Add 24-bit read/write methods.
+* Add `BE` and `LE` type aliases for `BigEndian` and `LittleEndian`,
+  respectively.
+
+Bug fixes:
+
+* [BUG #68](https://github.com/BurntSushi/byteorder/issues/68):
+  Panic in {BigEndian,LittleEndian}::default.
+* [BUG #69](https://github.com/BurntSushi/byteorder/issues/69):
+  Seal the `ByteOrder` trait to prevent out-of-crate implementations.
+* [BUG #71](https://github.com/BurntSushi/byteorder/issues/71):
+  Guarantee that the results of `read_f32`/`read_f64` are always defined.
+* [BUG #73](https://github.com/BurntSushi/byteorder/issues/73):
+  Add crates.io categories.
+* [BUG #77](https://github.com/BurntSushi/byteorder/issues/77):
+  Add `html_root` doc attribute.
rename from third_party/rust/byteorder-1.0.0/COPYING
rename to third_party/rust/byteorder-1.1.0/COPYING
new file mode 100644
--- /dev/null
+++ b/third_party/rust/byteorder-1.1.0/Cargo.toml
@@ -0,0 +1,44 @@
+# THIS FILE IS AUTOMATICALLY GENERATED BY CARGO
+#
+# When uploading crates to the registry Cargo will automatically
+# "normalize" Cargo.toml files for maximal compatibility
+# with all versions of Cargo and also rewrite `path` dependencies
+# to registry (e.g. crates.io) dependencies
+#
+# If you believe there's an error in this file please file an
+# issue against the rust-lang/cargo repository. If you're
+# editing this file be aware that the upstream Cargo.toml
+# will likely look very different (and much more reasonable)
+
+[package]
+name = "byteorder"
+version = "1.1.0"
+authors = ["Andrew Gallant <jamslam@gmail.com>"]
+description = "Library for reading/writing numbers in big-endian and little-endian."
+homepage = "https://github.com/BurntSushi/byteorder"
+documentation = "https://docs.rs/byteorder"
+readme = "README.md"
+keywords = ["byte", "endian", "big-endian", "little-endian", "binary"]
+categories = ["encoding", "parsing"]
+license = "Unlicense/MIT"
+repository = "https://github.com/BurntSushi/byteorder"
+[profile.bench]
+opt-level = 3
+
+[lib]
+name = "byteorder"
+bench = false
+[dev-dependencies.rand]
+version = "0.3"
+
+[dev-dependencies.quickcheck]
+version = "0.4"
+default-features = false
+
+[features]
+default = ["std"]
+i128 = []
+std = []
+[badges.travis-ci]
+branch = "master"
+repository = "https://github.com/BurntSushi/byteorder"
rename from third_party/rust/byteorder-1.0.0/LICENSE-MIT
rename to third_party/rust/byteorder-1.1.0/LICENSE-MIT
rename from third_party/rust/byteorder-1.0.0/README.md
rename to third_party/rust/byteorder-1.1.0/README.md
rename from third_party/rust/byteorder-1.0.0/UNLICENSE
rename to third_party/rust/byteorder-1.1.0/UNLICENSE
new file mode 100644
--- /dev/null
+++ b/third_party/rust/byteorder-1.1.0/benches/bench.rs
@@ -0,0 +1,320 @@
+#![cfg_attr(feature = "i128", feature(i128))]
+#![feature(test)]
+
+extern crate byteorder;
+extern crate rand;
+extern crate test;
+
+macro_rules! bench_num {
+    ($name:ident, $read:ident, $bytes:expr, $data:expr) => (
+        mod $name {
+            use byteorder::{ByteOrder, BigEndian, NativeEndian, LittleEndian};
+            use super::test::Bencher;
+            use super::test::black_box as bb;
+
+            const NITER: usize = 100_000;
+
+            #[bench]
+            fn read_big_endian(b: &mut Bencher) {
+                let buf = $data;
+                b.iter(|| {
+                    for _ in 0..NITER {
+                        bb(BigEndian::$read(&buf, $bytes));
+                    }
+                });
+            }
+
+            #[bench]
+            fn read_little_endian(b: &mut Bencher) {
+                let buf = $data;
+                b.iter(|| {
+                    for _ in 0..NITER {
+                        bb(LittleEndian::$read(&buf, $bytes));
+                    }
+                });
+            }
+
+            #[bench]
+            fn read_native_endian(b: &mut Bencher) {
+                let buf = $data;
+                b.iter(|| {
+                    for _ in 0..NITER {
+                        bb(NativeEndian::$read(&buf, $bytes));
+                    }
+                });
+            }
+        }
+    );
+    ($ty:ident, $max:ident,
+     $read:ident, $write:ident, $size:expr, $data:expr) => (
+        mod $ty {
+            use std::$ty;
+            use byteorder::{ByteOrder, BigEndian, NativeEndian, LittleEndian};
+            use super::test::Bencher;
+            use super::test::black_box as bb;
+
+            const NITER: usize = 100_000;
+
+            #[bench]
+            fn read_big_endian(b: &mut Bencher) {
+                let buf = $data;
+                b.iter(|| {
+                    for _ in 0..NITER {
+                        bb(BigEndian::$read(&buf));
+                    }
+                });
+            }
+
+            #[bench]
+            fn read_little_endian(b: &mut Bencher) {
+                let buf = $data;
+                b.iter(|| {
+                    for _ in 0..NITER {
+                        bb(LittleEndian::$read(&buf));
+                    }
+                });
+            }
+
+            #[bench]
+            fn read_native_endian(b: &mut Bencher) {
+                let buf = $data;
+                b.iter(|| {
+                    for _ in 0..NITER {
+                        bb(NativeEndian::$read(&buf));
+                    }
+                });
+            }
+
+            #[bench]
+            fn write_big_endian(b: &mut Bencher) {
+                let mut buf = $data;
+                let n = $ty::$max;
+                b.iter(|| {
+                    for _ in 0..NITER {
+                        bb(BigEndian::$write(&mut buf, n));
+                    }
+                });
+            }
+
+            #[bench]
+            fn write_little_endian(b: &mut Bencher) {
+                let mut buf = $data;
+                let n = $ty::$max;
+                b.iter(|| {
+                    for _ in 0..NITER {
+                        bb(LittleEndian::$write(&mut buf, n));
+                    }
+                });
+            }
+
+            #[bench]
+            fn write_native_endian(b: &mut Bencher) {
+                let mut buf = $data;
+                let n = $ty::$max;
+                b.iter(|| {
+                    for _ in 0..NITER {
+                        bb(NativeEndian::$write(&mut buf, n));
+                    }
+                });
+            }
+        }
+    );
+}
+
+bench_num!(u16, MAX, read_u16, write_u16, 2, [1, 2]);
+bench_num!(i16, MAX, read_i16, write_i16, 2, [1, 2]);
+bench_num!(u32, MAX, read_u32, write_u32, 4, [1, 2, 3, 4]);
+bench_num!(i32, MAX, read_i32, write_i32, 4, [1, 2, 3, 4]);
+bench_num!(u64, MAX, read_u64, write_u64, 8, [1, 2, 3, 4, 5, 6, 7, 8]);
+bench_num!(i64, MAX, read_i64, write_i64, 8, [1, 2, 3, 4, 5, 6, 7, 8]);
+bench_num!(f32, MAX, read_f32, write_f32, 4, [1, 2, 3, 4]);
+bench_num!(f64, MAX, read_f64, write_f64, 8,
+           [1, 2, 3, 4, 5, 6, 7, 8]);
+
+bench_num!(uint_1, read_uint, 1, [1]);
+bench_num!(uint_2, read_uint, 2, [1, 2]);
+bench_num!(uint_3, read_uint, 3, [1, 2, 3]);
+bench_num!(uint_4, read_uint, 4, [1, 2, 3, 4]);
+bench_num!(uint_5, read_uint, 5, [1, 2, 3, 4, 5]);
+bench_num!(uint_6, read_uint, 6, [1, 2, 3, 4, 5, 6]);
+bench_num!(uint_7, read_uint, 7, [1, 2, 3, 4, 5, 6, 7]);
+bench_num!(uint_8, read_uint, 8, [1, 2, 3, 4, 5, 6, 7, 8]);
+
+bench_num!(int_1, read_int, 1, [1]);
+bench_num!(int_2, read_int, 2, [1, 2]);
+bench_num!(int_3, read_int, 3, [1, 2, 3]);
+bench_num!(int_4, read_int, 4, [1, 2, 3, 4]);
+bench_num!(int_5, read_int, 5, [1, 2, 3, 4, 5]);
+bench_num!(int_6, read_int, 6, [1, 2, 3, 4, 5, 6]);
+bench_num!(int_7, read_int, 7, [1, 2, 3, 4, 5, 6, 7]);
+bench_num!(int_8, read_int, 8, [1, 2, 3, 4, 5, 6, 7, 8]);
+
+#[cfg(feature = "i128")]
+bench_num!(u128, MAX, read_u128, write_u128,
+    16, [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16]);
+#[cfg(feature = "i128")]
+bench_num!(i128, MAX, read_i128, write_i128,
+    16, [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16]);
+
+#[cfg(feature = "i128")]
+bench_num!(uint128_1, read_uint128,
+    1, [1]);
+#[cfg(feature = "i128")]
+bench_num!(uint128_2, read_uint128,
+    2, [1, 2]);
+#[cfg(feature = "i128")]
+bench_num!(uint128_3, read_uint128,
+    3, [1, 2, 3]);
+#[cfg(feature = "i128")]
+bench_num!(uint128_4, read_uint128,
+    4, [1, 2, 3, 4]);
+#[cfg(feature = "i128")]
+bench_num!(uint128_5, read_uint128,
+    5, [1, 2, 3, 4, 5]);
+#[cfg(feature = "i128")]
+bench_num!(uint128_6, read_uint128,
+    6, [1, 2, 3, 4, 5, 6]);
+#[cfg(feature = "i128")]
+bench_num!(uint128_7, read_uint128,
+    7, [1, 2, 3, 4, 5, 6, 7]);
+#[cfg(feature = "i128")]
+bench_num!(uint128_8, read_uint128,
+    8, [1, 2, 3, 4, 5, 6, 7, 8]);
+#[cfg(feature = "i128")]
+bench_num!(uint128_9, read_uint128,
+    9, [1, 2, 3, 4, 5, 6, 7, 8, 9]);
+#[cfg(feature = "i128")]
+bench_num!(uint128_10, read_uint128,
+    10, [1, 2, 3, 4, 5, 6, 7, 8, 9, 10]);
+#[cfg(feature = "i128")]
+bench_num!(uint128_11, read_uint128,
+    11, [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11]);
+#[cfg(feature = "i128")]
+bench_num!(uint128_12, read_uint128,
+    12, [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12]);
+#[cfg(feature = "i128")]
+bench_num!(uint128_13, read_uint128,
+    13, [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13]);
+#[cfg(feature = "i128")]
+bench_num!(uint128_14, read_uint128,
+    14, [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14]);
+#[cfg(feature = "i128")]
+bench_num!(uint128_15, read_uint128,
+    15, [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15]);
+#[cfg(feature = "i128")]
+bench_num!(uint128_16, read_uint128,
+    16, [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16]);
+
+#[cfg(feature = "i128")]
+bench_num!(int128_1, read_int128,
+    1, [1]);
+#[cfg(feature = "i128")]
+bench_num!(int128_2, read_int128,
+    2, [1, 2]);
+#[cfg(feature = "i128")]
+bench_num!(int128_3, read_int128,
+    3, [1, 2, 3]);
+#[cfg(feature = "i128")]
+bench_num!(int128_4, read_int128,
+    4, [1, 2, 3, 4]);
+#[cfg(feature = "i128")]
+bench_num!(int128_5, read_int128,
+    5, [1, 2, 3, 4, 5]);
+#[cfg(feature = "i128")]
+bench_num!(int128_6, read_int128,
+    6, [1, 2, 3, 4, 5, 6]);
+#[cfg(feature = "i128")]
+bench_num!(int128_7, read_int128,
+    7, [1, 2, 3, 4, 5, 6, 7]);
+#[cfg(feature = "i128")]
+bench_num!(int128_8, read_int128,
+    8, [1, 2, 3, 4, 5, 6, 7, 8]);
+#[cfg(feature = "i128")]
+bench_num!(int128_9, read_int128,
+    9, [1, 2, 3, 4, 5, 6, 7, 8, 9]);
+#[cfg(feature = "i128")]
+bench_num!(int128_10, read_int128,
+    10, [1, 2, 3, 4, 5, 6, 7, 8, 9, 10]);
+#[cfg(feature = "i128")]
+bench_num!(int128_11, read_int128,
+    11, [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11]);
+#[cfg(feature = "i128")]
+bench_num!(int128_12, read_int128,
+    12, [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12]);
+#[cfg(feature = "i128")]
+bench_num!(int128_13, read_int128,
+    13, [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13]);
+#[cfg(feature = "i128")]
+bench_num!(int128_14, read_int128,
+    14, [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14]);
+#[cfg(feature = "i128")]
+bench_num!(int128_15, read_int128,
+    15, [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15]);
+#[cfg(feature = "i128")]
+bench_num!(int128_16, read_int128,
+    16, [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16]);
+
+
+macro_rules! bench_slice {
+    ($name:ident, $numty:ty, $read:ident, $write:ident) => {
+        mod $name {
+            use std::mem::size_of;
+
+            use byteorder::{ByteOrder, BigEndian, LittleEndian};
+            use rand::{self, Rng};
+            use test::Bencher;
+
+            #[bench]
+            fn read_big_endian(b: &mut Bencher) {
+                let mut numbers: Vec<$numty> =
+                    rand::thread_rng().gen_iter().take(100000).collect();
+                let mut bytes = vec![0; numbers.len() * size_of::<$numty>()];
+                BigEndian::$write(&numbers, &mut bytes);
+
+                b.bytes = bytes.len() as u64;
+                b.iter(|| {
+                    BigEndian::$read(&bytes, &mut numbers);
+                });
+            }
+
+            #[bench]
+            fn read_little_endian(b: &mut Bencher) {
+                let mut numbers: Vec<$numty> =
+                    rand::thread_rng().gen_iter().take(100000).collect();
+                let mut bytes = vec![0; numbers.len() * size_of::<$numty>()];
+                LittleEndian::$write(&numbers, &mut bytes);
+
+                b.bytes = bytes.len() as u64;
+                b.iter(|| {
+                    LittleEndian::$read(&bytes, &mut numbers);
+                });
+            }
+
+            #[bench]
+            fn write_big_endian(b: &mut Bencher) {
+                let numbers: Vec<$numty> =
+                    rand::thread_rng().gen_iter().take(100000).collect();
+                let mut bytes = vec![0; numbers.len() * size_of::<$numty>()];
+
+                b.bytes = bytes.len() as u64;
+                b.iter(|| {
+                    BigEndian::$write(&numbers, &mut bytes);
+                });
+            }
+
+            #[bench]
+            fn write_little_endian(b: &mut Bencher) {
+                let numbers: Vec<$numty> =
+                    rand::thread_rng().gen_iter().take(100000).collect();
+                let mut bytes = vec![0; numbers.len() * size_of::<$numty>()];
+
+                b.bytes = bytes.len() as u64;
+                b.iter(|| {
+                    LittleEndian::$write(&numbers, &mut bytes);
+                });
+            }
+        }
+    }
+}
+
+bench_slice!(slice_u64, u64, read_u64_into, write_u64_into);
new file mode 100644
--- /dev/null
+++ b/third_party/rust/byteorder-1.1.0/src/io.rs
@@ -0,0 +1,1189 @@
+use std::io::{self, Result};
+use std::slice;
+// use std::mem::transmute;
+
+use ByteOrder;
+
+/// Extends `Read` with methods for reading numbers. (For `std::io`.)
+///
+/// Most of the methods defined here have an unconstrained type parameter that
+/// must be explicitly instantiated. Typically, it is instantiated with either
+/// the `BigEndian` or `LittleEndian` types defined in this crate.
+///
+/// # Examples
+///
+/// Read unsigned 16 bit big-endian integers from a `Read`:
+///
+/// ```rust
+/// use std::io::Cursor;
+/// use byteorder::{BigEndian, ReadBytesExt};
+///
+/// let mut rdr = Cursor::new(vec![2, 5, 3, 0]);
+/// assert_eq!(517, rdr.read_u16::<BigEndian>().unwrap());
+/// assert_eq!(768, rdr.read_u16::<BigEndian>().unwrap());
+/// ```
+pub trait ReadBytesExt: io::Read {
+    /// Reads an unsigned 8 bit integer from the underlying reader.
+    ///
+    /// Note that since this reads a single byte, no byte order conversions
+    /// are used. It is included for completeness.
+    ///
+    /// # Errors
+    ///
+    /// This method returns the same errors as [`Read::read_exact`].
+    ///
+    /// [`Read::read_exact`]: https://doc.rust-lang.org/std/io/trait.Read.html#method.read_exact
+    ///
+    /// # Examples
+    ///
+    /// Read unsigned 8 bit integers from a `Read`:
+    ///
+    /// ```rust
+    /// use std::io::Cursor;
+    /// use byteorder::{BigEndian, ReadBytesExt};
+    ///
+    /// let mut rdr = Cursor::new(vec![2, 5]);
+    /// assert_eq!(2, rdr.read_u8().unwrap());
+    /// assert_eq!(5, rdr.read_u8().unwrap());
+    /// ```
+    #[inline]
+    fn read_u8(&mut self) -> Result<u8> {
+        let mut buf = [0; 1];
+        try!(self.read_exact(&mut buf));
+        Ok(buf[0])
+    }
+
+    /// Reads a signed 8 bit integer from the underlying reader.
+    ///
+    /// Note that since this reads a single byte, no byte order conversions
+    /// are used. It is included for completeness.
+    ///
+    /// # Errors
+    ///
+    /// This method returns the same errors as [`Read::read_exact`].
+    ///
+    /// [`Read::read_exact`]: https://doc.rust-lang.org/std/io/trait.Read.html#method.read_exact
+    ///
+    /// # Examples
+    ///
+    /// Read unsigned 8 bit integers from a `Read`:
+    ///
+    /// ```rust
+    /// use std::io::Cursor;
+    /// use byteorder::{BigEndian, ReadBytesExt};
+    ///
+    /// let mut rdr = Cursor::new(vec![0x02, 0xfb]);
+    /// assert_eq!(2, rdr.read_i8().unwrap());
+    /// assert_eq!(-5, rdr.read_i8().unwrap());
+    /// ```
+    #[inline]
+    fn read_i8(&mut self) -> Result<i8> {
+        let mut buf = [0; 1];
+        try!(self.read_exact(&mut buf));
+        Ok(buf[0] as i8)
+    }
+
+    /// Reads an unsigned 16 bit integer from the underlying reader.
+    ///
+    /// # Errors
+    ///
+    /// This method returns the same errors as [`Read::read_exact`].
+    ///
+    /// [`Read::read_exact`]: https://doc.rust-lang.org/std/io/trait.Read.html#method.read_exact
+    ///
+    /// # Examples
+    ///
+    /// Read unsigned 16 bit big-endian integers from a `Read`:
+    ///
+    /// ```rust
+    /// use std::io::Cursor;
+    /// use byteorder::{BigEndian, ReadBytesExt};
+    ///
+    /// let mut rdr = Cursor::new(vec![2, 5, 3, 0]);
+    /// assert_eq!(517, rdr.read_u16::<BigEndian>().unwrap());
+    /// assert_eq!(768, rdr.read_u16::<BigEndian>().unwrap());
+    /// ```
+    #[inline]
+    fn read_u16<T: ByteOrder>(&mut self) -> Result<u16> {
+        let mut buf = [0; 2];
+        try!(self.read_exact(&mut buf));
+        Ok(T::read_u16(&buf))
+    }
+
+    /// Reads a signed 16 bit integer from the underlying reader.
+    ///
+    /// # Errors
+    ///
+    /// This method returns the same errors as [`Read::read_exact`].
+    ///
+    /// [`Read::read_exact`]: https://doc.rust-lang.org/std/io/trait.Read.html#method.read_exact
+    ///
+    /// # Examples
+    ///
+    /// Read signed 16 bit big-endian integers from a `Read`:
+    ///
+    /// ```rust
+    /// use std::io::Cursor;
+    /// use byteorder::{BigEndian, ReadBytesExt};
+    ///
+    /// let mut rdr = Cursor::new(vec![0x00, 0xc1, 0xff, 0x7c]);
+    /// assert_eq!(193, rdr.read_i16::<BigEndian>().unwrap());
+    /// assert_eq!(-132, rdr.read_i16::<BigEndian>().unwrap());
+    /// ```
+    #[inline]
+    fn read_i16<T: ByteOrder>(&mut self) -> Result<i16> {
+        let mut buf = [0; 2];
+        try!(self.read_exact(&mut buf));
+        Ok(T::read_i16(&buf))
+    }
+
+    /// Reads an unsigned 24 bit integer from the underlying reader.
+    ///
+    /// # Errors
+    ///
+    /// This method returns the same errors as [`Read::read_exact`].
+    ///
+    /// [`Read::read_exact`]: https://doc.rust-lang.org/std/io/trait.Read.html#method.read_exact
+    ///
+    /// # Examples
+    ///
+    /// Read unsigned 24 bit big-endian integers from a `Read`:
+    ///
+    /// ```rust
+    /// use std::io::Cursor;
+    /// use byteorder::{BigEndian, ReadBytesExt};
+    ///
+    /// let mut rdr = Cursor::new(vec![0x00, 0x01, 0x0b]);
+    /// assert_eq!(267, rdr.read_u24::<BigEndian>().unwrap());
+    /// ```
+    #[inline]
+    fn read_u24<T: ByteOrder>(&mut self) -> Result<u32> {
+        let mut buf = [0; 3];
+        try!(self.read_exact(&mut buf));
+        Ok(T::read_u24(&buf))
+    }
+
+    /// Reads a signed 24 bit integer from the underlying reader.
+    ///
+    /// # Errors
+    ///
+    /// This method returns the same errors as [`Read::read_exact`].
+    ///
+    /// [`Read::read_exact`]: https://doc.rust-lang.org/std/io/trait.Read.html#method.read_exact
+    ///
+    /// # Examples
+    ///
+    /// Read signed 24 bit big-endian integers from a `Read`:
+    ///
+    /// ```rust
+    /// use std::io::Cursor;
+    /// use byteorder::{BigEndian, ReadBytesExt};
+    ///
+    /// let mut rdr = Cursor::new(vec![0xff, 0x7a, 0x33]);
+    /// assert_eq!(-34253, rdr.read_i24::<BigEndian>().unwrap());
+    /// ```
+    #[inline]
+    fn read_i24<T: ByteOrder>(&mut self) -> Result<i32> {
+        let mut buf = [0; 3];
+        try!(self.read_exact(&mut buf));
+        Ok(T::read_i24(&buf))
+    }
+
+    /// Reads an unsigned 32 bit integer from the underlying reader.
+    ///
+    /// # Errors
+    ///
+    /// This method returns the same errors as [`Read::read_exact`].
+    ///
+    /// [`Read::read_exact`]: https://doc.rust-lang.org/std/io/trait.Read.html#method.read_exact
+    ///
+    /// # Examples
+    ///
+    /// Read unsigned 32 bit big-endian integers from a `Read`:
+    ///
+    /// ```rust
+    /// use std::io::Cursor;
+    /// use byteorder::{BigEndian, ReadBytesExt};
+    ///
+    /// let mut rdr = Cursor::new(vec![0x00, 0x00, 0x01, 0x0b]);
+    /// assert_eq!(267, rdr.read_u32::<BigEndian>().unwrap());
+    /// ```
+    #[inline]
+    fn read_u32<T: ByteOrder>(&mut self) -> Result<u32> {
+        let mut buf = [0; 4];
+        try!(self.read_exact(&mut buf));
+        Ok(T::read_u32(&buf))
+    }
+
+    /// Reads a signed 32 bit integer from the underlying reader.
+    ///
+    /// # Errors
+    ///
+    /// This method returns the same errors as [`Read::read_exact`].
+    ///
+    /// [`Read::read_exact`]: https://doc.rust-lang.org/std/io/trait.Read.html#method.read_exact
+    ///
+    /// # Examples
+    ///
+    /// Read signed 32 bit big-endian integers from a `Read`:
+    ///
+    /// ```rust
+    /// use std::io::Cursor;
+    /// use byteorder::{BigEndian, ReadBytesExt};
+    ///
+    /// let mut rdr = Cursor::new(vec![0xff, 0xff, 0x7a, 0x33]);
+    /// assert_eq!(-34253, rdr.read_i32::<BigEndian>().unwrap());
+    /// ```
+    #[inline]
+    fn read_i32<T: ByteOrder>(&mut self) -> Result<i32> {
+        let mut buf = [0; 4];
+        try!(self.read_exact(&mut buf));
+        Ok(T::read_i32(&buf))
+    }
+
+    /// Reads an unsigned 64 bit integer from the underlying reader.
+    ///
+    /// # Errors
+    ///
+    /// This method returns the same errors as [`Read::read_exact`].
+    ///
+    /// [`Read::read_exact`]: https://doc.rust-lang.org/std/io/trait.Read.html#method.read_exact
+    ///
+    /// # Examples
+    ///
+    /// Read an unsigned 64 bit big-endian integer from a `Read`:
+    ///
+    /// ```rust
+    /// use std::io::Cursor;
+    /// use byteorder::{BigEndian, ReadBytesExt};
+    ///
+    /// let mut rdr = Cursor::new(vec![0x00, 0x03, 0x43, 0x95, 0x4d, 0x60, 0x86, 0x83]);
+    /// assert_eq!(918733457491587, rdr.read_u64::<BigEndian>().unwrap());
+    /// ```
+    #[inline]
+    fn read_u64<T: ByteOrder>(&mut self) -> Result<u64> {
+        let mut buf = [0; 8];
+        try!(self.read_exact(&mut buf));
+        Ok(T::read_u64(&buf))
+    }
+
+    /// Reads a signed 64 bit integer from the underlying reader.
+    ///
+    /// # Errors
+    ///
+    /// This method returns the same errors as [`Read::read_exact`].
+    ///
+    /// [`Read::read_exact`]: https://doc.rust-lang.org/std/io/trait.Read.html#method.read_exact
+    ///
+    /// # Examples
+    ///
+    /// Read a signed 64 bit big-endian integer from a `Read`:
+    ///
+    /// ```rust
+    /// use std::io::Cursor;
+    /// use byteorder::{BigEndian, ReadBytesExt};
+    ///
+    /// let mut rdr = Cursor::new(vec![0x80, 0, 0, 0, 0, 0, 0, 0]);
+    /// assert_eq!(i64::min_value(), rdr.read_i64::<BigEndian>().unwrap());
+    /// ```
+    #[inline]
+    fn read_i64<T: ByteOrder>(&mut self) -> Result<i64> {
+        let mut buf = [0; 8];
+        try!(self.read_exact(&mut buf));
+        Ok(T::read_i64(&buf))
+    }
+
+    /// Reads an unsigned 128 bit integer from the underlying reader.
+    ///
+    /// # Errors
+    ///
+    /// This method returns the same errors as [`Read::read_exact`].
+    ///
+    /// [`Read::read_exact`]: https://doc.rust-lang.org/std/io/trait.Read.html#method.read_exact
+    ///
+    /// # Examples
+    ///
+    /// Read an unsigned 128 bit big-endian integer from a `Read`:
+    ///
+    /// ```rust
+    /// use std::io::Cursor;
+    /// use byteorder::{BigEndian, ReadBytesExt};
+    ///
+    /// let mut rdr = Cursor::new(vec![
+    ///     0x00, 0x03, 0x43, 0x95, 0x4d, 0x60, 0x86, 0x83,
+    ///     0x00, 0x03, 0x43, 0x95, 0x4d, 0x60, 0x86, 0x83
+    /// ]);
+    /// assert_eq!(16947640962301618749969007319746179, rdr.read_u128::<BigEndian>().unwrap());
+    /// ```
+    #[cfg(feature = "i128")]
+    #[inline]
+    fn read_u128<T: ByteOrder>(&mut self) -> Result<u128> {
+        let mut buf = [0; 16];
+        try!(self.read_exact(&mut buf));
+        Ok(T::read_u128(&buf))
+    }
+
+    /// Reads a signed 128 bit integer from the underlying reader.
+    ///
+    /// # Errors
+    ///
+    /// This method returns the same errors as [`Read::read_exact`].
+    ///
+    /// [`Read::read_exact`]: https://doc.rust-lang.org/std/io/trait.Read.html#method.read_exact
+    ///
+    /// # Examples
+    ///
+    /// Read a signed 128 bit big-endian integer from a `Read`:
+    ///
+    /// ```rust
+    /// #![feature(i128_type)]
+    /// use std::io::Cursor;
+    /// use byteorder::{BigEndian, ReadBytesExt};
+    ///
+    /// let mut rdr = Cursor::new(vec![0x80, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]);
+    /// assert_eq!(i128::min_value(), rdr.read_i128::<BigEndian>().unwrap());
+    /// ```
+    #[cfg(feature = "i128")]
+    #[inline]
+    fn read_i128<T: ByteOrder>(&mut self) -> Result<i128> {
+        let mut buf = [0; 16];
+        try!(self.read_exact(&mut buf));
+        Ok(T::read_i128(&buf))
+    }
+
+    /// Reads an unsigned n-bytes integer from the underlying reader.
+    ///
+    /// # Errors
+    ///
+    /// This method returns the same errors as [`Read::read_exact`].
+    ///
+    /// [`Read::read_exact`]: https://doc.rust-lang.org/std/io/trait.Read.html#method.read_exact
+    ///
+    /// # Examples
+    ///
+    /// Read an unsigned n-byte big-endian integer from a `Read`:
+    ///
+    /// ```rust
+    /// use std::io::Cursor;
+    /// use byteorder::{BigEndian, ReadBytesExt};
+    ///
+    /// let mut rdr = Cursor::new(vec![0x80, 0x74, 0xfa]);
+    /// assert_eq!(8418554, rdr.read_uint::<BigEndian>(3).unwrap());
+    #[inline]
+    fn read_uint<T: ByteOrder>(&mut self, nbytes: usize) -> Result<u64> {
+        let mut buf = [0; 8];
+        try!(self.read_exact(&mut buf[..nbytes]));
+        Ok(T::read_uint(&buf[..nbytes], nbytes))
+    }
+
+    /// Reads a signed n-bytes integer from the underlying reader.
+    ///
+    /// # Errors
+    ///
+    /// This method returns the same errors as [`Read::read_exact`].
+    ///
+    /// [`Read::read_exact`]: https://doc.rust-lang.org/std/io/trait.Read.html#method.read_exact
+    ///
+    /// # Examples
+    ///
+    /// Read an unsigned n-byte big-endian integer from a `Read`:
+    ///
+    /// ```rust
+    /// use std::io::Cursor;
+    /// use byteorder::{BigEndian, ReadBytesExt};
+    ///
+    /// let mut rdr = Cursor::new(vec![0xc1, 0xff, 0x7c]);
+    /// assert_eq!(-4063364, rdr.read_int::<BigEndian>(3).unwrap());
+    #[inline]
+    fn read_int<T: ByteOrder>(&mut self, nbytes: usize) -> Result<i64> {
+        let mut buf = [0; 8];
+        try!(self.read_exact(&mut buf[..nbytes]));
+        Ok(T::read_int(&buf[..nbytes], nbytes))
+    }
+
+    /// Reads an unsigned n-bytes integer from the underlying reader.
+    #[cfg(feature = "i128")]
+    #[inline]
+    fn read_uint128<T: ByteOrder>(&mut self, nbytes: usize) -> Result<u128> {
+        let mut buf = [0; 16];
+        try!(self.read_exact(&mut buf[..nbytes]));
+        Ok(T::read_uint128(&buf[..nbytes], nbytes))
+    }
+
+    /// Reads a signed n-bytes integer from the underlying reader.
+    #[cfg(feature = "i128")]
+    #[inline]
+    fn read_int128<T: ByteOrder>(&mut self, nbytes: usize) -> Result<i128> {
+        let mut buf = [0; 16];
+        try!(self.read_exact(&mut buf[..nbytes]));
+        Ok(T::read_int128(&buf[..nbytes], nbytes))
+    }
+
+    /// Reads a IEEE754 single-precision (4 bytes) floating point number from
+    /// the underlying reader.
+    ///
+    /// # Errors
+    ///
+    /// This method returns the same errors as [`Read::read_exact`].
+    ///
+    /// [`Read::read_exact`]: https://doc.rust-lang.org/std/io/trait.Read.html#method.read_exact
+    ///
+    /// # Examples
+    ///
+    /// Read a big-endian single-precision floating point number from a `Read`:
+    ///
+    /// ```rust
+    /// use std::f32;
+    /// use std::io::Cursor;
+    ///
+    /// use byteorder::{BigEndian, ReadBytesExt};
+    ///
+    /// let mut rdr = Cursor::new(vec![
+    ///     0x40, 0x49, 0x0f, 0xdb,
+    /// ]);
+    /// assert_eq!(f32::consts::PI, rdr.read_f32::<BigEndian>().unwrap());
+    /// ```
+    #[inline]
+    fn read_f32<T: ByteOrder>(&mut self) -> Result<f32> {
+        let mut buf = [0; 4];
+        try!(self.read_exact(&mut buf));
+        Ok(T::read_f32(&buf))
+    }
+
+    /// Reads a IEEE754 double-precision (8 bytes) floating point number from
+    /// the underlying reader.
+    ///
+    /// # Errors
+    ///
+    /// This method returns the same errors as [`Read::read_exact`].
+    ///
+    /// [`Read::read_exact`]: https://doc.rust-lang.org/std/io/trait.Read.html#method.read_exact
+    ///
+    /// # Examples
+    ///
+    /// Read a big-endian double-precision floating point number from a `Read`:
+    ///
+    /// ```rust
+    /// use std::f64;
+    /// use std::io::Cursor;
+    ///
+    /// use byteorder::{BigEndian, ReadBytesExt};
+    ///
+    /// let mut rdr = Cursor::new(vec![
+    ///     0x40, 0x09, 0x21, 0xfb, 0x54, 0x44, 0x2d, 0x18,
+    /// ]);
+    /// assert_eq!(f64::consts::PI, rdr.read_f64::<BigEndian>().unwrap());
+    /// ```
+    #[inline]
+    fn read_f64<T: ByteOrder>(&mut self) -> Result<f64> {
+        let mut buf = [0; 8];
+        try!(self.read_exact(&mut buf));
+        Ok(T::read_f64(&buf))
+    }
+
+    /// Reads a sequence of unsigned 16 bit integers from the underlying
+    /// reader.
+    ///
+    /// The given buffer is either filled completely or an error is returned.
+    /// If an error is returned, the contents of `dst` are unspecified.
+    ///
+    /// # Errors
+    ///
+    /// This method returns the same errors as [`Read::read_exact`].
+    ///
+    /// [`Read::read_exact`]: https://doc.rust-lang.org/std/io/trait.Read.html#method.read_exact
+    ///
+    /// # Examples
+    ///
+    /// Read a sequence of unsigned 16 bit big-endian integers from a `Read`:
+    ///
+    /// ```rust
+    /// use std::io::Cursor;
+    /// use byteorder::{BigEndian, ReadBytesExt};
+    ///
+    /// let mut rdr = Cursor::new(vec![2, 5, 3, 0]);
+    /// let mut dst = [0; 2];
+    /// rdr.read_u16_into::<BigEndian>(&mut dst).unwrap();
+    /// assert_eq!([517, 768], dst);
+    /// ```
+    #[inline]
+    fn read_u16_into<T: ByteOrder>(&mut self, dst: &mut [u16]) -> Result<()> {
+        {
+            let mut buf = unsafe { slice_to_u8_mut(dst) };
+            try!(self.read_exact(buf));
+        }
+        T::from_slice_u16(dst);
+        Ok(())
+    }
+
+    /// Reads a sequence of unsigned 32 bit integers from the underlying
+    /// reader.
+    ///
+    /// The given buffer is either filled completely or an error is returned.
+    /// If an error is returned, the contents of `dst` are unspecified.
+    ///
+    /// # Errors
+    ///
+    /// This method returns the same errors as [`Read::read_exact`].
+    ///
+    /// [`Read::read_exact`]: https://doc.rust-lang.org/std/io/trait.Read.html#method.read_exact
+    ///
+    /// # Examples
+    ///
+    /// Read a sequence of unsigned 32 bit big-endian integers from a `Read`:
+    ///
+    /// ```rust
+    /// use std::io::Cursor;
+    /// use byteorder::{BigEndian, ReadBytesExt};
+    ///
+    /// let mut rdr = Cursor::new(vec![0, 0, 2, 5, 0, 0, 3, 0]);
+    /// let mut dst = [0; 2];
+    /// rdr.read_u32_into::<BigEndian>(&mut dst).unwrap();
+    /// assert_eq!([517, 768], dst);
+    /// ```
+    #[inline]
+    fn read_u32_into<T: ByteOrder>(&mut self, dst: &mut [u32]) -> Result<()> {
+        {
+            let mut buf = unsafe { slice_to_u8_mut(dst) };
+            try!(self.read_exact(buf));
+        }
+        T::from_slice_u32(dst);
+        Ok(())
+    }
+
+    /// Reads a sequence of unsigned 64 bit integers from the underlying
+    /// reader.
+    ///
+    /// The given buffer is either filled completely or an error is returned.
+    /// If an error is returned, the contents of `dst` are unspecified.
+    ///
+    /// # Errors
+    ///
+    /// This method returns the same errors as [`Read::read_exact`].
+    ///
+    /// [`Read::read_exact`]: https://doc.rust-lang.org/std/io/trait.Read.html#method.read_exact
+    ///
+    /// # Examples
+    ///
+    /// Read a sequence of unsigned 64 bit big-endian integers from a `Read`:
+    ///
+    /// ```rust
+    /// use std::io::Cursor;
+    /// use byteorder::{BigEndian, ReadBytesExt};
+    ///
+    /// let mut rdr = Cursor::new(vec![
+    ///     0, 0, 0, 0, 0, 0, 2, 5,
+    ///     0, 0, 0, 0, 0, 0, 3, 0,
+    /// ]);
+    /// let mut dst = [0; 2];
+    /// rdr.read_u64_into::<BigEndian>(&mut dst).unwrap();
+    /// assert_eq!([517, 768], dst);
+    /// ```
+    #[inline]
+    fn read_u64_into<T: ByteOrder>(&mut self, dst: &mut [u64]) -> Result<()> {
+        {
+            let mut buf = unsafe { slice_to_u8_mut(dst) };
+            try!(self.read_exact(buf));
+        }
+        T::from_slice_u64(dst);
+        Ok(())
+    }
+
+    /// Reads a sequence of unsigned 128 bit integers from the underlying
+    /// reader.
+    ///
+    /// The given buffer is either filled completely or an error is returned.
+    /// If an error is returned, the contents of `dst` are unspecified.
+    ///
+    /// # Errors
+    ///
+    /// This method returns the same errors as [`Read::read_exact`].
+    ///
+    /// [`Read::read_exact`]: https://doc.rust-lang.org/std/io/trait.Read.html#method.read_exact
+    ///
+    /// # Examples
+    ///
+    /// Read a sequence of unsigned 128 bit big-endian integers from a `Read`:
+    ///
+    /// ```rust
+    /// use std::io::Cursor;
+    /// use byteorder::{BigEndian, ReadBytesExt};
+    ///
+    /// let mut rdr = Cursor::new(vec![
+    ///     0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 5,
+    ///     0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 0,
+    /// ]);
+    /// let mut dst = [0; 2];
+    /// rdr.read_u128_into::<BigEndian>(&mut dst).unwrap();
+    /// assert_eq!([517, 768], dst);
+    /// ```
+    #[cfg(feature = "i128")]
+    #[inline]
+    fn read_u128_into<T: ByteOrder>(
+        &mut self,
+        dst: &mut [u128],
+    ) -> Result<()> {
+        {
+            let mut buf = unsafe { slice_to_u8_mut(dst) };
+            try!(self.read_exact(buf));
+        }
+        T::from_slice_u128(dst);
+        Ok(())
+    }
+
+    /// Reads a sequence of signed 16 bit integers from the underlying
+    /// reader.
+    ///
+    /// The given buffer is either filled completely or an error is returned.
+    /// If an error is returned, the contents of `dst` are unspecified.
+    ///
+    /// # Errors
+    ///
+    /// This method returns the same errors as [`Read::read_exact`].
+    ///
+    /// [`Read::read_exact`]: https://doc.rust-lang.org/std/io/trait.Read.html#method.read_exact
+    ///
+    /// # Examples
+    ///
+    /// Read a sequence of signed 16 bit big-endian integers from a `Read`:
+    ///
+    /// ```rust
+    /// use std::io::Cursor;
+    /// use byteorder::{BigEndian, ReadBytesExt};
+    ///
+    /// let mut rdr = Cursor::new(vec![2, 5, 3, 0]);
+    /// let mut dst = [0; 2];
+    /// rdr.read_i16_into::<BigEndian>(&mut dst).unwrap();
+    /// assert_eq!([517, 768], dst);
+    /// ```
+    #[inline]
+    fn read_i16_into<T: ByteOrder>(&mut self, dst: &mut [i16]) -> Result<()> {
+        {
+            let mut buf = unsafe { slice_to_u8_mut(dst) };
+            try!(self.read_exact(buf));
+        }
+        T::from_slice_i16(dst);
+        Ok(())
+    }
+
+    /// Reads a sequence of signed 32 bit integers from the underlying
+    /// reader.
+    ///
+    /// The given buffer is either filled completely or an error is returned.
+    /// If an error is returned, the contents of `dst` are unspecified.
+    ///
+    /// # Errors
+    ///
+    /// This method returns the same errors as [`Read::read_exact`].
+    ///
+    /// [`Read::read_exact`]: https://doc.rust-lang.org/std/io/trait.Read.html#method.read_exact
+    ///
+    /// # Examples
+    ///
+    /// Read a sequence of signed 32 bit big-endian integers from a `Read`:
+    ///
+    /// ```rust
+    /// use std::io::Cursor;
+    /// use byteorder::{BigEndian, ReadBytesExt};
+    ///
+    /// let mut rdr = Cursor::new(vec![0, 0, 2, 5, 0, 0, 3, 0]);
+    /// let mut dst = [0; 2];
+    /// rdr.read_i32_into::<BigEndian>(&mut dst).unwrap();
+    /// assert_eq!([517, 768], dst);
+    /// ```
+    #[inline]
+    fn read_i32_into<T: ByteOrder>(&mut self, dst: &mut [i32]) -> Result<()> {
+        {
+            let mut buf = unsafe { slice_to_u8_mut(dst) };
+            try!(self.read_exact(buf));
+        }
+        T::from_slice_i32(dst);
+        Ok(())
+    }
+
+    /// Reads a sequence of signed 64 bit integers from the underlying
+    /// reader.
+    ///
+    /// The given buffer is either filled completely or an error is returned.
+    /// If an error is returned, the contents of `dst` are unspecified.
+    ///
+    /// # Errors
+    ///
+    /// This method returns the same errors as [`Read::read_exact`].
+    ///
+    /// [`Read::read_exact`]: https://doc.rust-lang.org/std/io/trait.Read.html#method.read_exact
+    ///
+    /// # Examples
+    ///
+    /// Read a sequence of signed 64 bit big-endian integers from a `Read`:
+    ///
+    /// ```rust
+    /// use std::io::Cursor;
+    /// use byteorder::{BigEndian, ReadBytesExt};
+    ///
+    /// let mut rdr = Cursor::new(vec![
+    ///     0, 0, 0, 0, 0, 0, 2, 5,
+    ///     0, 0, 0, 0, 0, 0, 3, 0,
+    /// ]);
+    /// let mut dst = [0; 2];
+    /// rdr.read_i64_into::<BigEndian>(&mut dst).unwrap();
+    /// assert_eq!([517, 768], dst);
+    /// ```
+    #[inline]
+    fn read_i64_into<T: ByteOrder>(&mut self, dst: &mut [i64]) -> Result<()> {
+        {
+            let mut buf = unsafe { slice_to_u8_mut(dst) };
+            try!(self.read_exact(buf));
+        }
+        T::from_slice_i64(dst);
+        Ok(())
+    }
+
+    /// Reads a sequence of signed 128 bit integers from the underlying
+    /// reader.
+    ///
+    /// The given buffer is either filled completely or an error is returned.
+    /// If an error is returned, the contents of `dst` are unspecified.
+    ///
+    /// # Errors
+    ///
+    /// This method returns the same errors as [`Read::read_exact`].
+    ///
+    /// [`Read::read_exact`]: https://doc.rust-lang.org/std/io/trait.Read.html#method.read_exact
+    ///
+    /// # Examples
+    ///
+    /// Read a sequence of signed 128 bit big-endian integers from a `Read`:
+    ///
+    /// ```rust
+    /// use std::io::Cursor;
+    /// use byteorder::{BigEndian, ReadBytesExt};
+    ///
+    /// let mut rdr = Cursor::new(vec![
+    ///     0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 5,
+    ///     0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 0,
+    /// ]);
+    /// let mut dst = [0; 2];
+    /// rdr.read_i128_into::<BigEndian>(&mut dst).unwrap();
+    /// assert_eq!([517, 768], dst);
+    /// ```
+    #[cfg(feature = "i128")]
+    #[inline]
+    fn read_i128_into<T: ByteOrder>(
+        &mut self,
+        dst: &mut [i128],
+    ) -> Result<()> {
+        {
+            let mut buf = unsafe { slice_to_u8_mut(dst) };
+            try!(self.read_exact(buf));
+        }
+        T::from_slice_i128(dst);
+        Ok(())
+    }
+
+    /// Reads a sequence of IEEE754 single-precision (4 bytes) floating
+    /// point numbers from the underlying reader.
+    ///
+    /// The given buffer is either filled completely or an error is returned.
+    /// If an error is returned, the contents of `dst` are unspecified.
+    ///
+    /// # Safety
+    ///
+    /// This method is unsafe because there are no guarantees made about the
+    /// floating point values. In particular, this method does not check for
+    /// signaling NaNs, which may result in undefined behavior.
+    ///
+    /// # Errors
+    ///
+    /// This method returns the same errors as [`Read::read_exact`].
+    ///
+    /// [`Read::read_exact`]: https://doc.rust-lang.org/std/io/trait.Read.html#method.read_exact
+    ///
+    /// # Examples
+    ///
+    /// Read a sequence of big-endian single-precision floating point number
+    /// from a `Read`:
+    ///
+    /// ```rust
+    /// use std::f32;
+    /// use std::io::Cursor;
+    ///
+    /// use byteorder::{BigEndian, ReadBytesExt};
+    ///
+    /// let mut rdr = Cursor::new(vec![
+    ///     0x40, 0x49, 0x0f, 0xdb,
+    ///     0x3f, 0x80, 0x00, 0x00,
+    /// ]);
+    /// let mut dst = [0.0; 2];
+    /// unsafe {
+    ///     rdr.read_f32_into_unchecked::<BigEndian>(&mut dst).unwrap();
+    /// }
+    /// assert_eq!([f32::consts::PI, 1.0], dst);
+    /// ```
+    #[inline]
+    unsafe fn read_f32_into_unchecked<T: ByteOrder>(
+        &mut self,
+        dst: &mut [f32],
+    ) -> Result<()> {
+        {
+            let mut buf = slice_to_u8_mut(dst);
+            try!(self.read_exact(buf));
+        }
+        T::from_slice_f32(dst);
+        Ok(())
+    }
+
+    /// Reads a sequence of IEEE754 double-precision (8 bytes) floating
+    /// point numbers from the underlying reader.
+    ///
+    /// The given buffer is either filled completely or an error is returned.
+    /// If an error is returned, the contents of `dst` are unspecified.
+    ///
+    /// # Safety
+    ///
+    /// This method is unsafe because there are no guarantees made about the
+    /// floating point values. In particular, this method does not check for
+    /// signaling NaNs, which may result in undefined behavior.
+    ///
+    /// # Errors
+    ///
+    /// This method returns the same errors as [`Read::read_exact`].
+    ///
+    /// [`Read::read_exact`]: https://doc.rust-lang.org/std/io/trait.Read.html#method.read_exact
+    ///
+    /// # Examples
+    ///
+    /// Read a sequence of big-endian single-precision floating point number
+    /// from a `Read`:
+    ///
+    /// ```rust
+    /// use std::f64;
+    /// use std::io::Cursor;
+    ///
+    /// use byteorder::{BigEndian, ReadBytesExt};
+    ///
+    /// let mut rdr = Cursor::new(vec![
+    ///     0x40, 0x09, 0x21, 0xfb, 0x54, 0x44, 0x2d, 0x18,
+    ///     0x3f, 0xF0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+    /// ]);
+    /// let mut dst = [0.0; 2];
+    /// unsafe {
+    ///     rdr.read_f64_into_unchecked::<BigEndian>(&mut dst).unwrap();
+    /// }
+    /// assert_eq!([f64::consts::PI, 1.0], dst);
+    /// ```
+    #[inline]
+    unsafe fn read_f64_into_unchecked<T: ByteOrder>(
+        &mut self,
+        dst: &mut [f64],
+    ) -> Result<()> {
+        {
+            let mut buf = slice_to_u8_mut(dst);
+            try!(self.read_exact(buf));
+        }
+        T::from_slice_f64(dst);
+        Ok(())
+    }
+}
+
+/// All types that implement `Read` get methods defined in `ReadBytesExt`
+/// for free.
+impl<R: io::Read + ?Sized> ReadBytesExt for R {}
+
+/// Extends `Write` with methods for writing numbers. (For `std::io`.)
+///
+/// Most of the methods defined here have an unconstrained type parameter that
+/// must be explicitly instantiated. Typically, it is instantiated with either
+/// the `BigEndian` or `LittleEndian` types defined in this crate.
+///
+/// # Examples
+///
+/// Write unsigned 16 bit big-endian integers to a `Write`:
+///
+/// ```rust
+/// use byteorder::{BigEndian, WriteBytesExt};
+///
+/// let mut wtr = vec![];
+/// wtr.write_u16::<BigEndian>(517).unwrap();
+/// wtr.write_u16::<BigEndian>(768).unwrap();
+/// assert_eq!(wtr, vec![2, 5, 3, 0]);
+/// ```
+pub trait WriteBytesExt: io::Write {
+    /// Writes an unsigned 8 bit integer to the underlying writer.
+    ///
+    /// Note that since this writes a single byte, no byte order conversions
+    /// are used. It is included for completeness.
+    ///
+    /// # Errors
+    ///
+    /// This method returns the same errors as [`Write::write_all`].
+    ///
+    /// [`Write::write_all`]: https://doc.rust-lang.org/std/io/trait.Write.html#method.write_all
+    #[inline]
+    fn write_u8(&mut self, n: u8) -> Result<()> {
+        self.write_all(&[n])
+    }
+
+    /// Writes a signed 8 bit integer to the underlying writer.
+    ///
+    /// Note that since this writes a single byte, no byte order conversions
+    /// are used. It is included for completeness.
+    ///
+    /// # Errors
+    ///
+    /// This method returns the same errors as [`Write::write_all`].
+    ///
+    /// [`Write::write_all`]: https://doc.rust-lang.org/std/io/trait.Write.html#method.write_all
+    #[inline]
+    fn write_i8(&mut self, n: i8) -> Result<()> {
+        self.write_all(&[n as u8])
+    }
+
+    /// Writes an unsigned 16 bit integer to the underlying writer.
+    ///
+    /// # Errors
+    ///
+    /// This method returns the same errors as [`Write::write_all`].
+    ///
+    /// [`Write::write_all`]: https://doc.rust-lang.org/std/io/trait.Write.html#method.write_all
+    #[inline]
+    fn write_u16<T: ByteOrder>(&mut self, n: u16) -> Result<()> {
+        let mut buf = [0; 2];
+        T::write_u16(&mut buf, n);
+        self.write_all(&buf)
+    }
+
+    /// Writes a signed 16 bit integer to the underlying writer.
+    ///
+    /// # Errors
+    ///
+    /// This method returns the same errors as [`Write::write_all`].
+    ///
+    /// [`Write::write_all`]: https://doc.rust-lang.org/std/io/trait.Write.html#method.write_all
+    #[inline]
+    fn write_i16<T: ByteOrder>(&mut self, n: i16) -> Result<()> {
+        let mut buf = [0; 2];
+        T::write_i16(&mut buf, n);
+        self.write_all(&buf)
+    }
+
+    /// Writes an unsigned 24 bit integer to the underlying writer.
+    ///
+    /// # Errors
+    ///
+    /// This method returns the same errors as [`Write::write_all`].
+    ///
+    /// [`Write::write_all`]: https://doc.rust-lang.org/std/io/trait.Write.html#method.write_all
+    #[inline]
+    fn write_u24<T: ByteOrder>(&mut self, n: u32) -> Result<()> {
+        let mut buf = [0; 3];
+        T::write_u24(&mut buf, n);
+        self.write_all(&buf)
+    }
+
+    /// Writes a signed 24 bit integer to the underlying writer.
+    ///
+    /// # Errors
+    ///
+    /// This method returns the same errors as [`Write::write_all`].
+    ///
+    /// [`Write::write_all`]: https://doc.rust-lang.org/std/io/trait.Write.html#method.write_all
+    #[inline]
+    fn write_i24<T: ByteOrder>(&mut self, n: i32) -> Result<()> {
+        let mut buf = [0; 3];
+        T::write_i24(&mut buf, n);
+        self.write_all(&buf)
+    }
+
+    /// Writes an unsigned 32 bit integer to the underlying writer.
+    ///
+    /// # Errors
+    ///
+    /// This method returns the same errors as [`Write::write_all`].
+    ///
+    /// [`Write::write_all`]: https://doc.rust-lang.org/std/io/trait.Write.html#method.write_all
+    #[inline]
+    fn write_u32<T: ByteOrder>(&mut self, n: u32) -> Result<()> {
+        let mut buf = [0; 4];
+        T::write_u32(&mut buf, n);
+        self.write_all(&buf)
+    }
+
+    /// Writes a signed 32 bit integer to the underlying writer.
+    ///
+    /// # Errors
+    ///
+    /// This method returns the same errors as [`Write::write_all`].
+    ///
+    /// [`Write::write_all`]: https://doc.rust-lang.org/std/io/trait.Write.html#method.write_all
+    #[inline]
+    fn write_i32<T: ByteOrder>(&mut self, n: i32) -> Result<()> {
+        let mut buf = [0; 4];
+        T::write_i32(&mut buf, n);
+        self.write_all(&buf)
+    }
+
+    /// Writes an unsigned 64 bit integer to the underlying writer.
+    ///
+    /// # Errors
+    ///
+    /// This method returns the same errors as [`Write::write_all`].
+    ///
+    /// [`Write::write_all`]: https://doc.rust-lang.org/std/io/trait.Write.html#method.write_all
+    #[inline]
+    fn write_u64<T: ByteOrder>(&mut self, n: u64) -> Result<()> {
+        let mut buf = [0; 8];
+        T::write_u64(&mut buf, n);
+        self.write_all(&buf)
+    }
+
+    /// Writes a signed 64 bit integer to the underlying writer.
+    ///
+    /// # Errors
+    ///
+    /// This method returns the same errors as [`Write::write_all`].
+    ///
+    /// [`Write::write_all`]: https://doc.rust-lang.org/std/io/trait.Write.html#method.write_all
+    #[inline]
+    fn write_i64<T: ByteOrder>(&mut self, n: i64) -> Result<()> {
+        let mut buf = [0; 8];
+        T::write_i64(&mut buf, n);
+        self.write_all(&buf)
+    }
+
+    /// Writes an unsigned 128 bit integer to the underlying writer.
+    #[cfg(feature = "i128")]
+    #[inline]
+    fn write_u128<T: ByteOrder>(&mut self, n: u128) -> Result<()> {
+        let mut buf = [0; 16];
+        T::write_u128(&mut buf, n);
+        self.write_all(&buf)
+    }
+
+    /// Writes a signed 128 bit integer to the underlying writer.
+    #[cfg(feature = "i128")]
+    #[inline]
+    fn write_i128<T: ByteOrder>(&mut self, n: i128) -> Result<()> {
+        let mut buf = [0; 16];
+        T::write_i128(&mut buf, n);
+        self.write_all(&buf)
+    }
+
+    /// Writes an unsigned n-bytes integer to the underlying writer.
+    ///
+    /// # Errors
+    ///
+    /// This method returns the same errors as [`Write::write_all`].
+    ///
+    /// [`Write::write_all`]: https://doc.rust-lang.org/std/io/trait.Write.html#method.write_all
+    ///
+    /// # Panics
+    ///
+    /// If the given integer is not representable in the given number of bytes,
+    /// this method panics. If `nbytes > 8`, this method panics.
+    #[inline]
+    fn write_uint<T: ByteOrder>(
+        &mut self,
+        n: u64,
+        nbytes: usize,
+    ) -> Result<()> {
+        let mut buf = [0; 8];
+        T::write_uint(&mut buf, n, nbytes);
+        self.write_all(&buf[0..nbytes])
+    }
+
+    /// Writes a signed n-bytes integer to the underlying writer.
+    ///
+    /// # Errors
+    ///
+    /// This method returns the same errors as [`Write::write_all`].
+    ///
+    /// [`Write::write_all`]: https://doc.rust-lang.org/std/io/trait.Write.html#method.write_all
+    ///
+    /// # Panics
+    ///
+    /// If the given integer is not representable in the given number of bytes,
+    /// this method panics. If `nbytes > 8`, this method panics.
+    #[inline]
+    fn write_int<T: ByteOrder>(
+        &mut self,
+        n: i64,
+        nbytes: usize,
+    ) -> Result<()> {
+        let mut buf = [0; 8];
+        T::write_int(&mut buf, n, nbytes);
+        self.write_all(&buf[0..nbytes])
+    }
+
+    /// Writes an unsigned n-bytes integer to the underlying writer.
+    ///
+    /// If the given integer is not representable in the given number of bytes,
+    /// this method panics. If `nbytes > 16`, this method panics.
+    #[cfg(feature = "i128")]
+    #[inline]
+    fn write_uint128<T: ByteOrder>(
+        &mut self,
+        n: u128,
+        nbytes: usize,
+    ) -> Result<()> {
+        let mut buf = [0; 16];
+        T::write_uint128(&mut buf, n, nbytes);
+        self.write_all(&buf[0..nbytes])
+    }
+
+    /// Writes a signed n-bytes integer to the underlying writer.
+    ///
+    /// If the given integer is not representable in the given number of bytes,
+    /// this method panics. If `nbytes > 16`, this method panics.
+    #[cfg(feature = "i128")]
+    #[inline]
+    fn write_int128<T: ByteOrder>(
+        &mut self,
+        n: i128,
+        nbytes: usize,
+    ) -> Result<()> {
+        let mut buf = [0; 16];
+        T::write_int128(&mut buf, n, nbytes);
+        self.write_all(&buf[0..nbytes])
+    }
+
+    /// Writes a IEEE754 single-precision (4 bytes) floating point number to
+    /// the underlying writer.
+    ///
+    /// # Errors
+    ///
+    /// This method returns the same errors as [`Write::write_all`].
+    ///
+    /// [`Write::write_all`]: https://doc.rust-lang.org/std/io/trait.Write.html#method.write_all
+    #[inline]
+    fn write_f32<T: ByteOrder>(&mut self, n: f32) -> Result<()> {
+        let mut buf = [0; 4];
+        T::write_f32(&mut buf, n);
+        self.write_all(&buf)
+    }
+
+    /// Writes a IEEE754 double-precision (8 bytes) floating point number to
+    /// the underlying writer.
+    #[inline]
+    fn write_f64<T: ByteOrder>(&mut self, n: f64) -> Result<()> {
+        let mut buf = [0; 8];
+        T::write_f64(&mut buf, n);
+        self.write_all(&buf)
+    }
+}
+
+/// All types that implement `Write` get methods defined in `WriteBytesExt`
+/// for free.
+impl<W: io::Write + ?Sized> WriteBytesExt for W {}
+
+/// Convert a slice of T (where T is plain old data) to its mutable binary
+/// representation.
+///
+/// This function is wildly unsafe because it permits arbitrary modification of
+/// the binary representation of any `Copy` type. Use with care.
+unsafe fn slice_to_u8_mut<T: Copy>(slice: &mut [T]) -> &mut [u8] {
+    use std::mem::size_of;
+
+    let len = size_of::<T>() * slice.len();
+    slice::from_raw_parts_mut(slice.as_mut_ptr() as *mut u8, len)
+}
new file mode 100644
--- /dev/null
+++ b/third_party/rust/byteorder-1.1.0/src/lib.rs
@@ -0,0 +1,3191 @@
+/*!
+This crate provides convenience methods for encoding and decoding numbers
+in either big-endian or little-endian order.
+
+The organization of the crate is pretty simple. A trait, `ByteOrder`, specifies
+byte conversion methods for each type of number in Rust (sans numbers that have
+a platform dependent size like `usize` and `isize`). Two types, `BigEndian`
+and `LittleEndian` implement these methods. Finally, `ReadBytesExt` and
+`WriteBytesExt` provide convenience methods available to all types that
+implement `Read` and `Write`.
+
+# Examples
+
+Read unsigned 16 bit big-endian integers from a `Read` type:
+
+```rust
+use std::io::Cursor;
+use byteorder::{BigEndian, ReadBytesExt};
+
+let mut rdr = Cursor::new(vec![2, 5, 3, 0]);
+// Note that we use type parameters to indicate which kind of byte order
+// we want!
+assert_eq!(517, rdr.read_u16::<BigEndian>().unwrap());
+assert_eq!(768, rdr.read_u16::<BigEndian>().unwrap());
+```
+
+Write unsigned 16 bit little-endian integers to a `Write` type:
+
+```rust
+use byteorder::{LittleEndian, WriteBytesExt};
+
+let mut wtr = vec![];
+wtr.write_u16::<LittleEndian>(517).unwrap();
+wtr.write_u16::<LittleEndian>(768).unwrap();
+assert_eq!(wtr, vec![5, 2, 0, 3]);
+```
+*/
+
+#![deny(missing_docs)]
+#![cfg_attr(not(feature = "std"), no_std)]
+#![cfg_attr(feature = "i128", feature(i128_type))]
+#![cfg_attr(all(feature = "i128", test), feature(i128))]
+#![doc(html_root_url = "https://docs.rs/byteorder/1.0.0")]
+
+#[cfg(feature = "std")]
+extern crate core;
+
+use core::fmt::Debug;
+use core::hash::Hash;
+use core::mem::transmute;
+use core::ptr::copy_nonoverlapping;
+
+#[cfg(feature = "std")]
+pub use io::{ReadBytesExt, WriteBytesExt};
+
+#[cfg(feature = "std")]
+mod io;
+
+#[inline]
+fn extend_sign(val: u64, nbytes: usize) -> i64 {
+    let shift = (8 - nbytes) * 8;
+    (val << shift) as i64 >> shift
+}
+
+#[cfg(feature = "i128")]
+#[inline]
+fn extend_sign128(val: u128, nbytes: usize) -> i128 {
+    let shift = (16 - nbytes) * 8;
+    (val << shift) as i128 >> shift
+}
+
+#[inline]
+fn unextend_sign(val: i64, nbytes: usize) -> u64 {
+    let shift = (8 - nbytes) * 8;
+    (val << shift) as u64 >> shift
+}
+
+#[cfg(feature = "i128")]
+#[inline]
+fn unextend_sign128(val: i128, nbytes: usize) -> u128 {
+    let shift = (16 - nbytes) * 8;
+    (val << shift) as u128 >> shift
+}
+
+#[inline]
+fn pack_size(n: u64) -> usize {
+    if n < 1 << 8 {
+        1
+    } else if n < 1 << 16 {
+        2
+    } else if n < 1 << 24 {
+        3
+    } else if n < 1 << 32 {
+        4
+    } else if n < 1 << 40 {
+        5
+    } else if n < 1 << 48 {
+        6
+    } else if n < 1 << 56 {
+        7
+    } else {
+        8
+    }
+}
+
+#[cfg(feature = "i128")]
+#[inline]
+fn pack_size128(n: u128) -> usize {
+    if n < 1 << 8 {
+        1
+    } else if n < 1 << 16 {
+        2
+    } else if n < 1 << 24 {
+        3
+    } else if n < 1 << 32 {
+        4
+    } else if n < 1 << 40 {
+        5
+    } else if n < 1 << 48 {
+        6
+    } else if n < 1 << 56 {
+        7
+    } else if n < 1 << 64 {
+        8
+    } else if n < 1 << 72 {
+        9
+    } else if n < 1 << 80 {
+        10
+    } else if n < 1 << 88 {
+        11
+    } else if n < 1 << 96 {
+        12
+    } else if n < 1 << 104 {
+        13
+    } else if n < 1 << 112 {
+        14
+    } else if n < 1 << 120 {
+        15
+    } else {
+        16
+    }
+}
+
+mod private {
+    /// Sealed stops crates other than byteorder from implementing any traits
+    /// that use it.
+    pub trait Sealed{}
+    impl Sealed for super::LittleEndian {}
+    impl Sealed for super::BigEndian {}
+}
+
+/// ByteOrder describes types that can serialize integers as bytes.
+///
+/// Note that `Self` does not appear anywhere in this trait's definition!
+/// Therefore, in order to use it, you'll need to use syntax like
+/// `T::read_u16(&[0, 1])` where `T` implements `ByteOrder`.
+///
+/// This crate provides two types that implement `ByteOrder`: `BigEndian`
+/// and `LittleEndian`.
+/// This trait is sealed and cannot be implemented for callers to avoid
+/// breaking backwards compatibility when adding new derived traits.
+///
+/// # Examples
+///
+/// Write and read `u32` numbers in little endian order:
+///
+/// ```rust
+/// use byteorder::{ByteOrder, LittleEndian};
+///
+/// let mut buf = [0; 4];
+/// LittleEndian::write_u32(&mut buf, 1_000_000);
+/// assert_eq!(1_000_000, LittleEndian::read_u32(&buf));
+/// ```
+///
+/// Write and read `i16` numbers in big endian order:
+///
+/// ```rust
+/// use byteorder::{ByteOrder, BigEndian};
+///
+/// let mut buf = [0; 2];
+/// BigEndian::write_i16(&mut buf, -50_000);
+/// assert_eq!(-50_000, BigEndian::read_i16(&buf));
+/// ```
+pub trait ByteOrder
+    : Clone + Copy + Debug + Default + Eq + Hash + Ord + PartialEq + PartialOrd
+    + private::Sealed
+{
+    /// Reads an unsigned 16 bit integer from `buf`.
+    ///
+    /// # Panics
+    ///
+    /// Panics when `buf.len() < 2`.
+    fn read_u16(buf: &[u8]) -> u16;
+
+    /// Reads an unsigned 24 bit integer from `buf`, stored in u32.
+    ///
+    /// # Panics
+    ///
+    /// Panics when `buf.len() < 3`.
+    ///
+    /// # Examples
+    ///
+    /// Write and read 24 bit `u32` numbers in little endian order:
+    ///
+    /// ```rust
+    /// use byteorder::{ByteOrder, LittleEndian};
+    ///
+    /// let mut buf = [0; 3];
+    /// LittleEndian::write_u24(&mut buf, 1_000_000);
+    /// assert_eq!(1_000_000, LittleEndian::read_u24(&buf));
+    /// ```
+    fn read_u24(buf: &[u8]) -> u32 {
+        Self::read_uint(buf, 3) as u32
+    }
+
+    /// Reads an unsigned 32 bit integer from `buf`.
+    ///
+    /// # Panics
+    ///
+    /// Panics when `buf.len() < 4`.
+    ///
+    /// # Examples
+    ///
+    /// Write and read `u32` numbers in little endian order:
+    ///
+    /// ```rust
+    /// use byteorder::{ByteOrder, LittleEndian};
+    ///
+    /// let mut buf = [0; 4];
+    /// LittleEndian::write_u32(&mut buf, 1_000_000);
+    /// assert_eq!(1_000_000, LittleEndian::read_u32(&buf));
+    /// ```
+    fn read_u32(buf: &[u8]) -> u32;
+
+    /// Reads an unsigned 64 bit integer from `buf`.
+    ///
+    /// # Panics
+    ///
+    /// Panics when `buf.len() < 8`.
+    ///
+    /// # Examples
+    ///
+    /// Write and read `u64` numbers in little endian order:
+    ///
+    /// ```rust
+    /// use byteorder::{ByteOrder, LittleEndian};
+    ///
+    /// let mut buf = [0; 8];
+    /// LittleEndian::write_u64(&mut buf, 1_000_000);
+    /// assert_eq!(1_000_000, LittleEndian::read_u64(&buf));
+    /// ```
+    fn read_u64(buf: &[u8]) -> u64;
+
+    /// Reads an unsigned 128 bit integer from `buf`.
+    ///
+    /// # Panics
+    ///
+    /// Panics when `buf.len() < 16`.
+    ///
+    /// # Examples
+    ///
+    /// Write and read `u128` numbers in little endian order:
+    ///
+    /// ```rust
+    /// use byteorder::{ByteOrder, LittleEndian};
+    ///
+    /// let mut buf = [0; 16];
+    /// LittleEndian::write_u128(&mut buf, 1_000_000);
+    /// assert_eq!(1_000_000, LittleEndian::read_u128(&buf));
+    /// ```
+    #[cfg(feature = "i128")]
+    fn read_u128(buf: &[u8]) -> u128;
+
+    /// Reads an unsigned n-bytes integer from `buf`.
+    ///
+    /// # Panics
+    ///
+    /// Panics when `nbytes < 1` or `nbytes > 8` or
+    /// `buf.len() < nbytes`
+    ///
+    /// # Examples
+    ///
+    /// Write and read an n-byte number in little endian order:
+    ///
+    /// ```rust
+    /// use byteorder::{ByteOrder, LittleEndian};
+    ///
+    /// let mut buf = [0; 3];
+    /// LittleEndian::write_uint(&mut buf, 1_000_000, 3);
+    /// assert_eq!(1_000_000, LittleEndian::read_uint(&buf, 3));
+    /// ```
+    fn read_uint(buf: &[u8], nbytes: usize) -> u64;
+
+    /// Reads an unsigned n-bytes integer from `buf`.
+    ///
+    /// # Panics
+    ///
+    /// Panics when `nbytes < 1` or `nbytes > 16` or
+    /// `buf.len() < nbytes`
+    ///
+    /// # Examples
+    ///
+    /// Write and read an n-byte number in little endian order:
+    ///
+    /// ```rust
+    /// use byteorder::{ByteOrder, LittleEndian};
+    ///
+    /// let mut buf = [0; 3];
+    /// LittleEndian::write_uint128(&mut buf, 1_000_000, 3);
+    /// assert_eq!(1_000_000, LittleEndian::read_uint128(&buf, 3));
+    /// ```
+    #[cfg(feature = "i128")]
+    fn read_uint128(buf: &[u8], nbytes: usize) -> u128;
+
+    /// Writes an unsigned 16 bit integer `n` to `buf`.
+    ///
+    /// # Panics
+    ///
+    /// Panics when `buf.len() < 2`.
+    ///
+    /// # Examples
+    ///
+    /// Write and read `u16` numbers in little endian order:
+    ///
+    /// ```rust
+    /// use byteorder::{ByteOrder, LittleEndian};
+    ///
+    /// let mut buf = [0; 2];
+    /// LittleEndian::write_u16(&mut buf, 1_000_000);
+    /// assert_eq!(1_000_000, LittleEndian::read_u16(&buf));
+    /// ```
+    fn write_u16(buf: &mut [u8], n: u16);
+
+    /// Writes an unsigned 24 bit integer `n` to `buf`, stored in u32.
+    ///
+    /// # Panics
+    ///
+    /// Panics when `buf.len() < 3`.
+    ///
+    /// # Examples
+    ///
+    /// Write and read 24 bit `u32` numbers in little endian order:
+    ///
+    /// ```rust
+    /// use byteorder::{ByteOrder, LittleEndian};
+    ///
+    /// let mut buf = [0; 3];
+    /// LittleEndian::write_u24(&mut buf, 1_000_000);
+    /// assert_eq!(1_000_000, LittleEndian::read_u24(&buf));
+    /// ```
+    fn write_u24(buf: &mut [u8], n: u32) {
+        Self::write_uint(buf, n as u64, 3)
+    }
+
+    /// Writes an unsigned 32 bit integer `n` to `buf`.
+    ///
+    /// # Panics
+    ///
+    /// Panics when `buf.len() < 4`.
+    ///
+    /// # Examples
+    ///
+    /// Write and read `u32` numbers in little endian order:
+    ///
+    /// ```rust
+    /// use byteorder::{ByteOrder, LittleEndian};
+    ///
+    /// let mut buf = [0; 4];
+    /// LittleEndian::write_u32(&mut buf, 1_000_000);
+    /// assert_eq!(1_000_000, LittleEndian::read_u32(&buf));
+    /// ```
+    fn write_u32(buf: &mut [u8], n: u32);
+
+    /// Writes an unsigned 64 bit integer `n` to `buf`.
+    ///
+    /// # Panics
+    ///
+    /// Panics when `buf.len() < 8`.
+    ///
+    /// # Examples
+    ///
+    /// Write and read `u64` numbers in little endian order:
+    ///
+    /// ```rust
+    /// use byteorder::{ByteOrder, LittleEndian};
+    ///
+    /// let mut buf = [0; 8];
+    /// LittleEndian::write_u64(&mut buf, 1_000_000);
+    /// assert_eq!(1_000_000, LittleEndian::read_u64(&buf));
+    /// ```
+    fn write_u64(buf: &mut [u8], n: u64);
+
+    /// Writes an unsigned 128 bit integer `n` to `buf`.
+    ///
+    /// # Panics
+    ///
+    /// Panics when `buf.len() < 16`.
+    ///
+    /// # Examples
+    ///
+    /// Write and read `u128` numbers in little endian order:
+    ///
+    /// ```rust
+    /// use byteorder::{ByteOrder, LittleEndian};
+    ///
+    /// let mut buf = [0; 16];
+    /// LittleEndian::write_u128(&mut buf, 1_000_000);
+    /// assert_eq!(1_000_000, LittleEndian::read_u128(&buf));
+    /// ```
+    #[cfg(feature = "i128")]
+    fn write_u128(buf: &mut [u8], n: u128);
+
+    /// Writes an unsigned integer `n` to `buf` using only `nbytes`.
+    ///
+    /// # Panics
+    ///
+    /// If `n` is not representable in `nbytes`, or if `nbytes` is `> 8`, then
+    /// this method panics.
+    ///
+    /// # Examples
+    ///
+    /// Write and read an n-byte number in little endian order:
+    ///
+    /// ```rust
+    /// use byteorder::{ByteOrder, LittleEndian};
+    ///
+    /// let mut buf = [0; 3];
+    /// LittleEndian::write_uint(&mut buf, 1_000_000, 3);
+    /// assert_eq!(1_000_000, LittleEndian::read_uint(&buf, 3));
+    /// ```
+    fn write_uint(buf: &mut [u8], n: u64, nbytes: usize);
+
+    /// Writes an unsigned integer `n` to `buf` using only `nbytes`.
+    ///
+    /// # Panics
+    ///
+    /// If `n` is not representable in `nbytes`, or if `nbytes` is `> 16`, then
+    /// this method panics.
+    ///
+    /// # Examples
+    ///
+    /// Write and read an n-byte number in little endian order:
+    ///
+    /// ```rust
+    /// use byteorder::{ByteOrder, LittleEndian};
+    ///
+    /// let mut buf = [0; 3];
+    /// LittleEndian::write_uint128(&mut buf, 1_000_000, 3);
+    /// assert_eq!(1_000_000, LittleEndian::read_uint128(&buf, 3));
+    /// ```
+    #[cfg(feature = "i128")]
+    fn write_uint128(buf: &mut [u8], n: u128, nbytes: usize);
+
+    /// Reads a signed 16 bit integer from `buf`.
+    ///
+    /// # Panics
+    ///
+    /// Panics when `buf.len() < 2`.
+    ///
+    /// # Examples
+    ///
+    /// Write and read `i16` numbers in little endian order:
+    ///
+    /// ```rust
+    /// use byteorder::{ByteOrder, LittleEndian};
+    ///
+    /// let mut buf = [0; 2];
+    /// LittleEndian::write_i16(&mut buf, -1_000);
+    /// assert_eq!(-1_000, LittleEndian::read_i16(&buf));
+    /// ```
+    #[inline]
+    fn read_i16(buf: &[u8]) -> i16 {
+        Self::read_u16(buf) as i16
+    }
+
+    /// Reads a signed 24 bit integer from `buf`, stored in i32.
+    ///
+    /// # Panics
+    ///
+    /// Panics when `buf.len() < 3`.
+    ///
+    /// # Examples
+    ///
+    /// Write and read 24 bit `i32` numbers in little endian order:
+    ///
+    /// ```rust
+    /// use byteorder::{ByteOrder, LittleEndian};
+    ///
+    /// let mut buf = [0; 3];
+    /// LittleEndian::write_i24(&mut buf, -1_000_000);
+    /// assert_eq!(-1_000_000, LittleEndian::read_i24(&buf));
+    /// ```
+    #[inline]
+    fn read_i24(buf: &[u8]) -> i32 {
+        Self::read_int(buf, 3) as i32
+    }
+
+    /// Reads a signed 32 bit integer from `buf`.
+    ///
+    /// # Panics
+    ///
+    /// Panics when `buf.len() < 4`.
+    ///
+    /// # Examples
+    ///
+    /// Write and read `i32` numbers in little endian order:
+    ///
+    /// ```rust
+    /// use byteorder::{ByteOrder, LittleEndian};
+    ///
+    /// let mut buf = [0; 4];
+    /// LittleEndian::write_i32(&mut buf, -1_000_000);
+    /// assert_eq!(-1_000_000, LittleEndian::read_i32(&buf));
+    /// ```
+    #[inline]
+    fn read_i32(buf: &[u8]) -> i32 {
+        Self::read_u32(buf) as i32
+    }
+
+    /// Reads a signed 64 bit integer from `buf`.
+    ///
+    /// # Panics
+    ///
+    /// Panics when `buf.len() < 8`.
+    ///
+    /// # Examples
+    ///
+    /// Write and read `i64` numbers in little endian order:
+    ///
+    /// ```rust
+    /// use byteorder::{ByteOrder, LittleEndian};
+    ///
+    /// let mut buf = [0; 8];
+    /// LittleEndian::write_i64(&mut buf, -1_000_000_000);
+    /// assert_eq!(-1_000_000_000, LittleEndian::read_i64(&buf));
+    /// ```
+    #[inline]
+    fn read_i64(buf: &[u8]) -> i64 {
+        Self::read_u64(buf) as i64
+    }
+
+    /// Reads a signed 128 bit integer from `buf`.
+    ///
+    /// # Panics
+    ///
+    /// Panics when `buf.len() < 16`.
+    ///
+    /// # Examples
+    ///
+    /// Write and read `i128` numbers in little endian order:
+    ///
+    /// ```rust
+    /// use byteorder::{ByteOrder, LittleEndian};
+    ///
+    /// let mut buf = [0; 16];
+    /// LittleEndian::write_i128(&mut buf, -1_000_000_000);
+    /// assert_eq!(-1_000_000_000, LittleEndian::read_i128(&buf));
+    /// ```
+    #[cfg(feature = "i128")]
+    #[inline]
+    fn read_i128(buf: &[u8]) -> i128 {
+        Self::read_u128(buf) as i128
+    }
+
+    /// Reads a signed n-bytes integer from `buf`.
+    ///
+    /// # Panics
+    ///
+    /// Panics when `nbytes < 1` or `nbytes > 8` or
+    /// `buf.len() < nbytes`
+    ///
+    /// # Examples
+    ///
+    /// Write and read n-length signed numbers in little endian order:
+    ///
+    /// ```rust
+    /// use byteorder::{ByteOrder, LittleEndian};
+    ///
+    /// let mut buf = [0; 3];
+    /// LittleEndian::write_int(&mut buf, -1_000, 3);
+    /// assert_eq!(-1_000, LittleEndian::read_int(&buf, 3));
+    /// ```
+    #[inline]
+    fn read_int(buf: &[u8], nbytes: usize) -> i64 {
+        extend_sign(Self::read_uint(buf, nbytes), nbytes)
+    }
+
+    /// Reads a signed n-bytes integer from `buf`.
+    ///
+    /// # Panics
+    ///
+    /// Panics when `nbytes < 1` or `nbytes > 16` or
+    /// `buf.len() < nbytes`
+    ///
+    /// # Examples
+    ///
+    /// Write and read n-length signed numbers in little endian order:
+    ///
+    /// ```rust
+    /// use byteorder::{ByteOrder, LittleEndian};
+    ///
+    /// let mut buf = [0; 3];
+    /// LittleEndian::write_int128(&mut buf, -1_000, 3);
+    /// assert_eq!(-1_000, LittleEndian::read_int128(&buf, 3));
+    /// ```
+    #[cfg(feature = "i128")]
+    #[inline]
+    fn read_int128(buf: &[u8], nbytes: usize) -> i128 {
+        extend_sign128(Self::read_uint128(buf, nbytes), nbytes)
+    }
+
+    /// Reads a IEEE754 single-precision (4 bytes) floating point number.
+    ///
+    /// The return value is always defined; signaling NaN's may be turned into
+    /// quiet NaN's.
+    ///
+    /// # Panics
+    ///
+    /// Panics when `buf.len() < 4`.
+    ///
+    /// # Examples
+    ///
+    /// Write and read `f32` numbers in little endian order:
+    ///
+    /// ```rust
+    /// use byteorder::{ByteOrder, LittleEndian};
+    ///
+    /// let e = 2.71828;
+    /// let mut buf = [0; 4];
+    /// LittleEndian::write_f32(&mut buf, e);
+    /// assert_eq!(e, LittleEndian::read_f32(&buf));
+    /// ```
+    #[inline]
+    fn read_f32(buf: &[u8]) -> f32 {
+        safe_u32_bits_to_f32(Self::read_u32(buf))
+    }
+
+    /// Reads a IEEE754 double-precision (8 bytes) floating point number.
+    ///
+    /// The return value is always defined; signaling NaN's may be turned into
+    /// quiet NaN's.
+    ///
+    /// # Panics
+    ///
+    /// Panics when `buf.len() < 8`.
+    ///
+    /// # Examples
+    ///
+    /// Write and read `f64` numbers in little endian order:
+    ///
+    /// ```rust
+    /// use byteorder::{ByteOrder, LittleEndian};
+    ///
+    /// let phi = 1.6180339887;
+    /// let mut buf = [0; 8];
+    /// LittleEndian::write_f64(&mut buf, phi);
+    /// assert_eq!(phi, LittleEndian::read_f64(&buf));
+    /// ```
+    #[inline]
+    fn read_f64(buf: &[u8]) -> f64 {
+        safe_u64_bits_to_f64(Self::read_u64(buf))
+    }
+
+    /// Writes a signed 16 bit integer `n` to `buf`.
+    ///
+    /// # Panics
+    ///
+    /// Panics when `buf.len() < 2`.
+    ///
+    /// # Examples
+    ///
+    /// Write and read `i16` numbers in little endian order:
+    ///
+    /// ```rust
+    /// use byteorder::{ByteOrder, LittleEndian};
+    ///
+    /// let mut buf = [0; 2];
+    /// LittleEndian::write_i16(&mut buf, -1_000);
+    /// assert_eq!(-1_000, LittleEndian::read_i16(&buf));
+    /// ```
+    #[inline]
+    fn write_i16(buf: &mut [u8], n: i16) {
+        Self::write_u16(buf, n as u16)
+    }
+
+    /// Writes a signed 24 bit integer `n` to `buf`, stored in i32.
+    ///
+    /// # Panics
+    ///
+    /// Panics when `buf.len() < 3`.
+    ///
+    /// # Examples
+    ///
+    /// Write and read 24 bit `i32` numbers in little endian order:
+    ///
+    /// ```rust
+    /// use byteorder::{ByteOrder, LittleEndian};
+    ///
+    /// let mut buf = [0; 3];
+    /// LittleEndian::write_i24(&mut buf, -1_000_000);
+    /// assert_eq!(-1_000_000, LittleEndian::read_i24(&buf));
+    /// ```
+    #[inline]
+    fn write_i24(buf: &mut [u8], n: i32) {
+        Self::write_int(buf, n as i64, 3)
+    }
+
+    /// Writes a signed 32 bit integer `n` to `buf`.
+    ///
+    /// # Panics
+    ///
+    /// Panics when `buf.len() < 4`.
+    ///
+    /// # Examples
+    ///
+    /// Write and read `i32` numbers in little endian order:
+    ///
+    /// ```rust
+    /// use byteorder::{ByteOrder, LittleEndian};
+    ///
+    /// let mut buf = [0; 4];
+    /// LittleEndian::write_i32(&mut buf, -1_000_000);
+    /// assert_eq!(-1_000_000, LittleEndian::read_i32(&buf));
+    /// ```
+    #[inline]
+    fn write_i32(buf: &mut [u8], n: i32) {
+        Self::write_u32(buf, n as u32)
+    }
+
+    /// Writes a signed 64 bit integer `n` to `buf`.
+    ///
+    /// # Panics
+    ///
+    /// Panics when `buf.len() < 8`.
+    ///
+    /// # Examples
+    ///
+    /// Write and read `i64` numbers in little endian order:
+    ///
+    /// ```rust
+    /// use byteorder::{ByteOrder, LittleEndian};
+    ///
+    /// let mut buf = [0; 8];
+    /// LittleEndian::write_i64(&mut buf, -1_000_000_000);
+    /// assert_eq!(-1_000_000_000, LittleEndian::read_i64(&buf));
+    /// ```
+    #[inline]
+    fn write_i64(buf: &mut [u8], n: i64) {
+        Self::write_u64(buf, n as u64)
+    }
+
+    /// Writes a signed 128 bit integer `n` to `buf`.
+    ///
+    /// # Panics
+    ///
+    /// Panics when `buf.len() < 16`.
+    ///
+    /// # Examples
+    ///
+    /// Write and read n-byte `i128` numbers in little endian order:
+    ///
+    /// ```rust
+    /// use byteorder::{ByteOrder, LittleEndian};
+    ///
+    /// let mut buf = [0; 16];
+    /// LittleEndian::write_i128(&mut buf, -1_000_000_000);
+    /// assert_eq!(-1_000_000_000, LittleEndian::read_i128(&buf));
+    /// ```
+    #[cfg(feature = "i128")]
+    #[inline]
+    fn write_i128(buf: &mut [u8], n: i128) {
+        Self::write_u128(buf, n as u128)
+    }
+
+    /// Writes a signed integer `n` to `buf` using only `nbytes`.
+    ///
+    /// # Panics
+    ///
+    /// If `n` is not representable in `nbytes`, or if `nbytes` is `> 8`, then
+    /// this method panics.
+    ///
+    /// # Examples
+    ///
+    /// Write and read an n-byte number in little endian order:
+    ///
+    /// ```rust
+    /// use byteorder::{ByteOrder, LittleEndian};
+    ///
+    /// let mut buf = [0; 3];
+    /// LittleEndian::write_int(&mut buf, -1_000, 3);
+    /// assert_eq!(-1_000, LittleEndian::read_int(&buf, 3));
+    /// ```
+    #[inline]
+    fn write_int(buf: &mut [u8], n: i64, nbytes: usize) {
+        Self::write_uint(buf, unextend_sign(n, nbytes), nbytes)
+    }
+
+    /// Writes a signed integer `n` to `buf` using only `nbytes`.
+    ///
+    /// # Panics
+    ///
+    /// If `n` is not representable in `nbytes`, or if `nbytes` is `> 16`, then
+    /// this method panics.
+    ///
+    /// # Examples
+    ///
+    /// Write and read n-length signed numbers in little endian order:
+    ///
+    /// ```rust
+    /// use byteorder::{ByteOrder, LittleEndian};
+    ///
+    /// let mut buf = [0; 3];
+    /// LittleEndian::write_int128(&mut buf, -1_000, 3);
+    /// assert_eq!(-1_000, LittleEndian::read_int128(&buf, 3));
+    /// ```
+    #[cfg(feature = "i128")]
+    #[inline]
+    fn write_int128(buf: &mut [u8], n: i128, nbytes: usize) {
+        Self::write_uint128(buf, unextend_sign128(n, nbytes), nbytes)
+    }
+
+    /// Writes a IEEE754 single-precision (4 bytes) floating point number.
+    ///
+    /// # Panics
+    ///
+    /// Panics when `buf.len() < 4`.
+    ///
+    /// # Examples
+    ///
+    /// Write and read `f32` numbers in little endian order:
+    ///
+    /// ```rust
+    /// use byteorder::{ByteOrder, LittleEndian};
+    ///
+    /// let e = 2.71828;
+    /// let mut buf = [0; 4];
+    /// LittleEndian::write_f32(&mut buf, e);
+    /// assert_eq!(e, LittleEndian::read_f32(&buf));
+    /// ```
+    #[inline]
+    fn write_f32(buf: &mut [u8], n: f32) {
+        Self::write_u32(buf, unsafe { transmute(n) })
+    }
+
+    /// Writes a IEEE754 double-precision (8 bytes) floating point number.
+    ///
+    /// # Panics
+    ///
+    /// Panics when `buf.len() < 8`.
+    ///
+    /// # Examples
+    ///
+    /// Write and read `f64` numbers in little endian order:
+    ///
+    /// ```rust
+    /// use byteorder::{ByteOrder, LittleEndian};
+    ///
+    /// let phi = 1.6180339887;
+    /// let mut buf = [0; 8];
+    /// LittleEndian::write_f64(&mut buf, phi);
+    /// assert_eq!(phi, LittleEndian::read_f64(&buf));
+    /// ```
+    #[inline]
+    fn write_f64(buf: &mut [u8], n: f64) {
+        Self::write_u64(buf, unsafe { transmute(n) })
+    }
+
+    /// Reads unsigned 16 bit integers from `src` into `dst`.
+    ///
+    /// # Panics
+    ///
+    /// Panics when `src.len() != 2*dst.len()`.
+    ///
+    /// # Examples
+    ///
+    /// Write and read `u16` numbers in little endian order:
+    ///
+    /// ```rust
+    /// use byteorder::{ByteOrder, LittleEndian};
+    ///
+    /// let mut bytes = [0; 8];
+    /// let numbers_given = [1, 2, 0xf00f, 0xffee];
+    /// LittleEndian::write_u16_into(&numbers_given, &mut bytes);
+    ///
+    /// let mut numbers_got = [0; 4];
+    /// LittleEndian::read_u16_into(&bytes, &mut numbers_got);
+    /// assert_eq!(numbers_given, numbers_got);
+    /// ```
+    fn read_u16_into(src: &[u8], dst: &mut [u16]);
+
+    /// Reads unsigned 32 bit integers from `src` into `dst`.
+    ///
+    /// # Panics
+    ///
+    /// Panics when `src.len() != 4*dst.len()`.
+    ///
+    /// # Examples
+    ///
+    /// Write and read `u32` numbers in little endian order:
+    ///
+    /// ```rust
+    /// use byteorder::{ByteOrder, LittleEndian};
+    ///
+    /// let mut bytes = [0; 16];
+    /// let numbers_given = [1, 2, 0xf00f, 0xffee];
+    /// LittleEndian::write_u32_into(&numbers_given, &mut bytes);
+    ///
+    /// let mut numbers_got = [0; 4];
+    /// LittleEndian::read_u32_into(&bytes, &mut numbers_got);
+    /// assert_eq!(numbers_given, numbers_got);
+    /// ```
+    fn read_u32_into(src: &[u8], dst: &mut [u32]);
+
+    /// Reads unsigned 64 bit integers from `src` into `dst`.
+    ///
+    /// # Panics
+    ///
+    /// Panics when `src.len() != 8*dst.len()`.
+    ///
+    /// # Examples
+    ///
+    /// Write and read `u64` numbers in little endian order:
+    ///
+    /// ```rust
+    /// use byteorder::{ByteOrder, LittleEndian};
+    ///
+    /// let mut bytes = [0; 32];
+    /// let numbers_given = [1, 2, 0xf00f, 0xffee];
+    /// LittleEndian::write_u64_into(&numbers_given, &mut bytes);
+    ///
+    /// let mut numbers_got = [0; 4];
+    /// LittleEndian::read_u64_into(&bytes, &mut numbers_got);
+    /// assert_eq!(numbers_given, numbers_got);
+    /// ```
+    fn read_u64_into(src: &[u8], dst: &mut [u64]);
+
+    /// Reads unsigned 128 bit integers from `src` into `dst`.
+    ///
+    /// # Panics
+    ///
+    /// Panics when `src.len() != 16*dst.len()`.
+    ///
+    /// # Examples
+    ///
+    /// Write and read `u128` numbers in little endian order:
+    ///
+    /// ```rust
+    /// use byteorder::{ByteOrder, LittleEndian};
+    ///
+    /// let mut bytes = [0; 64];
+    /// let numbers_given = [1, 2, 0xf00f, 0xffee];
+    /// LittleEndian::write_u128_into(&numbers_given, &mut bytes);
+    ///
+    /// let mut numbers_got = [0; 4];
+    /// LittleEndian::read_u128_into(&bytes, &mut numbers_got);
+    /// assert_eq!(numbers_given, numbers_got);
+    /// ```
+    #[cfg(feature = "i128")]
+    fn read_u128_into(src: &[u8], dst: &mut [u128]);
+
+    /// Reads signed 16 bit integers from `src` to `dst`.
+    ///
+    /// # Panics
+    ///
+    /// Panics when `buf.len() != 2*dst.len()`.
+    ///
+    /// # Examples
+    ///
+    /// Write and read `i16` numbers in little endian order:
+    ///
+    /// ```rust
+    /// use byteorder::{ByteOrder, LittleEndian};
+    ///
+    /// let mut bytes = [0; 8];
+    /// let numbers_given = [1, 2, 0xf00f, 0xffee];
+    /// LittleEndian::write_i16_into(&numbers_given, &mut bytes);
+    ///
+    /// let mut numbers_got = [0; 4];
+    /// LittleEndian::read_i16_into(&bytes, &mut numbers_got);
+    /// assert_eq!(numbers_given, numbers_got);
+    /// ```
+    #[inline]
+    fn read_i16_into(src: &[u8], dst: &mut [i16]) {
+        Self::read_u16_into(src, unsafe { transmute(dst) });
+    }
+
+    /// Reads signed 32 bit integers from `src` into `dst`.
+    ///
+    /// # Panics
+    ///
+    /// Panics when `src.len() != 4*dst.len()`.
+    ///
+    /// # Examples
+    ///
+    /// Write and read `i32` numbers in little endian order:
+    ///
+    /// ```rust
+    /// use byteorder::{ByteOrder, LittleEndian};
+    ///
+    /// let mut bytes = [0; 16];
+    /// let numbers_given = [1, 2, 0xf00f, 0xffee];
+    /// LittleEndian::write_i32_into(&numbers_given, &mut bytes);
+    ///
+    /// let mut numbers_got = [0; 4];
+    /// LittleEndian::read_i32_into(&bytes, &mut numbers_got);
+    /// assert_eq!(numbers_given, numbers_got);
+    /// ```
+    #[inline]
+    fn read_i32_into(src: &[u8], dst: &mut [i32]) {
+        Self::read_u32_into(src, unsafe { transmute(dst) });
+    }
+
+    /// Reads signed 64 bit integers from `src` into `dst`.
+    ///
+    /// # Panics
+    ///
+    /// Panics when `src.len() != 8*dst.len()`.
+    ///
+    /// # Examples
+    ///
+    /// Write and read `i64` numbers in little endian order:
+    ///
+    /// ```rust
+    /// use byteorder::{ByteOrder, LittleEndian};
+    ///
+    /// let mut bytes = [0; 32];
+    /// let numbers_given = [1, 2, 0xf00f, 0xffee];
+    /// LittleEndian::write_i64_into(&numbers_given, &mut bytes);
+    ///
+    /// let mut numbers_got = [0; 4];
+    /// LittleEndian::read_i64_into(&bytes, &mut numbers_got);
+    /// assert_eq!(numbers_given, numbers_got);
+    /// ```
+    #[inline]
+    fn read_i64_into(src: &[u8], dst: &mut [i64]) {
+        Self::read_u64_into(src, unsafe { transmute(dst) });
+    }
+
+    /// Reads signed 128 bit integers from `src` into `dst`.
+    ///
+    /// # Panics
+    ///
+    /// Panics when `src.len() != 16*dst.len()`.
+    ///
+    /// # Examples
+    ///
+    /// Write and read `i128` numbers in little endian order:
+    ///
+    /// ```rust
+    /// use byteorder::{ByteOrder, LittleEndian};
+    ///
+    /// let mut bytes = [0; 64];
+    /// let numbers_given = [1, 2, 0xf00f, 0xffee];
+    /// LittleEndian::write_i128_into(&numbers_given, &mut bytes);
+    ///
+    /// let mut numbers_got = [0; 4];
+    /// LittleEndian::read_i128_into(&bytes, &mut numbers_got);
+    /// assert_eq!(numbers_given, numbers_got);
+    /// ```
+    #[cfg(feature = "i128")]
+    #[inline]
+    fn read_i128_into(src: &[u8], dst: &mut [i128]) {
+        Self::read_u128_into(src, unsafe { transmute(dst) });
+    }
+
+    /// Reads IEEE754 single-precision (4 bytes) floating point numbers from
+    /// `src` into `dst`.
+    ///
+    /// Note that this does not perform any checks on the floating point
+    /// conversion. In particular, if the `src` data encodes an undefined
+    /// floating point value for your environment, then the result may be
+    /// undefined behavior. For example, this function may produce signaling
+    /// NaN floating point values.
+    ///
+    /// # Panics
+    ///
+    /// Panics when `src.len() != 4*dst.len()`.
+    ///
+    /// # Examples
+    ///
+    /// Write and read `f32` numbers in little endian order:
+    ///
+    /// ```rust
+    /// use byteorder::{ByteOrder, LittleEndian};
+    ///
+    /// let mut bytes = [0; 16];
+    /// let numbers_given = [1.0, 2.0, 31.312e311, -11.32e91];
+    /// LittleEndian::write_f32_into(&numbers_given, &mut bytes);
+    ///
+    /// let mut numbers_got = [0.0; 4];
+    /// unsafe {
+    ///     LittleEndian::read_f32_into_unchecked(&bytes, &mut numbers_got);
+    /// }
+    /// assert_eq!(numbers_given, numbers_got);
+    /// ```
+    #[inline]
+    unsafe fn read_f32_into_unchecked(src: &[u8], dst: &mut [f32]) {
+        Self::read_u32_into(src, transmute(dst));
+    }
+
+    /// Reads IEEE754 single-precision (4 bytes) floating point numbers from
+    /// `src` into `dst`.
+    ///
+    /// Note that this does not perform any checks on the floating point
+    /// conversion. In particular, if the `src` data encodes an undefined
+    /// floating point value for your environment, then the result may be
+    /// undefined behavior. For example, this function may produce signaling
+    /// NaN floating point values.
+    ///
+    /// # Panics
+    ///
+    /// Panics when `src.len() != 8*dst.len()`.
+    ///
+    /// # Examples
+    ///
+    /// Write and read `f64` numbers in little endian order:
+    ///
+    /// ```rust
+    /// use byteorder::{ByteOrder, LittleEndian};
+    ///
+    /// let mut bytes = [0; 32];
+    /// let numbers_given = [1.0, 2.0, 31.312e311, -11.32e91];
+    /// LittleEndian::write_f64_into(&numbers_given, &mut bytes);
+    ///
+    /// let mut numbers_got = [0.0; 4];
+    /// unsafe {
+    ///     LittleEndian::read_f64_into_unchecked(&bytes, &mut numbers_got);
+    /// }
+    /// assert_eq!(numbers_given, numbers_got);
+    /// ```
+    #[inline]
+    unsafe fn read_f64_into_unchecked(src: &[u8], dst: &mut [f64]) {
+        Self::read_u64_into(src, transmute(dst));
+    }
+
+    /// Writes unsigned 16 bit integers from `src` into `dst`.
+    ///
+    /// # Panics
+    ///
+    /// Panics when `dst.len() != 2*src.len()`.
+    ///
+    /// # Examples
+    ///
+    /// Write and read `u16` numbers in little endian order:
+    ///
+    /// ```rust
+    /// use byteorder::{ByteOrder, LittleEndian};
+    ///
+    /// let mut bytes = [0; 8];
+    /// let numbers_given = [1, 2, 0xf00f, 0xffee];
+    /// LittleEndian::write_u16_into(&numbers_given, &mut bytes);
+    ///
+    /// let mut numbers_got = [0; 4];
+    /// LittleEndian::read_u16_into(&bytes, &mut numbers_got);
+    /// assert_eq!(numbers_given, numbers_got);
+    /// ```
+    fn write_u16_into(src: &[u16], dst: &mut [u8]);
+
+    /// Writes unsigned 32 bit integers from `src` into `dst`.
+    ///
+    /// # Panics
+    ///
+    /// Panics when `dst.len() != 4*src.len()`.
+    ///
+    /// # Examples
+    ///
+    /// Write and read `u32` numbers in little endian order:
+    ///
+    /// ```rust
+    /// use byteorder::{ByteOrder, LittleEndian};
+    ///
+    /// let mut bytes = [0; 16];
+    /// let numbers_given = [1, 2, 0xf00f, 0xffee];
+    /// LittleEndian::write_u32_into(&numbers_given, &mut bytes);
+    ///
+    /// let mut numbers_got = [0; 4];
+    /// LittleEndian::read_u32_into(&bytes, &mut numbers_got);
+    /// assert_eq!(numbers_given, numbers_got);
+    /// ```
+    fn write_u32_into(src: &[u32], dst: &mut [u8]);
+
+    /// Writes unsigned 64 bit integers from `src` into `dst`.
+    ///
+    /// # Panics
+    ///
+    /// Panics when `dst.len() != 8*src.len()`.
+    ///
+    /// # Examples
+    ///
+    /// Write and read `u64` numbers in little endian order:
+    ///
+    /// ```rust
+    /// use byteorder::{ByteOrder, LittleEndian};
+    ///
+    /// let mut bytes = [0; 32];
+    /// let numbers_given = [1, 2, 0xf00f, 0xffee];
+    /// LittleEndian::write_u64_into(&numbers_given, &mut bytes);
+    ///
+    /// let mut numbers_got = [0; 4];
+    /// LittleEndian::read_u64_into(&bytes, &mut numbers_got);
+    /// assert_eq!(numbers_given, numbers_got);
+    /// ```
+    fn write_u64_into(src: &[u64], dst: &mut [u8]);
+
+    /// Writes unsigned 128 bit integers from `src` into `dst`.
+    ///
+    /// # Panics
+    ///
+    /// Panics when `dst.len() != 16*src.len()`.
+    ///
+    /// # Examples
+    ///
+    /// Write and read `u128` numbers in little endian order:
+    ///
+    /// ```rust
+    /// use byteorder::{ByteOrder, LittleEndian};
+    ///
+    /// let mut bytes = [0; 64];
+    /// let numbers_given = [1, 2, 0xf00f, 0xffee];
+    /// LittleEndian::write_u128_into(&numbers_given, &mut bytes);
+    ///
+    /// let mut numbers_got = [0; 4];
+    /// LittleEndian::read_u128_into(&bytes, &mut numbers_got);
+    /// assert_eq!(numbers_given, numbers_got);
+    /// ```
+    #[cfg(feature = "i128")]
+    fn write_u128_into(src: &[u128], dst: &mut [u8]);
+
+    /// Writes signed 16 bit integers from `src` into `dst`.
+    ///
+    /// # Panics
+    ///
+    /// Panics when `buf.len() != 2*src.len()`.
+    ///
+    /// # Examples
+    ///
+    /// Write and read `i16` numbers in little endian order:
+    ///
+    /// ```rust
+    /// use byteorder::{ByteOrder, LittleEndian};
+    ///
+    /// let mut bytes = [0; 8];
+    /// let numbers_given = [1, 2, 0xf00f, 0xffee];
+    /// LittleEndian::write_i16_into(&numbers_given, &mut bytes);
+    ///
+    /// let mut numbers_got = [0; 4];
+    /// LittleEndian::read_i16_into(&bytes, &mut numbers_got);
+    /// assert_eq!(numbers_given, numbers_got);
+    /// ```
+    fn write_i16_into(src: &[i16], dst: &mut [u8]) {
+        Self::write_u16_into(unsafe { transmute(src) }, dst);
+    }
+
+    /// Writes signed 32 bit integers from `src` into `dst`.
+    ///
+    /// # Panics
+    ///
+    /// Panics when `dst.len() != 4*src.len()`.
+    ///
+    /// # Examples
+    ///
+    /// Write and read `i32` numbers in little endian order:
+    ///
+    /// ```rust
+    /// use byteorder::{ByteOrder, LittleEndian};
+    ///
+    /// let mut bytes = [0; 16];
+    /// let numbers_given = [1, 2, 0xf00f, 0xffee];
+    /// LittleEndian::write_i32_into(&numbers_given, &mut bytes);
+    ///
+    /// let mut numbers_got = [0; 4];
+    /// LittleEndian::read_i32_into(&bytes, &mut numbers_got);
+    /// assert_eq!(numbers_given, numbers_got);
+    /// ```
+    fn write_i32_into(src: &[i32], dst: &mut [u8]) {
+        Self::write_u32_into(unsafe { transmute(src) }, dst);
+    }
+
+    /// Writes signed 64 bit integers from `src` into `dst`.
+    ///
+    /// # Panics
+    ///
+    /// Panics when `dst.len() != 8*src.len()`.
+    ///
+    /// # Examples
+    ///
+    /// Write and read `i64` numbers in little endian order:
+    ///
+    /// ```rust
+    /// use byteorder::{ByteOrder, LittleEndian};
+    ///
+    /// let mut bytes = [0; 32];
+    /// let numbers_given = [1, 2, 0xf00f, 0xffee];
+    /// LittleEndian::write_i64_into(&numbers_given, &mut bytes);
+    ///
+    /// let mut numbers_got = [0; 4];
+    /// LittleEndian::read_i64_into(&bytes, &mut numbers_got);
+    /// assert_eq!(numbers_given, numbers_got);
+    /// ```
+    fn write_i64_into(src: &[i64], dst: &mut [u8]) {
+        Self::write_u64_into(unsafe { transmute(src) }, dst);
+    }
+
+    /// Writes signed 128 bit integers from `src` into `dst`.
+    ///
+    /// # Panics
+    ///
+    /// Panics when `dst.len() != 16*src.len()`.
+    ///
+    /// # Examples
+    ///
+    /// Write and read `i128` numbers in little endian order:
+    ///
+    /// ```rust
+    /// use byteorder::{ByteOrder, LittleEndian};
+    ///
+    /// let mut bytes = [0; 64];
+    /// let numbers_given = [1, 2, 0xf00f, 0xffee];
+    /// LittleEndian::write_i128_into(&numbers_given, &mut bytes);
+    ///
+    /// let mut numbers_got = [0; 4];
+    /// LittleEndian::read_i128_into(&bytes, &mut numbers_got);
+    /// assert_eq!(numbers_given, numbers_got);
+    /// ```
+    #[cfg(feature = "i128")]
+    fn write_i128_into(src: &[i128], dst: &mut [u8]) {
+        Self::write_u128_into(unsafe { transmute(src) }, dst);
+    }
+
+    /// Writes IEEE754 single-precision (4 bytes) floating point numbers from
+    /// `src` into `dst`.
+    ///
+    /// # Panics
+    ///
+    /// Panics when `src.len() != 4*dst.len()`.
+    ///
+    /// # Examples
+    ///
+    /// Write and read `f32` numbers in little endian order:
+    ///
+    /// ```rust
+    /// use byteorder::{ByteOrder, LittleEndian};
+    ///
+    /// let mut bytes = [0; 16];
+    /// let numbers_given = [1.0, 2.0, 31.312e311, -11.32e91];
+    /// LittleEndian::write_f32_into(&numbers_given, &mut bytes);
+    ///
+    /// let mut numbers_got = [0.0; 4];
+    /// unsafe {
+    ///     LittleEndian::read_f32_into_unchecked(&bytes, &mut numbers_got);
+    /// }
+    /// assert_eq!(numbers_given, numbers_got);
+    /// ```
+    fn write_f32_into(src: &[f32], dst: &mut [u8]) {
+        Self::write_u32_into(unsafe { transmute(src) }, dst);
+    }
+
+    /// Writes IEEE754 double-precision (8 bytes) floating point numbers from
+    /// `src` into `dst`.
+    ///
+    /// # Panics
+    ///
+    /// Panics when `src.len() != 8*dst.len()`.
+    ///
+    /// # Examples
+    ///
+    /// Write and read `f64` numbers in little endian order:
+    ///
+    /// ```rust
+    /// use byteorder::{ByteOrder, LittleEndian};
+    ///
+    /// let mut bytes = [0; 32];
+    /// let numbers_given = [1.0, 2.0, 31.312e311, -11.32e91];
+    /// LittleEndian::write_f64_into(&numbers_given, &mut bytes);
+    ///
+    /// let mut numbers_got = [0.0; 4];
+    /// unsafe {
+    ///     LittleEndian::read_f64_into_unchecked(&bytes, &mut numbers_got);
+    /// }
+    /// assert_eq!(numbers_given, numbers_got);
+    /// ```
+    fn write_f64_into(src: &[f64], dst: &mut [u8]) {
+        Self::write_u64_into(unsafe { transmute(src) }, dst);
+    }
+
+    /// Converts the given slice of unsigned 16 bit integers to a particular
+    /// endianness.
+    ///
+    /// If the endianness matches the endianness of the host platform, then
+    /// this is a no-op.
+    ///
+    /// # Examples
+    ///
+    /// Convert the host platform's endianness to big-endian:
+    ///
+    /// ```rust
+    /// use byteorder::{ByteOrder, BigEndian};
+    ///
+    /// let mut numbers = [5, 65000];
+    /// BigEndian::from_slice_u16(&mut numbers);
+    /// if cfg!(target_endian = "little") {
+    ///     assert_eq!(numbers, [5u16.swap_bytes(), 65000u16.swap_bytes()]);
+    /// } else {
+    ///     assert_eq!(numbers, [5, 65000]);
+    /// }
+    /// ```
+    fn from_slice_u16(numbers: &mut [u16]);
+
+    /// Converts the given slice of unsigned 32 bit integers to a particular
+    /// endianness.
+    ///
+    /// If the endianness matches the endianness of the host platform, then
+    /// this is a no-op.
+    ///
+    /// # Examples
+    ///
+    /// Convert the host platform's endianness to big-endian:
+    ///
+    /// ```rust
+    /// use byteorder::{ByteOrder, BigEndian};
+    ///
+    /// let mut numbers = [5, 65000];
+    /// BigEndian::from_slice_u32(&mut numbers);
+    /// if cfg!(target_endian = "little") {
+    ///     assert_eq!(numbers, [5u32.swap_bytes(), 65000u32.swap_bytes()]);
+    /// } else {
+    ///     assert_eq!(numbers, [5, 65000]);
+    /// }
+    /// ```
+    fn from_slice_u32(numbers: &mut [u32]);
+
+    /// Converts the given slice of unsigned 64 bit integers to a particular
+    /// endianness.
+    ///
+    /// If the endianness matches the endianness of the host platform, then
+    /// this is a no-op.
+    ///
+    /// # Examples
+    ///
+    /// Convert the host platform's endianness to big-endian:
+    ///
+    /// ```rust
+    /// use byteorder::{ByteOrder, BigEndian};
+    ///
+    /// let mut numbers = [5, 65000];
+    /// BigEndian::from_slice_u64(&mut numbers);
+    /// if cfg!(target_endian = "little") {
+    ///     assert_eq!(numbers, [5u64.swap_bytes(), 65000u64.swap_bytes()]);
+    /// } else {
+    ///     assert_eq!(numbers, [5, 65000]);
+    /// }
+    /// ```
+    fn from_slice_u64(numbers: &mut [u64]);
+
+    /// Converts the given slice of unsigned 128 bit integers to a particular
+    /// endianness.
+    ///
+    /// If the endianness matches the endianness of the host platform, then
+    /// this is a no-op.
+    ///
+    /// # Examples
+    ///
+    /// Convert the host platform's endianness to big-endian:
+    ///
+    /// ```rust
+    /// #![feature(i128_type)]
+    ///
+    /// use byteorder::{ByteOrder, BigEndian};
+    ///
+    /// let mut numbers = [5, 65000];
+    /// BigEndian::from_slice_u128(&mut numbers);
+    /// if cfg!(target_endian = "little") {
+    ///     assert_eq!(numbers, [5u128.swap_bytes(), 65000u128.swap_bytes()]);
+    /// } else {
+    ///     assert_eq!(numbers, [5, 65000]);
+    /// }
+    /// ```
+    #[cfg(feature = "i128")]
+    fn from_slice_u128(numbers: &mut [u128]);
+
+    /// Converts the given slice of signed 16 bit integers to a particular
+    /// endianness.
+    ///
+    /// If the endianness matches the endianness of the host platform, then
+    /// this is a no-op.
+    ///
+    /// # Examples
+    ///
+    /// Convert the host platform's endianness to big-endian:
+    ///
+    /// ```rust
+    /// use byteorder::{ByteOrder, BigEndian};
+    ///
+    /// let mut numbers = [5, 65000];
+    /// BigEndian::from_slice_i16(&mut numbers);
+    /// if cfg!(target_endian = "little") {
+    ///     assert_eq!(numbers, [5i16.swap_bytes(), 65000i16.swap_bytes()]);
+    /// } else {
+    ///     assert_eq!(numbers, [5, 65000]);
+    /// }
+    /// ```
+    #[inline]
+    fn from_slice_i16(numbers: &mut [i16]) {
+        Self::from_slice_u16(unsafe { transmute(numbers) });
+    }
+
+    /// Converts the given slice of signed 32 bit integers to a particular
+    /// endianness.
+    ///
+    /// If the endianness matches the endianness of the host platform, then
+    /// this is a no-op.
+    ///
+    /// # Examples
+    ///
+    /// Convert the host platform's endianness to big-endian:
+    ///
+    /// ```rust
+    /// use byteorder::{ByteOrder, BigEndian};
+    ///
+    /// let mut numbers = [5, 65000];
+    /// BigEndian::from_slice_i32(&mut numbers);
+    /// if cfg!(target_endian = "little") {
+    ///     assert_eq!(numbers, [5i32.swap_bytes(), 65000i32.swap_bytes()]);
+    /// } else {
+    ///     assert_eq!(numbers, [5, 65000]);
+    /// }
+    /// ```
+    #[inline]
+    fn from_slice_i32(numbers: &mut [i32]) {
+        Self::from_slice_u32(unsafe { transmute(numbers) });
+    }
+
+    /// Converts the given slice of signed 64 bit integers to a particular
+    /// endianness.
+    ///
+    /// If the endianness matches the endianness of the host platform, then
+    /// this is a no-op.
+    ///
+    /// # Examples
+    ///
+    /// Convert the host platform's endianness to big-endian:
+    ///
+    /// ```rust
+    /// use byteorder::{ByteOrder, BigEndian};
+    ///
+    /// let mut numbers = [5, 65000];
+    /// BigEndian::from_slice_i64(&mut numbers);
+    /// if cfg!(target_endian = "little") {
+    ///     assert_eq!(numbers, [5i64.swap_bytes(), 65000i64.swap_bytes()]);
+    /// } else {
+    ///     assert_eq!(numbers, [5, 65000]);
+    /// }
+    /// ```
+    #[inline]
+    fn from_slice_i64(numbers: &mut [i64]) {
+        Self::from_slice_u64(unsafe { transmute(numbers) });
+    }
+
+    /// Converts the given slice of signed 128 bit integers to a particular
+    /// endianness.
+    ///
+    /// If the endianness matches the endianness of the host platform, then
+    /// this is a no-op.
+    ///
+    /// # Examples
+    ///
+    /// Convert the host platform's endianness to big-endian:
+    ///
+    /// ```rust
+    /// #![feature(i128_type)]
+    ///
+    /// use byteorder::{ByteOrder, BigEndian};
+    ///
+    /// let mut numbers = [5, 65000];
+    /// BigEndian::from_slice_i128(&mut numbers);
+    /// if cfg!(target_endian = "little") {
+    ///     assert_eq!(numbers, [5i128.swap_bytes(), 65000i128.swap_bytes()]);
+    /// } else {
+    ///     assert_eq!(numbers, [5, 65000]);
+    /// }
+    /// ```
+    #[cfg(feature = "i128")]
+    #[inline]
+    fn from_slice_i128(numbers: &mut [i128]) {
+        Self::from_slice_u128(unsafe { transmute(numbers) });
+    }
+
+    /// Converts the given slice of IEEE754 single-precision (4 bytes) floating
+    /// point numbers to a particular endianness.
+    ///
+    /// If the endianness matches the endianness of the host platform, then
+    /// this is a no-op.
+    ///
+    /// Note that the results of this operation are guaranteed to be defined.
+    /// In particular, this method may replace signaling NaN values with
+    /// quiet NaN values.
+    fn from_slice_f32(numbers: &mut [f32]);
+
+    /// Converts the given slice of IEEE754 double-precision (8 bytes) floating
+    /// point numbers to a particular endianness.
+    ///
+    /// If the endianness matches the endianness of the host platform, then
+    /// this is a no-op.
+    ///
+    /// Note that the results of this operation are guaranteed to be defined.
+    /// In particular, this method may replace signaling NaN values with
+    /// quiet NaN values.
+    fn from_slice_f64(numbers: &mut [f64]);
+}
+
+/// Defines big-endian serialization.
+///
+/// Note that this type has no value constructor. It is used purely at the
+/// type level.
+///
+/// # Examples
+///
+/// Write and read `u32` numbers in big endian order:
+///
+/// ```rust
+/// use byteorder::{ByteOrder, BigEndian};
+///
+/// let mut buf = [0; 4];
+/// BigEndian::write_u32(&mut buf, 1_000_000);
+/// assert_eq!(1_000_000, BigEndian::read_u32(&buf));
+/// ```
+#[derive(Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd)]
+pub enum BigEndian {}
+
+impl Default for BigEndian {
+    fn default() -> BigEndian {
+        panic!("BigEndian default")
+    }
+}
+
+/// A type alias for `BigEndian`.
+pub type BE = BigEndian;
+
+/// Defines little-endian serialization.
+///
+/// Note that this type has no value constructor. It is used purely at the
+/// type level.
+///
+/// # Examples
+///
+/// Write and read `u32` numbers in little endian order:
+///
+/// ```rust
+/// use byteorder::{ByteOrder, LittleEndian};
+///
+/// let mut buf = [0; 4];
+/// LittleEndian::write_u32(&mut buf, 1_000_000);
+/// assert_eq!(1_000_000, LittleEndian::read_u32(&buf));
+/// ```
+#[derive(Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd)]
+pub enum LittleEndian {}
+
+impl Default for LittleEndian {
+    fn default() -> LittleEndian {
+        panic!("LittleEndian default")
+    }
+}
+
+/// A type alias for `LittleEndian`.
+pub type LE = LittleEndian;
+
+/// Defines network byte order serialization.
+///
+/// Network byte order is defined by [RFC 1700][1] to be big-endian, and is
+/// referred to in several protocol specifications.  This type is an alias of
+/// BigEndian.
+///
+/// [1]: https://tools.ietf.org/html/rfc1700
+///
+/// Note that this type has no value constructor. It is used purely at the
+/// type level.
+///
+/// # Examples
+///
+/// Write and read `i16` numbers in big endian order:
+///
+/// ```rust
+/// use byteorder::{ByteOrder, NetworkEndian, BigEndian};
+///
+/// let mut buf = [0; 2];
+/// BigEndian::write_i16(&mut buf, -50_000);
+/// assert_eq!(-50_000, NetworkEndian::read_i16(&buf));
+/// ```
+pub type NetworkEndian = BigEndian;
+
+/// Defines system native-endian serialization.
+///
+/// Note that this type has no value constructor. It is used purely at the
+/// type level.
+#[cfg(target_endian = "little")]
+pub type NativeEndian = LittleEndian;
+
+/// Defines system native-endian serialization.
+///
+/// Note that this type has no value constructor. It is used purely at the
+/// type level.
+#[cfg(target_endian = "big")]
+pub type NativeEndian = BigEndian;
+
+macro_rules! read_num_bytes {
+    ($ty:ty, $size:expr, $src:expr, $which:ident) => ({
+        assert!($size == ::core::mem::size_of::<$ty>());
+        assert!($size <= $src.len());
+        let mut data: $ty = 0;
+        unsafe {
+            copy_nonoverlapping(
+                $src.as_ptr(),
+                &mut data as *mut $ty as *mut u8,
+                $size);
+        }
+        data.$which()
+    });
+}
+
+macro_rules! write_num_bytes {
+    ($ty:ty, $size:expr, $n:expr, $dst:expr, $which:ident) => ({
+        assert!($size <= $dst.len());
+        unsafe {
+            // N.B. https://github.com/rust-lang/rust/issues/22776
+            let bytes = transmute::<_, [u8; $size]>($n.$which());
+            copy_nonoverlapping((&bytes).as_ptr(), $dst.as_mut_ptr(), $size);
+        }
+    });
+}
+
+macro_rules! read_slice {
+    ($src:expr, $dst:expr, $size:expr, $which:ident) => {{
+        assert_eq!($src.len(), $size * $dst.len());
+
+        unsafe {
+            copy_nonoverlapping(
+                $src.as_ptr(),
+                $dst.as_mut_ptr() as *mut u8,
+                $src.len());
+        }
+        for v in $dst.iter_mut() {
+            *v = v.$which();
+        }
+    }};
+}
+
+macro_rules! write_slice_native {
+    ($src:expr, $dst:expr, $ty:ty, $size:expr) => {{
+        assert!($size == ::core::mem::size_of::<$ty>());
+        assert_eq!($size * $src.len(), $dst.len());
+
+        unsafe {
+            copy_nonoverlapping(
+                $src.as_ptr() as *const u8,
+                $dst.as_mut_ptr(),
+                $dst.len());
+        }
+    }};
+}
+
+macro_rules! write_slice {
+    ($src:expr, $dst:expr, $ty:ty, $size:expr, $write:expr) => ({
+        assert!($size == ::core::mem::size_of::<$ty>());
+        assert_eq!($size * $src.len(), $dst.len());
+
+        for (&n, chunk) in $src.iter().zip($dst.chunks_mut($size)) {
+            $write(chunk, n);
+        }
+    });
+}
+
+impl ByteOrder for BigEndian {
+    #[inline]
+    fn read_u16(buf: &[u8]) -> u16 {
+        read_num_bytes!(u16, 2, buf, to_be)
+    }
+
+    #[inline]
+    fn read_u32(buf: &[u8]) -> u32 {
+        read_num_bytes!(u32, 4, buf, to_be)
+    }
+
+    #[inline]
+    fn read_u64(buf: &[u8]) -> u64 {
+        read_num_bytes!(u64, 8, buf, to_be)
+    }
+
+    #[cfg(feature = "i128")]
+    #[inline]
+    fn read_u128(buf: &[u8]) -> u128 {
+        read_num_bytes!(u128, 16, buf, to_be)
+    }
+
+    #[inline]
+    fn read_uint(buf: &[u8], nbytes: usize) -> u64 {
+        assert!(1 <= nbytes && nbytes <= 8 && nbytes <= buf.len());
+        let mut out = [0u8; 8];
+        let ptr_out = out.as_mut_ptr();
+        unsafe {
+            copy_nonoverlapping(
+                buf.as_ptr(), ptr_out.offset((8 - nbytes) as isize), nbytes);
+            (*(ptr_out as *const u64)).to_be()
+        }
+    }
+
+    #[cfg(feature = "i128")]
+    #[inline]
+    fn read_uint128(buf: &[u8], nbytes: usize) -> u128 {
+        assert!(1 <= nbytes && nbytes <= 16 && nbytes <= buf.len());
+        let mut out = [0u8; 16];
+        let ptr_out = out.as_mut_ptr();
+        unsafe {
+            copy_nonoverlapping(
+                buf.as_ptr(), ptr_out.offset((16 - nbytes) as isize), nbytes);
+            (*(ptr_out as *const u128)).to_be()
+        }
+    }
+
+    #[inline]
+    fn write_u16(buf: &mut [u8], n: u16) {
+        write_num_bytes!(u16, 2, n, buf, to_be);
+    }
+
+    #[inline]
+    fn write_u32(buf: &mut [u8], n: u32) {
+        write_num_bytes!(u32, 4, n, buf, to_be);
+    }
+
+    #[inline]
+    fn write_u64(buf: &mut [u8], n: u64) {
+        write_num_bytes!(u64, 8, n, buf, to_be);
+    }
+
+    #[cfg(feature = "i128")]
+    #[inline]
+    fn write_u128(buf: &mut [u8], n: u128) {
+        write_num_bytes!(u128, 16, n, buf, to_be);
+    }
+
+    #[inline]
+    fn write_uint(buf: &mut [u8], n: u64, nbytes: usize) {
+        assert!(pack_size(n) <= nbytes && nbytes <= 8);
+        assert!(nbytes <= buf.len());
+        unsafe {
+            let bytes: [u8; 8] = transmute(n.to_be());
+            copy_nonoverlapping(
+                bytes.as_ptr().offset((8 - nbytes) as isize),
+                buf.as_mut_ptr(),
+                nbytes);
+        }
+    }
+
+    #[cfg(feature = "i128")]
+    #[inline]
+    fn write_uint128(buf: &mut [u8], n: u128, nbytes: usize) {
+        assert!(pack_size128(n) <= nbytes && nbytes <= 16);
+        assert!(nbytes <= buf.len());
+        unsafe {
+            let bytes: [u8; 16] = transmute(n.to_be());
+            copy_nonoverlapping(
+                bytes.as_ptr().offset((16 - nbytes) as isize),
+                buf.as_mut_ptr(),
+                nbytes);
+        }
+    }
+
+    #[inline]
+    fn read_u16_into(src: &[u8], dst: &mut [u16]) {
+        read_slice!(src, dst, 2, to_be);
+    }
+
+    #[inline]
+    fn read_u32_into(src: &[u8], dst: &mut [u32]) {
+        read_slice!(src, dst, 4, to_be);
+    }
+
+    #[inline]
+    fn read_u64_into(src: &[u8], dst: &mut [u64]) {
+        read_slice!(src, dst, 8, to_be);
+    }
+
+    #[cfg(feature = "i128")]
+    #[inline]
+    fn read_u128_into(src: &[u8], dst: &mut [u128]) {
+        read_slice!(src, dst, 16, to_be);
+    }
+
+    #[inline]
+    fn write_u16_into(src: &[u16], dst: &mut [u8]) {
+        if cfg!(target_endian = "big") {
+            write_slice_native!(src, dst, u16, 2);
+        } else {
+            write_slice!(src, dst, u16, 2, Self::write_u16);
+        }
+    }
+
+    #[inline]
+    fn write_u32_into(src: &[u32], dst: &mut [u8]) {
+        if cfg!(target_endian = "big") {
+            write_slice_native!(src, dst, u32, 4);
+        } else {
+            write_slice!(src, dst, u32, 4, Self::write_u32);
+        }
+    }
+
+    #[inline]
+    fn write_u64_into(src: &[u64], dst: &mut [u8]) {
+        if cfg!(target_endian = "big") {
+            write_slice_native!(src, dst, u64, 8);
+        } else {
+            write_slice!(src, dst, u64, 8, Self::write_u64);
+        }
+    }
+
+    #[cfg(feature = "i128")]
+    #[inline]
+    fn write_u128_into(src: &[u128], dst: &mut [u8]) {
+        if cfg!(target_endian = "big") {
+            write_slice_native!(src, dst, u128, 16);
+        } else {
+            write_slice!(src, dst, u128, 16, Self::write_u128);
+        }
+    }
+
+    #[inline]
+    fn from_slice_u16(numbers: &mut [u16]) {
+        if cfg!(target_endian = "little") {
+            for n in numbers {
+                *n = n.to_be();
+            }
+        }
+    }
+
+    #[inline]
+    fn from_slice_u32(numbers: &mut [u32]) {
+        if cfg!(target_endian = "little") {
+            for n in numbers {
+                *n = n.to_be();
+            }
+        }
+    }
+
+    #[inline]
+    fn from_slice_u64(numbers: &mut [u64]) {
+        if cfg!(target_endian = "little") {
+            for n in numbers {
+                *n = n.to_be();
+            }
+        }
+    }
+
+    #[cfg(feature = "i128")]
+    #[inline]
+    fn from_slice_u128(numbers: &mut [u128]) {
+        if cfg!(target_endian = "little") {
+            for n in numbers {
+                *n = n.to_be();
+            }
+        }
+    }
+
+    #[inline]
+    fn from_slice_f32(numbers: &mut [f32]) {
+        if cfg!(target_endian = "little") {
+            for n in numbers {
+                let int: u32 = unsafe { transmute(*n) };
+                *n = safe_u32_bits_to_f32(int.to_be());
+            }
+        }
+    }
+
+    #[inline]
+    fn from_slice_f64(numbers: &mut [f64]) {
+        if cfg!(target_endian = "little") {
+            for n in numbers {
+                let int: u64 = unsafe { transmute(*n) };
+                *n = safe_u64_bits_to_f64(int.to_be());
+            }
+        }
+    }
+}
+
+impl ByteOrder for LittleEndian {
+    #[inline]
+    fn read_u16(buf: &[u8]) -> u16 {
+        read_num_bytes!(u16, 2, buf, to_le)
+    }
+
+    #[inline]
+    fn read_u32(buf: &[u8]) -> u32 {
+        read_num_bytes!(u32, 4, buf, to_le)
+    }
+
+    #[inline]
+    fn read_u64(buf: &[u8]) -> u64 {
+        read_num_bytes!(u64, 8, buf, to_le)
+    }
+
+    #[cfg(feature = "i128")]
+    #[inline]
+    fn read_u128(buf: &[u8]) -> u128 {
+        read_num_bytes!(u128, 16, buf, to_le)
+    }
+
+    #[inline]
+    fn read_uint(buf: &[u8], nbytes: usize) -> u64 {
+        assert!(1 <= nbytes && nbytes <= 8 && nbytes <= buf.len());
+        let mut out = [0u8; 8];
+        let ptr_out = out.as_mut_ptr();
+        unsafe {
+            copy_nonoverlapping(buf.as_ptr(), ptr_out, nbytes);
+            (*(ptr_out as *const u64)).to_le()
+        }
+    }
+
+    #[cfg(feature = "i128")]
+    #[inline]
+    fn read_uint128(buf: &[u8], nbytes: usize) -> u128 {
+        assert!(1 <= nbytes && nbytes <= 16 && nbytes <= buf.len());
+        let mut out = [0u8; 16];
+        let ptr_out = out.as_mut_ptr();
+        unsafe {
+            copy_nonoverlapping(buf.as_ptr(), ptr_out, nbytes);
+            (*(ptr_out as *const u128)).to_le()
+        }
+    }
+
+    #[inline]
+    fn write_u16(buf: &mut [u8], n: u16) {
+        write_num_bytes!(u16, 2, n, buf, to_le);
+    }
+
+    #[inline]
+    fn write_u32(buf: &mut [u8], n: u32) {
+        write_num_bytes!(u32, 4, n, buf, to_le);
+    }
+
+    #[inline]
+    fn write_u64(buf: &mut [u8], n: u64) {
+        write_num_bytes!(u64, 8, n, buf, to_le);
+    }
+
+    #[cfg(feature = "i128")]
+    #[inline]
+    fn write_u128(buf: &mut [u8], n: u128) {
+        write_num_bytes!(u128, 16, n, buf, to_le);
+    }
+
+    #[inline]
+    fn write_uint(buf: &mut [u8], n: u64, nbytes: usize) {
+        assert!(pack_size(n as u64) <= nbytes && nbytes <= 8);
+        assert!(nbytes <= buf.len());
+        unsafe {
+            let bytes: [u8; 8] = transmute(n.to_le());
+            copy_nonoverlapping(bytes.as_ptr(), buf.as_mut_ptr(), nbytes);
+        }
+    }
+
+    #[cfg(feature = "i128")]
+    #[inline]
+    fn write_uint128(buf: &mut [u8], n: u128, nbytes: usize) {
+        assert!(pack_size128(n as u128) <= nbytes && nbytes <= 16);
+        assert!(nbytes <= buf.len());
+        unsafe {
+            let bytes: [u8; 16] = transmute(n.to_le());
+            copy_nonoverlapping(bytes.as_ptr(), buf.as_mut_ptr(), nbytes);
+        }
+    }
+
+    #[inline]
+    fn read_u16_into(src: &[u8], dst: &mut [u16]) {
+        read_slice!(src, dst, 2, to_le);
+    }
+
+    #[inline]
+    fn read_u32_into(src: &[u8], dst: &mut [u32]) {
+        read_slice!(src, dst, 4, to_le);
+    }
+
+    #[inline]
+    fn read_u64_into(src: &[u8], dst: &mut [u64]) {
+        read_slice!(src, dst, 8, to_le);
+    }
+
+    #[cfg(feature = "i128")]
+    #[inline]
+    fn read_u128_into(src: &[u8], dst: &mut [u128]) {
+        read_slice!(src, dst, 16, to_le);
+    }
+
+    #[inline]
+    fn write_u16_into(src: &[u16], dst: &mut [u8]) {
+        if cfg!(target_endian = "little") {
+            write_slice_native!(src, dst, u16, 2);
+        } else {
+            write_slice!(src, dst, u16, 2, Self::write_u16);
+        }
+    }
+
+    #[inline]
+    fn write_u32_into(src: &[u32], dst: &mut [u8]) {
+        if cfg!(target_endian = "little") {
+            write_slice_native!(src, dst, u32, 4);
+        } else {
+            write_slice!(src, dst, u32, 4, Self::write_u32);
+        }
+    }
+
+    #[inline]
+    fn write_u64_into(src: &[u64], dst: &mut [u8]) {
+        if cfg!(target_endian = "little") {
+            write_slice_native!(src, dst, u64, 8);
+        } else {
+            write_slice!(src, dst, u64, 8, Self::write_u64);
+        }
+    }
+
+    #[cfg(feature = "i128")]
+    #[inline]
+    fn write_u128_into(src: &[u128], dst: &mut [u8]) {
+        if cfg!(target_endian = "little") {
+            write_slice_native!(src, dst, u128, 16);
+        } else {
+            write_slice!(src, dst, u128, 16, Self::write_u128);
+        }
+    }
+
+    #[inline]
+    fn from_slice_u16(numbers: &mut [u16]) {
+        if cfg!(target_endian = "big") {
+            for n in numbers {
+                *n = n.to_le();
+            }
+        }
+    }
+
+    #[inline]
+    fn from_slice_u32(numbers: &mut [u32]) {
+        if cfg!(target_endian = "big") {
+            for n in numbers {
+                *n = n.to_le();
+            }
+        }
+    }
+
+    #[inline]
+    fn from_slice_u64(numbers: &mut [u64]) {
+        if cfg!(target_endian = "big") {
+            for n in numbers {
+                *n = n.to_le();
+            }
+        }
+    }
+
+    #[cfg(feature = "i128")]
+    #[inline]
+    fn from_slice_u128(numbers: &mut [u128]) {
+        if cfg!(target_endian = "big") {
+            for n in numbers {
+                *n = n.to_le();
+            }
+        }
+    }
+
+    #[inline]
+    fn from_slice_f32(numbers: &mut [f32]) {
+        if cfg!(target_endian = "big") {
+            for n in numbers {
+                let int: u32 = unsafe { transmute(*n) };
+                *n = safe_u32_bits_to_f32(int.to_le());
+            }
+        }
+    }
+
+    #[inline]
+    fn from_slice_f64(numbers: &mut [f64]) {
+        if cfg!(target_endian = "big") {
+            for n in numbers {
+                let int: u64 = unsafe { transmute(*n) };
+                *n = safe_u64_bits_to_f64(int.to_le());
+            }
+        }
+    }
+}
+
+#[inline]
+fn safe_u32_bits_to_f32(u: u32) -> f32 {
+    use core::f32::NAN;
+
+    const EXP_MASK: u32 = 0x7F800000;
+    const FRACT_MASK: u32 = 0x007FFFFF;
+
+    if u & EXP_MASK == EXP_MASK && u & FRACT_MASK != 0 {
+        // While IEEE 754-2008 specifies encodings for quiet NaNs and
+        // signaling ones, certains MIPS and PA-RISC CPUs treat signaling
+        // NaNs differently. Therefore, to be safe, we pass a known quiet
+        // NaN if u is any kind of NaN. The check above only assumes
+        // IEEE 754-1985 to be valid.
+        NAN
+    } else {
+        unsafe { transmute(u) }
+    }
+}
+
+#[inline]
+fn safe_u64_bits_to_f64(u: u64) -> f64 {
+    use core::f64::NAN;
+
+    const EXP_MASK: u64 = 0x7FF0000000000000;
+    const FRACT_MASK: u64 = 0x000FFFFFFFFFFFFF;
+
+    if u & EXP_MASK == EXP_MASK && u & FRACT_MASK != 0 {
+        // While IEEE 754-2008 specifies encodings for quiet NaNs and
+        // signaling ones, certains MIPS and PA-RISC CPUs treat signaling
+        // NaNs differently. Therefore, to be safe, we pass a known quiet
+        // NaN if u is any kind of NaN. The check above only assumes
+        // IEEE 754-1985 to be valid.
+        NAN
+    } else {
+        unsafe { transmute(u) }
+    }
+}
+
+#[cfg(test)]
+mod test {
+    extern crate quickcheck;
+    extern crate rand;
+
+    use self::quickcheck::{QuickCheck, StdGen, Testable};
+    use self::rand::thread_rng;
+    #[cfg(feature = "i128")] use self::quickcheck::{Arbitrary, Gen};
+
+    pub const U24_MAX: u32 = 16_777_215;
+    pub const I24_MAX: i32 = 8_388_607;
+
+    pub const U64_MAX: u64 = ::core::u64::MAX;
+    pub const I64_MAX: u64 = ::core::i64::MAX as u64;
+
+    macro_rules! calc_max {
+        ($max:expr, $bytes:expr) => { calc_max!($max, $bytes, 8) };
+        ($max:expr, $bytes:expr, $maxbytes:expr) => {
+            ($max - 1) >> (8 * ($maxbytes - $bytes))
+        };
+    }
+
+    #[derive(Clone, Debug)]
+    pub struct Wi128<T>(pub T);
+
+    #[cfg(feature = "i128")]
+    impl<T: Clone> Wi128<T> {
+        pub fn clone(&self) -> T {
+            self.0.clone()
+        }
+    }
+
+    impl<T: PartialEq> PartialEq<T> for Wi128<T> {
+        fn eq(&self, other: &T) -> bool {
+            self.0.eq(other)
+        }
+    }
+
+    #[cfg(feature = "i128")]
+    impl Arbitrary for Wi128<u128> {
+        fn arbitrary<G: Gen>(gen: &mut G) -> Wi128<u128> {
+            let max = calc_max!(::core::u128::MAX, gen.size(), 16);
+            let output =
+                (gen.gen::<u64>() as u128) |
+                ((gen.gen::<u64>() as u128) << 64);
+            Wi128(output & (max - 1))
+        }
+    }
+
+    #[cfg(feature = "i128")]
+    impl Arbitrary for Wi128<i128> {
+        fn arbitrary<G: Gen>(gen: &mut G) -> Wi128<i128> {
+            let max = calc_max!(::core::i128::MAX, gen.size(), 16);
+            let output =
+                (gen.gen::<i64>() as i128) |
+                ((gen.gen::<i64>() as i128) << 64);
+            Wi128(output & (max - 1))
+        }
+    }
+
+    pub fn qc_sized<A: Testable>(f: A, size: u64) {
+        QuickCheck::new()
+            .gen(StdGen::new(thread_rng(), size as usize))
+            .tests(1_00)
+            .max_tests(10_000)
+            .quickcheck(f);
+    }
+
+    macro_rules! qc_byte_order {
+        ($name:ident, $ty_int:ty, $max:expr,
+         $bytes:expr, $read:ident, $write:ident) => (
+            mod $name {
+                use {BigEndian, ByteOrder, NativeEndian, LittleEndian};
+                #[allow(unused_imports)] use super::{ qc_sized, Wi128 };
+
+                #[test]
+                fn big_endian() {
+                    fn prop(n: $ty_int) -> bool {
+                        let mut buf = [0; 16];
+                        BigEndian::$write(&mut buf, n.clone(), $bytes);
+                        n == BigEndian::$read(&mut buf[..$bytes], $bytes)
+                    }
+                    qc_sized(prop as fn($ty_int) -> bool, $max);
+                }
+
+                #[test]
+                fn little_endian() {
+                    fn prop(n: $ty_int) -> bool {
+                        let mut buf = [0; 16];
+                        LittleEndian::$write(&mut buf, n.clone(), $bytes);
+                        n == LittleEndian::$read(&mut buf[..$bytes], $bytes)
+                    }
+                    qc_sized(prop as fn($ty_int) -> bool, $max);
+                }
+
+                #[test]
+                fn native_endian() {
+                    fn prop(n: $ty_int) -> bool {
+                        let mut buf = [0; 16];
+                        NativeEndian::$write(&mut buf, n.clone(), $bytes);
+                        n == NativeEndian::$read(&mut buf[..$bytes], $bytes)
+                    }
+                    qc_sized(prop as fn($ty_int) -> bool, $max);
+                }
+            }
+        );
+        ($name:ident, $ty_int:ty, $max:expr,
+         $read:ident, $write:ident) => (
+            mod $name {
+                use core::mem::size_of;
+                use {BigEndian, ByteOrder, NativeEndian, LittleEndian};
+                #[allow(unused_imports)] use super::{ qc_sized, Wi128 };
+
+                #[test]
+                fn big_endian() {
+                    fn prop(n: $ty_int) -> bool {
+                        let bytes = size_of::<$ty_int>();
+                        let mut buf = [0; 16];
+                        BigEndian::$write(&mut buf[16 - bytes..], n.clone());
+                        n == BigEndian::$read(&mut buf[16 - bytes..])
+                    }
+                    qc_sized(prop as fn($ty_int) -> bool, $max - 1);
+                }
+
+                #[test]
+                fn little_endian() {
+                    fn prop(n: $ty_int) -> bool {
+                        let bytes = size_of::<$ty_int>();
+                        let mut buf = [0; 16];
+                        LittleEndian::$write(&mut buf[..bytes], n.clone());
+                        n == LittleEndian::$read(&mut buf[..bytes])
+                    }
+                    qc_sized(prop as fn($ty_int) -> bool, $max - 1);
+                }
+
+                #[test]
+                fn native_endian() {
+                    fn prop(n: $ty_int) -> bool {
+                        let bytes = size_of::<$ty_int>();
+                        let mut buf = [0; 16];
+                        NativeEndian::$write(&mut buf[..bytes], n.clone());
+                        n == NativeEndian::$read(&mut buf[..bytes])
+                    }
+                    qc_sized(prop as fn($ty_int) -> bool, $max - 1);
+                }
+            }
+        );
+    }
+
+    qc_byte_order!(prop_u16, u16, ::core::u16::MAX as u64, read_u16, write_u16);
+    qc_byte_order!(prop_i16, i16, ::core::i16::MAX as u64, read_i16, write_i16);
+    qc_byte_order!(prop_u24, u32, ::test::U24_MAX as u64, read_u24, write_u24);
+    qc_byte_order!(prop_i24, i32, ::test::I24_MAX as u64, read_i24, write_i24);
+    qc_byte_order!(prop_u32, u32, ::core::u32::MAX as u64, read_u32, write_u32);
+    qc_byte_order!(prop_i32, i32, ::core::i32::MAX as u64, read_i32, write_i32);
+    qc_byte_order!(prop_u64, u64, ::core::u64::MAX as u64, read_u64, write_u64);
+    qc_byte_order!(prop_i64, i64, ::core::i64::MAX as u64, read_i64, write_i64);
+    qc_byte_order!(prop_f32, f32, ::core::u64::MAX as u64, read_f32, write_f32);
+    qc_byte_order!(prop_f64, f64, ::core::i64::MAX as u64, read_f64, write_f64);
+
+    #[cfg(feature = "i128")]
+    qc_byte_order!(prop_u128, Wi128<u128>, 16 + 1, read_u128, write_u128);
+    #[cfg(feature = "i128")]
+    qc_byte_order!(prop_i128, Wi128<i128>, 16 + 1, read_i128, write_i128);
+
+    qc_byte_order!(prop_uint_1,
+        u64, calc_max!(super::U64_MAX, 1), 1, read_uint, write_uint);
+    qc_byte_order!(prop_uint_2,
+        u64, calc_max!(super::U64_MAX, 2), 2, read_uint, write_uint);
+    qc_byte_order!(prop_uint_3,
+        u64, calc_max!(super::U64_MAX, 3), 3, read_uint, write_uint);
+    qc_byte_order!(prop_uint_4,
+        u64, calc_max!(super::U64_MAX, 4), 4, read_uint, write_uint);
+    qc_byte_order!(prop_uint_5,
+        u64, calc_max!(super::U64_MAX, 5), 5, read_uint, write_uint);
+    qc_byte_order!(prop_uint_6,
+        u64, calc_max!(super::U64_MAX, 6), 6, read_uint, write_uint);
+    qc_byte_order!(prop_uint_7,
+        u64, calc_max!(super::U64_MAX, 7), 7, read_uint, write_uint);
+    qc_byte_order!(prop_uint_8,
+        u64, calc_max!(super::U64_MAX, 8), 8, read_uint, write_uint);
+
+    #[cfg(feature = "i128")]
+    qc_byte_order!(prop_uint128_1,
+        Wi128<u128>, 1, 1, read_uint128, write_uint128);
+    #[cfg(feature = "i128")]
+    qc_byte_order!(prop_uint128_2,
+        Wi128<u128>, 2, 2, read_uint128, write_uint128);
+    #[cfg(feature = "i128")]
+    qc_byte_order!(prop_uint128_3,
+        Wi128<u128>, 3, 3, read_uint128, write_uint128);
+    #[cfg(feature = "i128")]
+    qc_byte_order!(prop_uint128_4,
+        Wi128<u128>, 4, 4, read_uint128, write_uint128);
+    #[cfg(feature = "i128")]
+    qc_byte_order!(prop_uint128_5,
+        Wi128<u128>, 5, 5, read_uint128, write_uint128);
+    #[cfg(feature = "i128")]
+    qc_byte_order!(prop_uint128_6,
+        Wi128<u128>, 6, 6, read_uint128, write_uint128);
+    #[cfg(feature = "i128")]
+    qc_byte_order!(prop_uint128_7,
+        Wi128<u128>, 7, 7, read_uint128, write_uint128);
+    #[cfg(feature = "i128")]
+    qc_byte_order!(prop_uint128_8,
+        Wi128<u128>, 8, 8, read_uint128, write_uint128);
+    #[cfg(feature = "i128")]
+    qc_byte_order!(prop_uint128_9,
+        Wi128<u128>, 9, 9, read_uint128, write_uint128);
+    #[cfg(feature = "i128")]
+    qc_byte_order!(prop_uint128_10,
+        Wi128<u128>, 10, 10, read_uint128, write_uint128);
+    #[cfg(feature = "i128")]
+    qc_byte_order!(prop_uint128_11,
+        Wi128<u128>, 11, 11, read_uint128, write_uint128);
+    #[cfg(feature = "i128")]
+    qc_byte_order!(prop_uint128_12,
+        Wi128<u128>, 12, 12, read_uint128, write_uint128);
+    #[cfg(feature = "i128")]
+    qc_byte_order!(prop_uint128_13,
+        Wi128<u128>, 13, 13, read_uint128, write_uint128);
+    #[cfg(feature = "i128")]
+    qc_byte_order!(prop_uint128_14,
+        Wi128<u128>, 14, 14, read_uint128, write_uint128);
+    #[cfg(feature = "i128")]
+    qc_byte_order!(prop_uint128_15,
+        Wi128<u128>, 15, 15, read_uint128, write_uint128);
+    #[cfg(feature = "i128")]
+    qc_byte_order!(prop_uint128_16,
+        Wi128<u128>, 16, 16, read_uint128, write_uint128);
+
+    qc_byte_order!(prop_int_1,
+        i64, calc_max!(super::I64_MAX, 1), 1, read_int, write_int);
+    qc_byte_order!(prop_int_2,
+        i64, calc_max!(super::I64_MAX, 2), 2, read_int, write_int);
+    qc_byte_order!(prop_int_3,
+        i64, calc_max!(super::I64_MAX, 3), 3, read_int, write_int);
+    qc_byte_order!(prop_int_4,
+        i64, calc_max!(super::I64_MAX, 4), 4, read_int, write_int);
+    qc_byte_order!(prop_int_5,
+        i64, calc_max!(super::I64_MAX, 5), 5, read_int, write_int);
+    qc_byte_order!(prop_int_6,
+        i64, calc_max!(super::I64_MAX, 6), 6, read_int, write_int);
+    qc_byte_order!(prop_int_7,
+        i64, calc_max!(super::I64_MAX, 7), 7, read_int, write_int);
+    qc_byte_order!(prop_int_8,
+        i64, calc_max!(super::I64_MAX, 8), 8, read_int, write_int);
+
+    #[cfg(feature = "i128")]
+    qc_byte_order!(prop_int128_1,
+        Wi128<i128>, 1, 1, read_int128, write_int128);
+    #[cfg(feature = "i128")]
+    qc_byte_order!(prop_int128_2,
+        Wi128<i128>, 2, 2, read_int128, write_int128);
+    #[cfg(feature = "i128")]
+    qc_byte_order!(prop_int128_3,
+        Wi128<i128>, 3, 3, read_int128, write_int128);
+    #[cfg(feature = "i128")]
+    qc_byte_order!(prop_int128_4,
+        Wi128<i128>, 4, 4, read_int128, write_int128);
+    #[cfg(feature = "i128")]
+    qc_byte_order!(prop_int128_5,
+        Wi128<i128>, 5, 5, read_int128, write_int128);
+    #[cfg(feature = "i128")]
+    qc_byte_order!(prop_int128_6,
+        Wi128<i128>, 6, 6, read_int128, write_int128);
+    #[cfg(feature = "i128")]
+    qc_byte_order!(prop_int128_7,
+        Wi128<i128>, 7, 7, read_int128, write_int128);
+    #[cfg(feature = "i128")]
+    qc_byte_order!(prop_int128_8,
+        Wi128<i128>, 8, 8, read_int128, write_int128);
+    #[cfg(feature = "i128")]
+    qc_byte_order!(prop_int128_9,
+        Wi128<i128>, 9, 9, read_int128, write_int128);
+    #[cfg(feature = "i128")]
+    qc_byte_order!(prop_int128_10,
+        Wi128<i128>, 10, 10, read_int128, write_int128);
+    #[cfg(feature = "i128")]
+    qc_byte_order!(prop_int128_11,
+        Wi128<i128>, 11, 11, read_int128, write_int128);
+    #[cfg(feature = "i128")]
+    qc_byte_order!(prop_int128_12,
+        Wi128<i128>, 12, 12, read_int128, write_int128);
+    #[cfg(feature = "i128")]
+    qc_byte_order!(prop_int128_13,
+        Wi128<i128>, 13, 13, read_int128, write_int128);
+    #[cfg(feature = "i128")]
+    qc_byte_order!(prop_int128_14,
+        Wi128<i128>, 14, 14, read_int128, write_int128);
+    #[cfg(feature = "i128")]
+    qc_byte_order!(prop_int128_15,
+        Wi128<i128>, 15, 15, read_int128, write_int128);
+    #[cfg(feature = "i128")]
+    qc_byte_order!(prop_int128_16,
+        Wi128<i128>, 16, 16, read_int128, write_int128);
+
+
+    // Test that all of the byte conversion functions panic when given a
+    // buffer that is too small.
+    //
+    // These tests are critical to ensure safety, otherwise we might end up
+    // with a buffer overflow.
+    macro_rules! too_small {
+        ($name:ident, $maximally_small:expr, $zero:expr,
+         $read:ident, $write:ident) => (
+            mod $name {
+                use {BigEndian, ByteOrder, NativeEndian, LittleEndian};
+
+                #[test]
+                #[should_panic]
+                fn read_big_endian() {
+                    let buf = [0; $maximally_small];
+                    BigEndian::$read(&buf);
+                }
+
+                #[test]
+                #[should_panic]
+                fn read_little_endian() {
+                    let buf = [0; $maximally_small];
+                    LittleEndian::$read(&buf);
+                }
+
+                #[test]
+                #[should_panic]
+                fn read_native_endian() {
+                    let buf = [0; $maximally_small];
+                    NativeEndian::$read(&buf);
+                }
+
+                #[test]
+                #[should_panic]
+                fn write_big_endian() {
+                    let mut buf = [0; $maximally_small];
+                    BigEndian::$write(&mut buf, $zero);
+                }
+
+                #[test]
+                #[should_panic]
+                fn write_little_endian() {
+                    let mut buf = [0; $maximally_small];
+                    LittleEndian::$write(&mut buf, $zero);
+                }
+
+                #[test]
+                #[should_panic]
+                fn write_native_endian() {
+                    let mut buf = [0; $maximally_small];
+                    NativeEndian::$write(&mut buf, $zero);
+                }
+            }
+        );
+        ($name:ident, $maximally_small:expr, $read:ident) => (
+            mod $name {
+                use {BigEndian, ByteOrder, NativeEndian, LittleEndian};
+
+                #[test]
+                #[should_panic]
+                fn read_big_endian() {
+                    let buf = [0; $maximally_small];
+                    BigEndian::$read(&buf, $maximally_small + 1);
+                }
+
+                #[test]
+                #[should_panic]
+                fn read_little_endian() {
+                    let buf = [0; $maximally_small];
+                    LittleEndian::$read(&buf, $maximally_small + 1);
+                }
+
+                #[test]
+                #[should_panic]
+                fn read_native_endian() {
+                    let buf = [0; $maximally_small];
+                    NativeEndian::$read(&buf, $maximally_small + 1);
+                }
+            }
+        );
+    }
+
+    too_small!(small_u16, 1, 0, read_u16, write_u16);
+    too_small!(small_i16, 1, 0, read_i16, write_i16);
+    too_small!(small_u32, 3, 0, read_u32, write_u32);
+    too_small!(small_i32, 3, 0, read_i32, write_i32);
+    too_small!(small_u64, 7, 0, read_u64, write_u64);
+    too_small!(small_i64, 7, 0, read_i64, write_i64);
+    too_small!(small_f32, 3, 0.0, read_f32, write_f32);
+    too_small!(small_f64, 7, 0.0, read_f64, write_f64);
+    #[cfg(feature = "i128")]
+    too_small!(small_u128, 15, 0, read_u128, write_u128);
+    #[cfg(feature = "i128")]
+    too_small!(small_i128, 15, 0, read_i128, write_i128);
+
+    too_small!(small_uint_1, 1, read_uint);
+    too_small!(small_uint_2, 2, read_uint);
+    too_small!(small_uint_3, 3, read_uint);
+    too_small!(small_uint_4, 4, read_uint);
+    too_small!(small_uint_5, 5, read_uint);
+    too_small!(small_uint_6, 6, read_uint);
+    too_small!(small_uint_7, 7, read_uint);
+
+    #[cfg(feature = "i128")]
+    too_small!(small_uint128_1, 1, read_uint128);
+    #[cfg(feature = "i128")]
+    too_small!(small_uint128_2, 2, read_uint128);
+    #[cfg(feature = "i128")]
+    too_small!(small_uint128_3, 3, read_uint128);
+    #[cfg(feature = "i128")]
+    too_small!(small_uint128_4, 4, read_uint128);
+    #[cfg(feature = "i128")]
+    too_small!(small_uint128_5, 5, read_uint128);
+    #[cfg(feature = "i128")]
+    too_small!(small_uint128_6, 6, read_uint128);
+    #[cfg(feature = "i128")]
+    too_small!(small_uint128_7, 7, read_uint128);
+    #[cfg(feature = "i128")]
+    too_small!(small_uint128_8, 8, read_uint128);
+    #[cfg(feature = "i128")]
+    too_small!(small_uint128_9, 9, read_uint128);
+    #[cfg(feature = "i128")]
+    too_small!(small_uint128_10, 10, read_uint128);
+    #[cfg(feature = "i128")]
+    too_small!(small_uint128_11, 11, read_uint128);
+    #[cfg(feature = "i128")]
+    too_small!(small_uint128_12, 12, read_uint128);
+    #[cfg(feature = "i128")]
+    too_small!(small_uint128_13, 13, read_uint128);
+    #[cfg(feature = "i128")]
+    too_small!(small_uint128_14, 14, read_uint128);
+    #[cfg(feature = "i128")]
+    too_small!(small_uint128_15, 15, read_uint128);
+
+    too_small!(small_int_1, 1, read_int);
+    too_small!(small_int_2, 2, read_int);
+    too_small!(small_int_3, 3, read_int);
+    too_small!(small_int_4, 4, read_int);
+    too_small!(small_int_5, 5, read_int);
+    too_small!(small_int_6, 6, read_int);
+    too_small!(small_int_7, 7, read_int);
+
+    #[cfg(feature = "i128")]
+    too_small!(small_int128_1, 1, read_int128);
+    #[cfg(feature = "i128")]
+    too_small!(small_int128_2, 2, read_int128);
+    #[cfg(feature = "i128")]
+    too_small!(small_int128_3, 3, read_int128);
+    #[cfg(feature = "i128")]
+    too_small!(small_int128_4, 4, read_int128);
+    #[cfg(feature = "i128")]
+    too_small!(small_int128_5, 5, read_int128);
+    #[cfg(feature = "i128")]
+    too_small!(small_int128_6, 6, read_int128);
+    #[cfg(feature = "i128")]
+    too_small!(small_int128_7, 7, read_int128);
+    #[cfg(feature = "i128")]
+    too_small!(small_int128_8, 8, read_int128);
+    #[cfg(feature = "i128")]
+    too_small!(small_int128_9, 9, read_int128);
+    #[cfg(feature = "i128")]
+    too_small!(small_int128_10, 10, read_int128);
+    #[cfg(feature = "i128")]
+    too_small!(small_int128_11, 11, read_int128);
+    #[cfg(feature = "i128")]
+    too_small!(small_int128_12, 12, read_int128);
+    #[cfg(feature = "i128")]
+    too_small!(small_int128_13, 13, read_int128);
+    #[cfg(feature = "i128")]
+    too_small!(small_int128_14, 14, read_int128);
+    #[cfg(feature = "i128")]
+    too_small!(small_int128_15, 15, read_int128);
+
+    // Test that reading/writing slices enforces the correct lengths.
+    macro_rules! slice_lengths {
+        ($name:ident, $read:ident, $write:ident,
+         $num_bytes:expr, $numbers:expr) => {
+            mod $name {
+                use {ByteOrder, BigEndian, NativeEndian, LittleEndian};
+
+                #[test]
+                #[should_panic]
+                fn read_big_endian() {
+                    let bytes = [0; $num_bytes];
+                    let mut numbers = $numbers;
+                    BigEndian::$read(&bytes, &mut numbers);
+                }
+
+                #[test]
+                #[should_panic]
+                fn read_little_endian() {
+                    let bytes = [0; $num_bytes];
+                    let mut numbers = $numbers;
+                    LittleEndian::$read(&bytes, &mut numbers);
+                }
+
+                #[test]
+                #[should_panic]
+                fn read_native_endian() {
+                    let bytes = [0; $num_bytes];
+                    let mut numbers = $numbers;
+                    NativeEndian::$read(&bytes, &mut numbers);
+                }
+
+                #[test]
+                #[should_panic]
+                fn write_big_endian() {
+                    let mut bytes = [0; $num_bytes];
+                    let numbers = $numbers;
+                    BigEndian::$write(&numbers, &mut bytes);
+                }
+
+                #[test]
+                #[should_panic]
+                fn write_little_endian() {
+                    let mut bytes = [0; $num_bytes];
+                    let numbers = $numbers;
+                    LittleEndian::$write(&numbers, &mut bytes);
+                }
+
+                #[test]
+                #[should_panic]
+                fn write_native_endian() {
+                    let mut bytes = [0; $num_bytes];
+                    let numbers = $numbers;
+                    NativeEndian::$write(&numbers, &mut bytes);
+                }
+            }
+        }
+    }
+
+    slice_lengths!(
+        slice_len_too_small_u16, read_u16_into, write_u16_into, 3, [0, 0]);
+    slice_lengths!(
+        slice_len_too_big_u16, read_u16_into, write_u16_into, 5, [0, 0]);
+    slice_lengths!(
+        slice_len_too_small_i16, read_i16_into, write_i16_into, 3, [0, 0]);
+    slice_lengths!(
+        slice_len_too_big_i16, read_i16_into, write_i16_into, 5, [0, 0]);
+
+    slice_lengths!(
+        slice_len_too_small_u32, read_u32_into, write_u32_into, 7, [0, 0]);
+    slice_lengths!(
+        slice_len_too_big_u32, read_u32_into, write_u32_into, 9, [0, 0]);
+    slice_lengths!(
+        slice_len_too_small_i32, read_i32_into, write_i32_into, 7, [0, 0]);
+    slice_lengths!(
+        slice_len_too_big_i32, read_i32_into, write_i32_into, 9, [0, 0]);
+
+    slice_lengths!(
+        slice_len_too_small_u64, read_u64_into, write_u64_into, 15, [0, 0]);
+    slice_lengths!(
+        slice_len_too_big_u64, read_u64_into, write_u64_into, 17, [0, 0]);
+    slice_lengths!(
+        slice_len_too_small_i64, read_i64_into, write_i64_into, 15, [0, 0]);
+    slice_lengths!(
+        slice_len_too_big_i64, read_i64_into, write_i64_into, 17, [0, 0]);
+
+    #[cfg(feature = "i128")]
+    slice_lengths!(
+        slice_len_too_small_u128, read_u128_into, write_u128_into, 31, [0, 0]);
+    #[cfg(feature = "i128")]
+    slice_lengths!(
+        slice_len_too_big_u128, read_u128_into, write_u128_into, 33, [0, 0]);
+    #[cfg(feature = "i128")]
+    slice_lengths!(
+        slice_len_too_small_i128, read_i128_into, write_i128_into, 31, [0, 0]);
+    #[cfg(feature = "i128")]
+    slice_lengths!(
+        slice_len_too_big_i128, read_i128_into, write_i128_into, 33, [0, 0]);
+
+    #[test]
+    fn uint_bigger_buffer() {
+        use {ByteOrder, LittleEndian};
+        let n = LittleEndian::read_uint(&[1, 2, 3, 4, 5, 6, 7, 8], 5);
+        assert_eq!(n, 0x0504030201);
+    }
+
+    #[test]
+    fn read_snan() {
+        use core::f32;
+        use core::f64;
+        use core::mem::transmute;
+
+        use {ByteOrder, BigEndian, LittleEndian};
+
+        let sf = BigEndian::read_f32(&[0xFF, 0x80, 0x00, 0x01]);
+        let sbits: u32 = unsafe { transmute(sf) };
+        assert_eq!(sbits, unsafe { transmute(f32::NAN) });
+        assert_eq!(sf.classify(), ::core::num::FpCategory::Nan);
+
+        let df = BigEndian::read_f64(&[0x7F, 0xF0, 0, 0, 0, 0, 0, 0x01]);
+        let dbits: u64 = unsafe { ::core::mem::transmute(df) };
+        assert_eq!(dbits, unsafe { transmute(f64::NAN) });
+        assert_eq!(df.classify(), ::core::num::FpCategory::Nan);
+
+        let sf = LittleEndian::read_f32(&[0x01, 0x00, 0x80, 0xFF]);
+        let sbits: u32 = unsafe { transmute(sf) };
+        assert_eq!(sbits, unsafe { transmute(f32::NAN) });
+        assert_eq!(sf.classify(), ::core::num::FpCategory::Nan);
+
+        let df = LittleEndian::read_f64(&[0x01, 0, 0, 0, 0, 0, 0xF0, 0x7F]);
+        let dbits: u64 = unsafe { ::core::mem::transmute(df) };
+        assert_eq!(dbits, unsafe { transmute(f64::NAN) });
+        assert_eq!(df.classify(), ::core::num::FpCategory::Nan);
+    }
+}
+
+#[cfg(test)]
+#[cfg(feature = "std")]
+mod stdtests {
+    extern crate quickcheck;
+    extern crate rand;
+
+    use self::quickcheck::{QuickCheck, StdGen, Testable};
+    use self::rand::thread_rng;
+
+    fn qc_unsized<A: Testable>(f: A) {
+
+        QuickCheck::new()
+            .gen(StdGen::new(thread_rng(), 16))
+            .tests(1_00)
+            .max_tests(10_000)
+            .quickcheck(f);
+    }
+
+    macro_rules! calc_max {
+        ($max:expr, $bytes:expr) => { ($max - 1) >> (8 * (8 - $bytes)) };
+    }
+
+    macro_rules! qc_bytes_ext {
+        ($name:ident, $ty_int:ty, $max:expr,
+         $bytes:expr, $read:ident, $write:ident) => (
+            mod $name {
+                use std::io::Cursor;
+                use {
+                    ReadBytesExt, WriteBytesExt,
+                    BigEndian, NativeEndian, LittleEndian,
+                };
+                #[allow(unused_imports)] use test::{qc_sized, Wi128};
+
+                #[test]
+                fn big_endian() {
+                    fn prop(n: $ty_int) -> bool {
+                        let mut wtr = vec![];
+                        wtr.$write::<BigEndian>(n.clone()).unwrap();
+                        let mut rdr = Vec::new();
+                        rdr.extend(wtr[wtr.len()-$bytes..].iter().map(|&x| x));
+                        let mut rdr = Cursor::new(rdr);
+                        n == rdr.$read::<BigEndian>($bytes).unwrap()
+                    }
+                    qc_sized(prop as fn($ty_int) -> bool, $max);
+                }
+
+                #[test]
+                fn little_endian() {
+                    fn prop(n: $ty_int) -> bool {
+                        let mut wtr = vec![];
+                        wtr.$write::<LittleEndian>(n.clone()).unwrap();
+                        let mut rdr = Cursor::new(wtr);
+                        n == rdr.$read::<LittleEndian>($bytes).unwrap()
+                    }
+                    qc_sized(prop as fn($ty_int) -> bool, $max);
+                }
+
+                #[test]
+                fn native_endian() {
+                    fn prop(n: $ty_int) -> bool {
+                        let mut wtr = vec![];
+                        wtr.$write::<NativeEndian>(n.clone()).unwrap();
+                        let mut rdr = Cursor::new(wtr);
+                        n == rdr.$read::<NativeEndian>($bytes).unwrap()
+                    }
+                    qc_sized(prop as fn($ty_int) -> bool, $max);
+                }
+            }
+        );
+        ($name:ident, $ty_int:ty, $max:expr, $read:ident, $write:ident) => (
+            mod $name {
+                use std::io::Cursor;
+                use {
+                    ReadBytesExt, WriteBytesExt,
+                    BigEndian, NativeEndian, LittleEndian,
+                };
+                #[allow(unused_imports)] use test::{qc_sized, Wi128};
+
+                #[test]
+                fn big_endian() {
+                    fn prop(n: $ty_int) -> bool {
+                        let mut wtr = vec![];
+                        wtr.$write::<BigEndian>(n.clone()).unwrap();
+                        let mut rdr = Cursor::new(wtr);
+                        n == rdr.$read::<BigEndian>().unwrap()
+                    }
+                    qc_sized(prop as fn($ty_int) -> bool, $max - 1);
+                }
+
+                #[test]
+                fn little_endian() {
+                    fn prop(n: $ty_int) -> bool {
+                        let mut wtr = vec![];
+                        wtr.$write::<LittleEndian>(n.clone()).unwrap();
+                        let mut rdr = Cursor::new(wtr);
+                        n == rdr.$read::<LittleEndian>().unwrap()
+                    }
+                    qc_sized(prop as fn($ty_int) -> bool, $max - 1);
+                }
+
+                #[test]
+                fn native_endian() {
+                    fn prop(n: $ty_int) -> bool {
+                        let mut wtr = vec![];
+                        wtr.$write::<NativeEndian>(n.clone()).unwrap();
+                        let mut rdr = Cursor::new(wtr);
+                        n == rdr.$read::<NativeEndian>().unwrap()
+                    }
+                    qc_sized(prop as fn($ty_int) -> bool, $max - 1);
+                }
+            }
+        );
+    }
+
+    qc_bytes_ext!(prop_ext_u16,
+        u16, ::std::u16::MAX as u64, read_u16, write_u16);
+    qc_bytes_ext!(prop_ext_i16,
+        i16, ::std::i16::MAX as u64, read_i16, write_i16);
+    qc_bytes_ext!(prop_ext_u32,
+        u32, ::std::u32::MAX as u64, read_u32, write_u32);
+    qc_bytes_ext!(prop_ext_i32,
+        i32, ::std::i32::MAX as u64, read_i32, write_i32);
+    qc_bytes_ext!(prop_ext_u64,
+        u64, ::std::u64::MAX as u64, read_u64, write_u64);
+    qc_bytes_ext!(prop_ext_i64,
+        i64, ::std::i64::MAX as u64, read_i64, write_i64);
+    qc_bytes_ext!(prop_ext_f32,
+        f32, ::std::u64::MAX as u64, read_f32, write_f32);
+    qc_bytes_ext!(prop_ext_f64,
+        f64, ::std::i64::MAX as u64, read_f64, write_f64);
+
+    #[cfg(feature = "i128")]
+    qc_bytes_ext!(prop_ext_u128, Wi128<u128>, 16 + 1, read_u128, write_u128);
+    #[cfg(feature = "i128")]
+    qc_bytes_ext!(prop_ext_i128, Wi128<i128>, 16 + 1, read_i128, write_i128);
+
+    qc_bytes_ext!(prop_ext_uint_1,
+        u64, calc_max!(::test::U64_MAX, 1), 1, read_uint, write_u64);
+    qc_bytes_ext!(prop_ext_uint_2,
+        u64, calc_max!(::test::U64_MAX, 2), 2, read_uint, write_u64);
+    qc_bytes_ext!(prop_ext_uint_3,
+        u64, calc_max!(::test::U64_MAX, 3), 3, read_uint, write_u64);
+    qc_bytes_ext!(prop_ext_uint_4,
+        u64, calc_max!(::test::U64_MAX, 4), 4, read_uint, write_u64);
+    qc_bytes_ext!(prop_ext_uint_5,
+        u64, calc_max!(::test::U64_MAX, 5), 5, read_uint, write_u64);
+    qc_bytes_ext!(prop_ext_uint_6,
+        u64, calc_max!(::test::U64_MAX, 6), 6, read_uint, write_u64);
+    qc_bytes_ext!(prop_ext_uint_7,
+        u64, calc_max!(::test::U64_MAX, 7), 7, read_uint, write_u64);
+    qc_bytes_ext!(prop_ext_uint_8,
+        u64, calc_max!(::test::U64_MAX, 8), 8, read_uint, write_u64);
+
+    #[cfg(feature = "i128")]
+    qc_bytes_ext!(prop_ext_uint128_1,
+        Wi128<u128>, 1, 1, read_uint128, write_u128);
+    #[cfg(feature = "i128")]
+    qc_bytes_ext!(prop_ext_uint128_2,
+        Wi128<u128>, 2, 2, read_uint128, write_u128);
+    #[cfg(feature = "i128")]
+    qc_bytes_ext!(prop_ext_uint128_3,
+        Wi128<u128>, 3, 3, read_uint128, write_u128);
+    #[cfg(feature = "i128")]
+    qc_bytes_ext!(prop_ext_uint128_4,
+        Wi128<u128>, 4, 4, read_uint128, write_u128);
+    #[cfg(feature = "i128")]
+    qc_bytes_ext!(prop_ext_uint128_5,
+        Wi128<u128>, 5, 5, read_uint128, write_u128);
+    #[cfg(feature = "i128")]
+    qc_bytes_ext!(prop_ext_uint128_6,
+        Wi128<u128>, 6, 6, read_uint128, write_u128);
+    #[cfg(feature = "i128")]
+    qc_bytes_ext!(prop_ext_uint128_7,
+        Wi128<u128>, 7, 7, read_uint128, write_u128);
+    #[cfg(feature = "i128")]
+    qc_bytes_ext!(prop_ext_uint128_8,
+        Wi128<u128>, 8, 8, read_uint128, write_u128);
+    #[cfg(feature = "i128")]
+    qc_bytes_ext!(prop_ext_uint128_9,
+        Wi128<u128>, 9, 9, read_uint128, write_u128);
+    #[cfg(feature = "i128")]
+    qc_bytes_ext!(prop_ext_uint128_10,
+        Wi128<u128>, 10, 10, read_uint128, write_u128);
+    #[cfg(feature = "i128")]
+    qc_bytes_ext!(prop_ext_uint128_11,
+        Wi128<u128>, 11, 11, read_uint128, write_u128);
+    #[cfg(feature = "i128")]
+    qc_bytes_ext!(prop_ext_uint128_12,
+        Wi128<u128>, 12, 12, read_uint128, write_u128);
+    #[cfg(feature = "i128")]
+    qc_bytes_ext!(prop_ext_uint128_13,
+        Wi128<u128>, 13, 13, read_uint128, write_u128);
+    #[cfg(feature = "i128")]
+    qc_bytes_ext!(prop_ext_uint128_14,
+        Wi128<u128>, 14, 14, read_uint128, write_u128);
+    #[cfg(feature = "i128")]
+    qc_bytes_ext!(prop_ext_uint128_15,
+        Wi128<u128>, 15, 15, read_uint128, write_u128);
+    #[cfg(feature = "i128")]
+    qc_bytes_ext!(prop_ext_uint128_16,
+        Wi128<u128>, 16, 16, read_uint128, write_u128);
+
+    qc_bytes_ext!(prop_ext_int_1,
+        i64, calc_max!(::test::I64_MAX, 1), 1, read_int, write_i64);
+    qc_bytes_ext!(prop_ext_int_2,
+        i64, calc_max!(::test::I64_MAX, 2), 2, read_int, write_i64);
+    qc_bytes_ext!(prop_ext_int_3,
+        i64, calc_max!(::test::I64_MAX, 3), 3, read_int, write_i64);
+    qc_bytes_ext!(prop_ext_int_4,
+        i64, calc_max!(::test::I64_MAX, 4), 4, read_int, write_i64);
+    qc_bytes_ext!(prop_ext_int_5,
+        i64, calc_max!(::test::I64_MAX, 5), 5, read_int, write_i64);
+    qc_bytes_ext!(prop_ext_int_6,
+        i64, calc_max!(::test::I64_MAX, 6), 6, read_int, write_i64);
+    qc_bytes_ext!(prop_ext_int_7,
+        i64, calc_max!(::test::I64_MAX, 1), 7, read_int, write_i64);
+    qc_bytes_ext!(prop_ext_int_8,
+        i64, calc_max!(::test::I64_MAX, 8), 8, read_int, write_i64);
+
+    #[cfg(feature = "i128")]
+    qc_bytes_ext!(prop_ext_int128_1,
+        Wi128<i128>, 1, 1, read_int128, write_i128);
+    #[cfg(feature = "i128")]
+    qc_bytes_ext!(prop_ext_int128_2,
+        Wi128<i128>, 2, 2, read_int128, write_i128);
+    #[cfg(feature = "i128")]
+    qc_bytes_ext!(prop_ext_int128_3,
+        Wi128<i128>, 3, 3, read_int128, write_i128);
+    #[cfg(feature = "i128")]
+    qc_bytes_ext!(prop_ext_int128_4,
+        Wi128<i128>, 4, 4, read_int128, write_i128);
+    #[cfg(feature = "i128")]
+    qc_bytes_ext!(prop_ext_int128_5,
+        Wi128<i128>, 5, 5, read_int128, write_i128);
+    #[cfg(feature = "i128")]
+    qc_bytes_ext!(prop_ext_int128_6,
+        Wi128<i128>, 6, 6, read_int128, write_i128);
+    #[cfg(feature = "i128")]
+    qc_bytes_ext!(prop_ext_int128_7,
+        Wi128<i128>, 7, 7, read_int128, write_i128);
+    #[cfg(feature = "i128")]
+    qc_bytes_ext!(prop_ext_int128_8,
+        Wi128<i128>, 8, 8, read_int128, write_i128);
+    #[cfg(feature = "i128")]
+    qc_bytes_ext!(prop_ext_int128_9,
+        Wi128<i128>, 9, 9, read_int128, write_i128);
+    #[cfg(feature = "i128")]
+    qc_bytes_ext!(prop_ext_int128_10,
+        Wi128<i128>, 10, 10, read_int128, write_i128);
+    #[cfg(feature = "i128")]
+    qc_bytes_ext!(prop_ext_int128_11,
+        Wi128<i128>, 11, 11, read_int128, write_i128);
+    #[cfg(feature = "i128")]
+    qc_bytes_ext!(prop_ext_int128_12,
+        Wi128<i128>, 12, 12, read_int128, write_i128);
+    #[cfg(feature = "i128")]
+    qc_bytes_ext!(prop_ext_int128_13,
+        Wi128<i128>, 13, 13, read_int128, write_i128);
+    #[cfg(feature = "i128")]
+    qc_bytes_ext!(prop_ext_int128_14,
+        Wi128<i128>, 14, 14, read_int128, write_i128);
+    #[cfg(feature = "i128")]
+    qc_bytes_ext!(prop_ext_int128_15,
+        Wi128<i128>, 15, 15, read_int128, write_i128);
+    #[cfg(feature = "i128")]
+    qc_bytes_ext!(prop_ext_int128_16,
+        Wi128<i128>, 16, 16, read_int128, write_i128);
+
+    // Test slice serialization/deserialization.
+    macro_rules! qc_slice {
+        ($name:ident, $ty_int:ty, $read:ident, $write:ident, $zero:expr) => {
+            mod $name {
+                use core::mem::size_of;
+                use {ByteOrder, BigEndian, NativeEndian, LittleEndian};
+                use super::qc_unsized;
+                #[allow(unused_imports)]
+                use test::Wi128;
+
+                #[test]
+                fn big_endian() {
+                    #[allow(unused_unsafe)]
+                    fn prop(numbers: Vec<$ty_int>) -> bool {
+                        let numbers: Vec<_> = numbers
+                            .into_iter()
+                            .map(|x| x.clone())
+                            .collect();
+                        let num_bytes = size_of::<$ty_int>() * numbers.len();
+                        let mut bytes = vec![0; num_bytes];
+
+                        BigEndian::$write(&numbers, &mut bytes);
+
+                        let mut got = vec![$zero; numbers.len()];
+                        unsafe { BigEndian::$read(&bytes, &mut got); }
+
+                        numbers == got
+                    }
+                    qc_unsized(prop as fn(_) -> bool);
+                }
+
+                #[test]
+                fn little_endian() {
+                    #[allow(unused_unsafe)]
+                    fn prop(numbers: Vec<$ty_int>) -> bool {
+                        let numbers: Vec<_> = numbers
+                            .into_iter()
+                            .map(|x| x.clone())
+                            .collect();
+                        let num_bytes = size_of::<$ty_int>() * numbers.len();
+                        let mut bytes = vec![0; num_bytes];
+
+                        LittleEndian::$write(&numbers, &mut bytes);
+
+                        let mut got = vec![$zero; numbers.len()];
+                        unsafe { LittleEndian::$read(&bytes, &mut got); }
+
+                        numbers == got
+                    }
+                    qc_unsized(prop as fn(_) -> bool);
+                }
+
+                #[test]
+                fn native_endian() {
+                    #[allow(unused_unsafe)]
+                    fn prop(numbers: Vec<$ty_int>) -> bool {
+                        let numbers: Vec<_> = numbers
+                            .into_iter()
+                            .map(|x| x.clone())
+                            .collect();
+                        let num_bytes = size_of::<$ty_int>() * numbers.len();
+                        let mut bytes = vec![0; num_bytes];
+
+                        NativeEndian::$write(&numbers, &mut bytes);
+
+                        let mut got = vec![$zero; numbers.len()];
+                        unsafe { NativeEndian::$read(&bytes, &mut got); }
+
+                        numbers == got
+                    }
+                    qc_unsized(prop as fn(_) -> bool);
+                }
+            }
+        }
+    }
+
+    qc_slice!(prop_slice_u16, u16, read_u16_into, write_u16_into, 0);
+    qc_slice!(prop_slice_i16, i16, read_i16_into, write_i16_into, 0);
+    qc_slice!(prop_slice_u32, u32, read_u32_into, write_u32_into, 0);
+    qc_slice!(prop_slice_i32, i32, read_i32_into, write_i32_into, 0);
+    qc_slice!(prop_slice_u64, u64, read_u64_into, write_u64_into, 0);
+    qc_slice!(prop_slice_i64, i64, read_i64_into, write_i64_into, 0);
+    #[cfg(feature = "i128")]
+    qc_slice!(
+        prop_slice_u128, Wi128<u128>, read_u128_into, write_u128_into, 0);
+    #[cfg(feature = "i128")]
+    qc_slice!(
+        prop_slice_i128, Wi128<i128>, read_i128_into, write_i128_into, 0);
+
+    qc_slice!(
+        prop_slice_f32, f32, read_f32_into_unchecked, write_f32_into, 0.0);
+    qc_slice!(
+        prop_slice_f64, f64, read_f64_into_unchecked, write_f64_into, 0.0);
+}
--- a/third_party/rust/byteorder/.cargo-checksum.json
+++ b/third_party/rust/byteorder/.cargo-checksum.json
@@ -1,1 +1,1 @@
-{"files":{".travis.yml":"a798200a7a2a7b499b4c44f0e516cd8975dc5f4b933144d1e2b1523087330b95","CHANGELOG.md":"caa17ca58eafcd282ed7b8bd47ef0670ce30a20aad339bf2758469f09fa4559d","COPYING":"01c266bced4a434da0051174d6bee16a4c82cf634e2679b6155d40d75012390f","Cargo.toml":"0e636678a02b111d1ebdfdc8ac5a835a2a41370028eeadf6d5fbfd3239f531f8","LICENSE-MIT":"0f96a83840e146e43c0ec96a22ec1f392e0680e6c1226e6f3ba87e0740af850f","README.md":"0559514b9d7488e96fb7a2f3c043a62fadf3495a1e10602d109ce79ee67da998","UNLICENSE":"7e12e5df4bae12cb21581ba157ced20e1986a0508dd10d0e8a4ab9a4cf94e85c","benches/bench.rs":"250d46461a0529a856d76a6421fd45c499bccba2c532e05dbf438c94582a8eac","src/io.rs":"5429f522221b3cce8a5c90fba7ad98b0ddad4fab44acc39763e6adabd511c021","src/lib.rs":"d31f218ca1892bea2812dd575ceb700779de704dc8bf1b9a778315ab75343c5d"},"package":"ff81738b726f5d099632ceaffe7fb65b90212e8dce59d518729e7e8634032d3d"}
\ No newline at end of file
+{"files":{".travis.yml":"a798200a7a2a7b499b4c44f0e516cd8975dc5f4b933144d1e2b1523087330b95","CHANGELOG.md":"750ff16a714caad77a272a62b4baed5ea113ead2846f8c3968342e592a99ecd5","COPYING":"01c266bced4a434da0051174d6bee16a4c82cf634e2679b6155d40d75012390f","Cargo.toml":"cd633b2d76dd5d57191388e7cc31340eb2d6b89e2f98f587999dc685d977c673","LICENSE-MIT":"0f96a83840e146e43c0ec96a22ec1f392e0680e6c1226e6f3ba87e0740af850f","README.md":"97c01a66dbff4615acd49a8c3a85d137bf29cc113fa514910195bb11aef445bc","UNLICENSE":"7e12e5df4bae12cb21581ba157ced20e1986a0508dd10d0e8a4ab9a4cf94e85c","benches/bench.rs":"250d46461a0529a856d76a6421fd45c499bccba2c532e05dbf438c94582a8eac","src/io.rs":"4221711399f9723ef21c5b07700b8e9319f6f665b1eaaceb49528f6e976a25a9","src/lib.rs":"07e5f53bf3b9e30f1da9f4cf37797b77ce3d16c9f2a3a3e56669dd323debd1b9"},"package":"652805b7e73fada9d85e9a6682a4abd490cb52d96aeecc12e33a0de34dfd0d23"}
\ No newline at end of file
--- a/third_party/rust/byteorder/CHANGELOG.md
+++ b/third_party/rust/byteorder/CHANGELOG.md
@@ -1,8 +1,30 @@
+1.2.1
+=====
+This patch release removes more unnecessary uses of `unsafe` that
+were overlooked in the prior `1.2.0` release. In particular, the
+`ReadBytesExt::read_{f32,f64}_into_checked` methods have been deprecated and
+replaced by more appropriately named `read_{f32,f64}_into` methods.
+
+
+1.2.0
+=====
+The most prominent change in this release of `byteorder` is the removal of
+unnecessary signaling NaN masking, and in turn, the `unsafe` annotations
+associated with methods that didn't do masking. See
+[#103](https://github.com/BurntSushi/byteorder/issues/103)
+for more details.
+
+* [BUG #102](https://github.com/BurntSushi/byteorder/issues/102):
+  Fix big endian tests.
+* [BUG #103](https://github.com/BurntSushi/byteorder/issues/103):
+  Remove sNaN masking.
+
+
 1.1.0
 =====
 This release of `byteorder` features a number of fixes and improvements, mostly
 as a result of the
 [Litz Blitz evaluation](https://public.etherpad-mozilla.org/p/rust-crate-eval-byteorder).
 
 Feature enhancements:
 
--- a/third_party/rust/byteorder/Cargo.toml
+++ b/third_party/rust/byteorder/Cargo.toml
@@ -7,38 +7,37 @@
 #
 # If you believe there's an error in this file please file an
 # issue against the rust-lang/cargo repository. If you're
 # editing this file be aware that the upstream Cargo.toml
 # will likely look very different (and much more reasonable)
 
 [package]
 name = "byteorder"
-version = "1.1.0"
+version = "1.2.1"
 authors = ["Andrew Gallant <jamslam@gmail.com>"]
 description = "Library for reading/writing numbers in big-endian and little-endian."
 homepage = "https://github.com/BurntSushi/byteorder"
 documentation = "https://docs.rs/byteorder"
 readme = "README.md"
 keywords = ["byte", "endian", "big-endian", "little-endian", "binary"]
 categories = ["encoding", "parsing"]
 license = "Unlicense/MIT"
 repository = "https://github.com/BurntSushi/byteorder"
 [profile.bench]
 opt-level = 3
 
 [lib]
 name = "byteorder"
 bench = false
-[dev-dependencies.rand]
-version = "0.3"
-
 [dev-dependencies.quickcheck]
 version = "0.4"
 default-features = false
 
+[dev-dependencies.rand]
+version = "0.3"
+
 [features]
 default = ["std"]
 i128 = []
 std = []
 [badges.travis-ci]
-branch = "master"
-repository = "https://github.com/BurntSushi/byteorder"
+repository = "BurntSushi/byteorder"
--- a/third_party/rust/byteorder/README.md
+++ b/third_party/rust/byteorder/README.md
@@ -1,12 +1,12 @@
 This crate provides convenience methods for encoding and decoding numbers in
 either big-endian or little-endian order.
 
-[![Build status](https://api.travis-ci.org/BurntSushi/byteorder.png)](https://travis-ci.org/BurntSushi/byteorder)
+[![Build status](https://api.travis-ci.org/BurntSushi/byteorder.svg)](https://travis-ci.org/BurntSushi/byteorder)
 [![](http://meritbadge.herokuapp.com/byteorder)](https://crates.io/crates/byteorder)
 
 Dual-licensed under MIT or the [UNLICENSE](http://unlicense.org).
 
 
 ### Documentation
 
 https://docs.rs/byteorder
--- a/third_party/rust/byteorder/src/io.rs
+++ b/third_party/rust/byteorder/src/io.rs
@@ -1,11 +1,10 @@
 use std::io::{self, Result};
 use std::slice;
-// use std::mem::transmute;
 
 use ByteOrder;
 
 /// Extends `Read` with methods for reading numbers. (For `std::io`.)
 ///
 /// Most of the methods defined here have an unconstrained type parameter that
 /// must be explicitly instantiated. Typically, it is instantiated with either
 /// the `BigEndian` or `LittleEndian` types defined in this crate.
@@ -504,17 +503,17 @@ pub trait ReadBytesExt: io::Read {
     /// let mut rdr = Cursor::new(vec![2, 5, 3, 0]);
     /// let mut dst = [0; 2];
     /// rdr.read_u16_into::<BigEndian>(&mut dst).unwrap();
     /// assert_eq!([517, 768], dst);
     /// ```
     #[inline]
     fn read_u16_into<T: ByteOrder>(&mut self, dst: &mut [u16]) -> Result<()> {
         {
-            let mut buf = unsafe { slice_to_u8_mut(dst) };
+            let buf = unsafe { slice_to_u8_mut(dst) };
             try!(self.read_exact(buf));
         }
         T::from_slice_u16(dst);
         Ok(())
     }
 
     /// Reads a sequence of unsigned 32 bit integers from the underlying
     /// reader.
@@ -539,17 +538,17 @@ pub trait ReadBytesExt: io::Read {
     /// let mut rdr = Cursor::new(vec![0, 0, 2, 5, 0, 0, 3, 0]);
     /// let mut dst = [0; 2];
     /// rdr.read_u32_into::<BigEndian>(&mut dst).unwrap();
     /// assert_eq!([517, 768], dst);
     /// ```
     #[inline]
     fn read_u32_into<T: ByteOrder>(&mut self, dst: &mut [u32]) -> Result<()> {
         {
-            let mut buf = unsafe { slice_to_u8_mut(dst) };
+            let buf = unsafe { slice_to_u8_mut(dst) };
             try!(self.read_exact(buf));
         }
         T::from_slice_u32(dst);
         Ok(())
     }
 
     /// Reads a sequence of unsigned 64 bit integers from the underlying
     /// reader.
@@ -577,17 +576,17 @@ pub trait ReadBytesExt: io::Read {
     /// ]);
     /// let mut dst = [0; 2];
     /// rdr.read_u64_into::<BigEndian>(&mut dst).unwrap();
     /// assert_eq!([517, 768], dst);
     /// ```
     #[inline]
     fn read_u64_into<T: ByteOrder>(&mut self, dst: &mut [u64]) -> Result<()> {
         {
-            let mut buf = unsafe { slice_to_u8_mut(dst) };
+            let buf = unsafe { slice_to_u8_mut(dst) };
             try!(self.read_exact(buf));
         }
         T::from_slice_u64(dst);
         Ok(())
     }
 
     /// Reads a sequence of unsigned 128 bit integers from the underlying
     /// reader.
@@ -654,17 +653,17 @@ pub trait ReadBytesExt: io::Read {
     /// let mut rdr = Cursor::new(vec![2, 5, 3, 0]);
     /// let mut dst = [0; 2];
     /// rdr.read_i16_into::<BigEndian>(&mut dst).unwrap();
     /// assert_eq!([517, 768], dst);
     /// ```
     #[inline]
     fn read_i16_into<T: ByteOrder>(&mut self, dst: &mut [i16]) -> Result<()> {
         {
-            let mut buf = unsafe { slice_to_u8_mut(dst) };
+            let buf = unsafe { slice_to_u8_mut(dst) };
             try!(self.read_exact(buf));
         }
         T::from_slice_i16(dst);
         Ok(())
     }
 
     /// Reads a sequence of signed 32 bit integers from the underlying
     /// reader.
@@ -689,17 +688,17 @@ pub trait ReadBytesExt: io::Read {
     /// let mut rdr = Cursor::new(vec![0, 0, 2, 5, 0, 0, 3, 0]);
     /// let mut dst = [0; 2];
     /// rdr.read_i32_into::<BigEndian>(&mut dst).unwrap();
     /// assert_eq!([517, 768], dst);
     /// ```
     #[inline]
     fn read_i32_into<T: ByteOrder>(&mut self, dst: &mut [i32]) -> Result<()> {
         {
-            let mut buf = unsafe { slice_to_u8_mut(dst) };
+            let buf = unsafe { slice_to_u8_mut(dst) };
             try!(self.read_exact(buf));
         }
         T::from_slice_i32(dst);
         Ok(())
     }
 
     /// Reads a sequence of signed 64 bit integers from the underlying
     /// reader.
@@ -727,17 +726,17 @@ pub trait ReadBytesExt: io::Read {
     /// ]);
     /// let mut dst = [0; 2];
     /// rdr.read_i64_into::<BigEndian>(&mut dst).unwrap();
     /// assert_eq!([517, 768], dst);
     /// ```
     #[inline]
     fn read_i64_into<T: ByteOrder>(&mut self, dst: &mut [i64]) -> Result<()> {
         {
-            let mut buf = unsafe { slice_to_u8_mut(dst) };
+            let buf = unsafe { slice_to_u8_mut(dst) };
             try!(self.read_exact(buf));
         }
         T::from_slice_i64(dst);
         Ok(())
     }
 
     /// Reads a sequence of signed 128 bit integers from the underlying
     /// reader.
@@ -782,21 +781,63 @@ pub trait ReadBytesExt: io::Read {
     }
 
     /// Reads a sequence of IEEE754 single-precision (4 bytes) floating
     /// point numbers from the underlying reader.
     ///
     /// The given buffer is either filled completely or an error is returned.
     /// If an error is returned, the contents of `dst` are unspecified.
     ///
-    /// # Safety
+    /// # Errors
+    ///
+    /// This method returns the same errors as [`Read::read_exact`].
+    ///
+    /// [`Read::read_exact`]: https://doc.rust-lang.org/std/io/trait.Read.html#method.read_exact
+    ///
+    /// # Examples
+    ///
+    /// Read a sequence of big-endian single-precision floating point number
+    /// from a `Read`:
+    ///
+    /// ```rust
+    /// use std::f32;
+    /// use std::io::Cursor;
+    ///
+    /// use byteorder::{BigEndian, ReadBytesExt};
     ///
-    /// This method is unsafe because there are no guarantees made about the
-    /// floating point values. In particular, this method does not check for
-    /// signaling NaNs, which may result in undefined behavior.
+    /// let mut rdr = Cursor::new(vec![
+    ///     0x40, 0x49, 0x0f, 0xdb,
+    ///     0x3f, 0x80, 0x00, 0x00,
+    /// ]);
+    /// let mut dst = [0.0; 2];
+    /// rdr.read_f32_into::<BigEndian>(&mut dst).unwrap();
+    /// assert_eq!([f32::consts::PI, 1.0], dst);
+    /// ```
+    #[inline]
+    fn read_f32_into<T: ByteOrder>(
+        &mut self,
+        dst: &mut [f32],
+    ) -> Result<()> {
+        {
+            let buf = unsafe { slice_to_u8_mut(dst) };
+            try!(self.read_exact(buf));
+        }
+        T::from_slice_f32(dst);
+        Ok(())
+    }
+
+    /// **DEPRECATED**.
+    ///
+    /// This method is deprecated. Use `read_f32_into` instead.
+    ///
+    /// Reads a sequence of IEEE754 single-precision (4 bytes) floating
+    /// point numbers from the underlying reader.
+    ///
+    /// The given buffer is either filled completely or an error is returned.
+    /// If an error is returned, the contents of `dst` are unspecified.
     ///
     /// # Errors
     ///
     /// This method returns the same errors as [`Read::read_exact`].
     ///
     /// [`Read::read_exact`]: https://doc.rust-lang.org/std/io/trait.Read.html#method.read_exact
     ///
     /// # Examples
@@ -810,34 +851,75 @@ pub trait ReadBytesExt: io::Read {
     ///
     /// use byteorder::{BigEndian, ReadBytesExt};
     ///
     /// let mut rdr = Cursor::new(vec![
     ///     0x40, 0x49, 0x0f, 0xdb,
     ///     0x3f, 0x80, 0x00, 0x00,
     /// ]);
     /// let mut dst = [0.0; 2];
-    /// unsafe {
-    ///     rdr.read_f32_into_unchecked::<BigEndian>(&mut dst).unwrap();
-    /// }
+    /// rdr.read_f32_into_unchecked::<BigEndian>(&mut dst).unwrap();
     /// assert_eq!([f32::consts::PI, 1.0], dst);
     /// ```
     #[inline]
-    unsafe fn read_f32_into_unchecked<T: ByteOrder>(
+    fn read_f32_into_unchecked<T: ByteOrder>(
         &mut self,
         dst: &mut [f32],
     ) -> Result<()> {
+        self.read_f32_into::<T>(dst)
+    }
+
+    /// Reads a sequence of IEEE754 double-precision (8 bytes) floating
+    /// point numbers from the underlying reader.
+    ///
+    /// The given buffer is either filled completely or an error is returned.
+    /// If an error is returned, the contents of `dst` are unspecified.
+    ///
+    /// # Errors
+    ///
+    /// This method returns the same errors as [`Read::read_exact`].
+    ///
+    /// [`Read::read_exact`]: https://doc.rust-lang.org/std/io/trait.Read.html#method.read_exact
+    ///
+    /// # Examples
+    ///
+    /// Read a sequence of big-endian single-precision floating point number
+    /// from a `Read`:
+    ///
+    /// ```rust
+    /// use std::f64;
+    /// use std::io::Cursor;
+    ///
+    /// use byteorder::{BigEndian, ReadBytesExt};
+    ///
+    /// let mut rdr = Cursor::new(vec![
+    ///     0x40, 0x09, 0x21, 0xfb, 0x54, 0x44, 0x2d, 0x18,
+    ///     0x3f, 0xF0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+    /// ]);
+    /// let mut dst = [0.0; 2];
+    /// rdr.read_f64_into::<BigEndian>(&mut dst).unwrap();
+    /// assert_eq!([f64::consts::PI, 1.0], dst);
+    /// ```
+    #[inline]
+    fn read_f64_into<T: ByteOrder>(
+        &mut self,
+        dst: &mut [f64],
+    ) -> Result<()> {
         {
-            let mut buf = slice_to_u8_mut(dst);
+            let buf = unsafe { slice_to_u8_mut(dst) };
             try!(self.read_exact(buf));
         }
-        T::from_slice_f32(dst);
+        T::from_slice_f64(dst);
         Ok(())
     }
 
+    /// **DEPRECATED**.
+    ///
+    /// This method is deprecated. Use `read_f64_into` instead.
+    ///
     /// Reads a sequence of IEEE754 double-precision (8 bytes) floating
     /// point numbers from the underlying reader.
     ///
     /// The given buffer is either filled completely or an error is returned.
     /// If an error is returned, the contents of `dst` are unspecified.
     ///
     /// # Safety
     ///
@@ -862,32 +944,25 @@ pub trait ReadBytesExt: io::Read {
     ///
     /// use byteorder::{BigEndian, ReadBytesExt};
     ///
     /// let mut rdr = Cursor::new(vec![
     ///     0x40, 0x09, 0x21, 0xfb, 0x54, 0x44, 0x2d, 0x18,
     ///     0x3f, 0xF0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
     /// ]);
     /// let mut dst = [0.0; 2];
-    /// unsafe {
-    ///     rdr.read_f64_into_unchecked::<BigEndian>(&mut dst).unwrap();
-    /// }
+    /// rdr.read_f64_into_unchecked::<BigEndian>(&mut dst).unwrap();
     /// assert_eq!([f64::consts::PI, 1.0], dst);
     /// ```
     #[inline]
-    unsafe fn read_f64_into_unchecked<T: ByteOrder>(
+    fn read_f64_into_unchecked<T: ByteOrder>(
         &mut self,
         dst: &mut [f64],
     ) -> Result<()> {
-        {
-            let mut buf = slice_to_u8_mut(dst);
-            try!(self.read_exact(buf));
-        }
-        T::from_slice_f64(dst);
-        Ok(())
+        self.read_f64_into::<T>(dst)
     }
 }
 
 /// All types that implement `Read` get methods defined in `ReadBytesExt`
 /// for free.
 impl<R: io::Read + ?Sized> ReadBytesExt for R {}
 
 /// Extends `Write` with methods for writing numbers. (For `std::io`.)
--- a/third_party/rust/byteorder/src/lib.rs
+++ b/third_party/rust/byteorder/src/lib.rs
@@ -35,17 +35,17 @@ wtr.write_u16::<LittleEndian>(768).unwra
 assert_eq!(wtr, vec![5, 2, 0, 3]);
 ```
 */
 
 #![deny(missing_docs)]
 #![cfg_attr(not(feature = "std"), no_std)]
 #![cfg_attr(feature = "i128", feature(i128_type))]
 #![cfg_attr(all(feature = "i128", test), feature(i128))]
-#![doc(html_root_url = "https://docs.rs/byteorder/1.0.0")]
+#![doc(html_root_url = "https://docs.rs/byteorder/1.2.1")]
 
 #[cfg(feature = "std")]
 extern crate core;
 
 use core::fmt::Debug;
 use core::hash::Hash;
 use core::mem::transmute;
 use core::ptr::copy_nonoverlapping;
@@ -606,19 +606,16 @@ pub trait ByteOrder
     #[cfg(feature = "i128")]
     #[inline]
     fn read_int128(buf: &[u8], nbytes: usize) -> i128 {
         extend_sign128(Self::read_uint128(buf, nbytes), nbytes)
     }
 
     /// Reads a IEEE754 single-precision (4 bytes) floating point number.
     ///
-    /// The return value is always defined; signaling NaN's may be turned into
-    /// quiet NaN's.
-    ///
     /// # Panics
     ///
     /// Panics when `buf.len() < 4`.
     ///
     /// # Examples
     ///
     /// Write and read `f32` numbers in little endian order:
     ///
@@ -627,24 +624,21 @@ pub trait ByteOrder
     ///
     /// let e = 2.71828;
     /// let mut buf = [0; 4];
     /// LittleEndian::write_f32(&mut buf, e);
     /// assert_eq!(e, LittleEndian::read_f32(&buf));
     /// ```
     #[inline]
     fn read_f32(buf: &[u8]) -> f32 {
-        safe_u32_bits_to_f32(Self::read_u32(buf))
+        unsafe { transmute(Self::read_u32(buf)) }
     }
 
     /// Reads a IEEE754 double-precision (8 bytes) floating point number.
     ///
-    /// The return value is always defined; signaling NaN's may be turned into
-    /// quiet NaN's.
-    ///
     /// # Panics
     ///
     /// Panics when `buf.len() < 8`.
     ///
     /// # Examples
     ///
     /// Write and read `f64` numbers in little endian order:
     ///
@@ -653,17 +647,17 @@ pub trait ByteOrder
     ///
     /// let phi = 1.6180339887;
     /// let mut buf = [0; 8];
     /// LittleEndian::write_f64(&mut buf, phi);
     /// assert_eq!(phi, LittleEndian::read_f64(&buf));
     /// ```
     #[inline]
     fn read_f64(buf: &[u8]) -> f64 {
-        safe_u64_bits_to_f64(Self::read_u64(buf))
+        unsafe { transmute(Self::read_u64(buf)) }
     }
 
     /// Writes a signed 16 bit integer `n` to `buf`.
     ///
     /// # Panics
     ///
     /// Panics when `buf.len() < 2`.
     ///
@@ -1061,81 +1055,65 @@ pub trait ByteOrder
     #[inline]
     fn read_i128_into(src: &[u8], dst: &mut [i128]) {
         Self::read_u128_into(src, unsafe { transmute(dst) });
     }
 
     /// Reads IEEE754 single-precision (4 bytes) floating point numbers from
     /// `src` into `dst`.
     ///
-    /// Note that this does not perform any checks on the floating point
-    /// conversion. In particular, if the `src` data encodes an undefined
-    /// floating point value for your environment, then the result may be
-    /// undefined behavior. For example, this function may produce signaling
-    /// NaN floating point values.
-    ///
     /// # Panics
     ///
     /// Panics when `src.len() != 4*dst.len()`.
     ///
     /// # Examples
     ///
     /// Write and read `f32` numbers in little endian order:
     ///
     /// ```rust
     /// use byteorder::{ByteOrder, LittleEndian};
     ///
     /// let mut bytes = [0; 16];
     /// let numbers_given = [1.0, 2.0, 31.312e311, -11.32e91];
     /// LittleEndian::write_f32_into(&numbers_given, &mut bytes);
     ///
     /// let mut numbers_got = [0.0; 4];
-    /// unsafe {
-    ///     LittleEndian::read_f32_into_unchecked(&bytes, &mut numbers_got);
-    /// }
+    /// LittleEndian::read_f32_into_unchecked(&bytes, &mut numbers_got);
     /// assert_eq!(numbers_given, numbers_got);
     /// ```
     #[inline]
-    unsafe fn read_f32_into_unchecked(src: &[u8], dst: &mut [f32]) {
-        Self::read_u32_into(src, transmute(dst));
+    fn read_f32_into_unchecked(src: &[u8], dst: &mut [f32]) {
+        Self::read_u32_into(src, unsafe { transmute(dst) });
     }
 
     /// Reads IEEE754 single-precision (4 bytes) floating point numbers from
     /// `src` into `dst`.
     ///
-    /// Note that this does not perform any checks on the floating point
-    /// conversion. In particular, if the `src` data encodes an undefined
-    /// floating point value for your environment, then the result may be
-    /// undefined behavior. For example, this function may produce signaling
-    /// NaN floating point values.
-    ///
     /// # Panics
     ///
     /// Panics when `src.len() != 8*dst.len()`.
     ///
     /// # Examples
     ///
     /// Write and read `f64` numbers in little endian order:
     ///
     /// ```rust
     /// use byteorder::{ByteOrder, LittleEndian};
     ///
     /// let mut bytes = [0; 32];
     /// let numbers_given = [1.0, 2.0, 31.312e311, -11.32e91];
     /// LittleEndian::write_f64_into(&numbers_given, &mut bytes);
     ///
     /// let mut numbers_got = [0.0; 4];
-    /// unsafe {
-    ///     LittleEndian::read_f64_into_unchecked(&bytes, &mut numbers_got);
-    /// }
+    /// LittleEndian::read_f64_into_unchecked(&bytes, &mut numbers_got);
     /// assert_eq!(numbers_given, numbers_got);
     /// ```
     #[inline]
-    unsafe fn read_f64_into_unchecked(src: &[u8], dst: &mut [f64]) {
-        Self::read_u64_into(src, transmute(dst));
+    fn read_f64_into_unchecked(src: &[u8], dst: &mut [f64]) {
+        Self::read_u64_into(src, unsafe { transmute(dst) });
     }
 
     /// Writes unsigned 16 bit integers from `src` into `dst`.
     ///
     /// # Panics
     ///
     /// Panics when `dst.len() != 2*src.len()`.
     ///
@@ -1585,31 +1563,23 @@ pub trait ByteOrder
         Self::from_slice_u128(unsafe { transmute(numbers) });
     }
 
     /// Converts the given slice of IEEE754 single-precision (4 bytes) floating
     /// point numbers to a particular endianness.
     ///
     /// If the endianness matches the endianness of the host platform, then
     /// this is a no-op.
-    ///
-    /// Note that the results of this operation are guaranteed to be defined.
-    /// In particular, this method may replace signaling NaN values with
-    /// quiet NaN values.
     fn from_slice_f32(numbers: &mut [f32]);
 
     /// Converts the given slice of IEEE754 double-precision (8 bytes) floating
     /// point numbers to a particular endianness.
     ///
     /// If the endianness matches the endianness of the host platform, then
     /// this is a no-op.
-    ///
-    /// Note that the results of this operation are guaranteed to be defined.
-    /// In particular, this method may replace signaling NaN values with
-    /// quiet NaN values.
     fn from_slice_f64(numbers: &mut [f64]);
 }
 
 /// Defines big-endian serialization.
 ///
 /// Note that this type has no value constructor. It is used purely at the
 /// type level.
 ///
@@ -1959,27 +1929,27 @@ impl ByteOrder for BigEndian {
         }
     }
 
     #[inline]
     fn from_slice_f32(numbers: &mut [f32]) {
         if cfg!(target_endian = "little") {
             for n in numbers {
                 let int: u32 = unsafe { transmute(*n) };
-                *n = safe_u32_bits_to_f32(int.to_be());
+                *n = unsafe { transmute(int.to_be()) };
             }
         }
     }
 
     #[inline]
     fn from_slice_f64(numbers: &mut [f64]) {
         if cfg!(target_endian = "little") {
             for n in numbers {
                 let int: u64 = unsafe { transmute(*n) };
-                *n = safe_u64_bits_to_f64(int.to_be());
+                *n = unsafe { transmute(int.to_be()) };
             }
         }
     }
 }
 
 impl ByteOrder for LittleEndian {
     #[inline]
     fn read_u16(buf: &[u8]) -> u16 {
@@ -2162,70 +2132,32 @@ impl ByteOrder for LittleEndian {
         }
     }
 
     #[inline]
     fn from_slice_f32(numbers: &mut [f32]) {
         if cfg!(target_endian = "big") {
             for n in numbers {
                 let int: u32 = unsafe { transmute(*n) };
-                *n = safe_u32_bits_to_f32(int.to_le());
+                *n = unsafe { transmute(int.to_le()) };
             }
         }
     }
 
     #[inline]
     fn from_slice_f64(numbers: &mut [f64]) {
         if cfg!(target_endian = "big") {
             for n in numbers {
                 let int: u64 = unsafe { transmute(*n) };
-                *n = safe_u64_bits_to_f64(int.to_le());
+                *n = unsafe { transmute(int.to_le()) };
             }
         }
     }
 }
 
-#[inline]
-fn safe_u32_bits_to_f32(u: u32) -> f32 {
-    use core::f32::NAN;
-
-    const EXP_MASK: u32 = 0x7F800000;
-    const FRACT_MASK: u32 = 0x007FFFFF;
-
-    if u & EXP_MASK == EXP_MASK && u & FRACT_MASK != 0 {
-        // While IEEE 754-2008 specifies encodings for quiet NaNs and
-        // signaling ones, certains MIPS and PA-RISC CPUs treat signaling
-        // NaNs differently. Therefore, to be safe, we pass a known quiet
-        // NaN if u is any kind of NaN. The check above only assumes
-        // IEEE 754-1985 to be valid.
-        NAN
-    } else {
-        unsafe { transmute(u) }
-    }
-}
-
-#[inline]
-fn safe_u64_bits_to_f64(u: u64) -> f64 {
-    use core::f64::NAN;
-
-    const EXP_MASK: u64 = 0x7FF0000000000000;
-    const FRACT_MASK: u64 = 0x000FFFFFFFFFFFFF;
-
-    if u & EXP_MASK == EXP_MASK && u & FRACT_MASK != 0 {
-        // While IEEE 754-2008 specifies encodings for quiet NaNs and
-        // signaling ones, certains MIPS and PA-RISC CPUs treat signaling
-        // NaNs differently. Therefore, to be safe, we pass a known quiet
-        // NaN if u is any kind of NaN. The check above only assumes
-        // IEEE 754-1985 to be valid.
-        NAN
-    } else {
-        unsafe { transmute(u) }
-    }
-}
-
 #[cfg(test)]
 mod test {
     extern crate quickcheck;
     extern crate rand;
 
     use self::quickcheck::{QuickCheck, StdGen, Testable};
     use self::rand::thread_rng;
     #[cfg(feature = "i128")] use self::quickcheck::{Arbitrary, Gen};
@@ -2791,45 +2723,16 @@ mod test {
         slice_len_too_big_i128, read_i128_into, write_i128_into, 33, [0, 0]);
 
     #[test]
     fn uint_bigger_buffer() {
         use {ByteOrder, LittleEndian};
         let n = LittleEndian::read_uint(&[1, 2, 3, 4, 5, 6, 7, 8], 5);
         assert_eq!(n, 0x0504030201);
     }
-
-    #[test]
-    fn read_snan() {
-        use core::f32;
-        use core::f64;
-        use core::mem::transmute;
-
-        use {ByteOrder, BigEndian, LittleEndian};
-
-        let sf = BigEndian::read_f32(&[0xFF, 0x80, 0x00, 0x01]);
-        let sbits: u32 = unsafe { transmute(sf) };
-        assert_eq!(sbits, unsafe { transmute(f32::NAN) });
-        assert_eq!(sf.classify(), ::core::num::FpCategory::Nan);
-
-        let df = BigEndian::read_f64(&[0x7F, 0xF0, 0, 0, 0, 0, 0, 0x01]);
-        let dbits: u64 = unsafe { ::core::mem::transmute(df) };
-        assert_eq!(dbits, unsafe { transmute(f64::NAN) });
-        assert_eq!(df.classify(), ::core::num::FpCategory::Nan);
-
-        let sf = LittleEndian::read_f32(&[0x01, 0x00, 0x80, 0xFF]);
-        let sbits: u32 = unsafe { transmute(sf) };
-        assert_eq!(sbits, unsafe { transmute(f32::NAN) });
-        assert_eq!(sf.classify(), ::core::num::FpCategory::Nan);
-
-        let df = LittleEndian::read_f64(&[0x01, 0, 0, 0, 0, 0, 0xF0, 0x7F]);
-        let dbits: u64 = unsafe { ::core::mem::transmute(df) };
-        assert_eq!(dbits, unsafe { transmute(f64::NAN) });
-        assert_eq!(df.classify(), ::core::num::FpCategory::Nan);
-    }
 }
 
 #[cfg(test)]
 #[cfg(feature = "std")]
 mod stdtests {
     extern crate quickcheck;
     extern crate rand;
 
@@ -2860,19 +2763,18 @@ mod stdtests {
                 };
                 #[allow(unused_imports)] use test::{qc_sized, Wi128};
 
                 #[test]
                 fn big_endian() {
                     fn prop(n: $ty_int) -> bool {
                         let mut wtr = vec![];
                         wtr.$write::<BigEndian>(n.clone()).unwrap();
-                        let mut rdr = Vec::new();
-                        rdr.extend(wtr[wtr.len()-$bytes..].iter().map(|&x| x));
-                        let mut rdr = Cursor::new(rdr);
+                        let offset = wtr.len() - $bytes;
+                        let mut rdr = Cursor::new(&mut wtr[offset..]);
                         n == rdr.$read::<BigEndian>($bytes).unwrap()
                     }
                     qc_sized(prop as fn($ty_int) -> bool, $max);
                 }
 
                 #[test]
                 fn little_endian() {
                     fn prop(n: $ty_int) -> bool {
@@ -2884,17 +2786,22 @@ mod stdtests {
                     qc_sized(prop as fn($ty_int) -> bool, $max);
                 }
 
                 #[test]
                 fn native_endian() {
                     fn prop(n: $ty_int) -> bool {
                         let mut wtr = vec![];
                         wtr.$write::<NativeEndian>(n.clone()).unwrap();
-                        let mut rdr = Cursor::new(wtr);
+                        let offset = if cfg!(target_endian = "big") {
+                            wtr.len() - $bytes
+                        } else {
+                            0
+                        };
+                        let mut rdr = Cursor::new(&mut wtr[offset..]);
                         n == rdr.$read::<NativeEndian>($bytes).unwrap()
                     }
                     qc_sized(prop as fn($ty_int) -> bool, $max);
                 }
             }
         );
         ($name:ident, $ty_int:ty, $max:expr, $read:ident, $write:ident) => (
             mod $name {
--- a/third_party/rust/dwrote/.cargo-checksum.json
+++ b/third_party/rust/dwrote/.cargo-checksum.json
@@ -1,1 +1,1 @@
-{"files":{"Cargo.toml":"48059bb4b7efd1a6c2d659fa909888f2c8b5d34f0bd8027b4aefaae9b8d0586e","README.md":"d69d75705e2582721cbfb2d3b4b2af052c71679057a0b2ac53a22c03f1755bba","appveyor.yml":"2c7b2468dc69bef84860b8900024cb6e1a1c52f6fe1232e8ccd83caaf7c231ca","src/bitmap_render_target.rs":"d3b229f85a9804ac52976431657727b410e7d5253283df046e46d98c196f0a3a","src/com_helpers.rs":"fccb4b36379ae3454a88aa32a8e5c09e46ef5f5626266dde1fe5f40a992de39c","src/comptr.rs":"218435689f505769686e07cfc5428852dda90b849a0d48e670f632307f5edc7c","src/font.rs":"9bdf3134c6ad3639eab3da4419c9b43aad2673797f6fdc65841da2c82e1f3af4","src/font_collection.rs":"969fa3abf141dc3504774886f4783fda4a74cd5a198c643f8a77fc1af4e75258","src/font_face.rs":"9506ca579345ab2b6b5615fc75f8f431e2bb0dbd93123d1d2a21a73c851a5427","src/font_family.rs":"403da9f8f9903cbe7f9f79636497b273f9885e200f53af99f9d4e483f11d6889","src/font_file.rs":"60ad02fc25765a2c113175ea372e98a2be0d84aa65fef9246b6a0192e63ff708","src/font_file_loader_impl.rs":"0d304ad99ff1e6874510a1498223329d798ff75b417e3db7e823a695003dfe92","src/gdi_interop.rs":"98922996afc5b8c8304cb65e7c965419003825dfa172a3e11fe69bf3d768551c","src/glyph_run_analysis.rs":"d30d8b41b047815ab5770c730b7a6d09939f2347b4a4257b87bebec08a5794fe","src/helpers.rs":"5d6f164468234ca8806dc1cea117b42dbfae80cc4c9ae965cb0556efdb364682","src/lib.rs":"07dae7e9a6b8e2970917eade968490e2af90110047a0e16f539647269b12f439","src/rendering_params.rs":"be1d1c433f76926c285d8ecdb747c5d9cc6a6c10c1a1890c0760cd99755ed471","src/test.rs":"d77e45f8866abeea070cbbafd4cbde62d875292e8d191310a04c70091978547c","src/types.rs":"784235c15d61fb0d001373575169aa473c92af18dcbc1709a5b2bbaa3a7ceb22"},"package":"36e3b27cd0b8a68e00f07e8d8e1e4f4d8a6b8b873290a734f63bd56d792d23e1"}
\ No newline at end of file
+{"files":{"Cargo.toml":"0b4c8dcf0a46bb7a21d3872485dce2bd0a91fa3003b1a87ecee8e418a95b5f94","README.md":"d69d75705e2582721cbfb2d3b4b2af052c71679057a0b2ac53a22c03f1755bba","appveyor.yml":"2c7b2468dc69bef84860b8900024cb6e1a1c52f6fe1232e8ccd83caaf7c231ca","src/bitmap_render_target.rs":"d3b229f85a9804ac52976431657727b410e7d5253283df046e46d98c196f0a3a","src/com_helpers.rs":"fccb4b36379ae3454a88aa32a8e5c09e46ef5f5626266dde1fe5f40a992de39c","src/comptr.rs":"218435689f505769686e07cfc5428852dda90b849a0d48e670f632307f5edc7c","src/font.rs":"9bdf3134c6ad3639eab3da4419c9b43aad2673797f6fdc65841da2c82e1f3af4","src/font_collection.rs":"969fa3abf141dc3504774886f4783fda4a74cd5a198c643f8a77fc1af4e75258","src/font_face.rs":"97bb3f67516b766fb3522f6fb07836cd55020adecc814353d2da35f885c66a85","src/font_family.rs":"403da9f8f9903cbe7f9f79636497b273f9885e200f53af99f9d4e483f11d6889","src/font_file.rs":"60ad02fc25765a2c113175ea372e98a2be0d84aa65fef9246b6a0192e63ff708","src/font_file_loader_impl.rs":"0d304ad99ff1e6874510a1498223329d798ff75b417e3db7e823a695003dfe92","src/gdi_interop.rs":"98922996afc5b8c8304cb65e7c965419003825dfa172a3e11fe69bf3d768551c","src/glyph_run_analysis.rs":"d30d8b41b047815ab5770c730b7a6d09939f2347b4a4257b87bebec08a5794fe","src/helpers.rs":"5d6f164468234ca8806dc1cea117b42dbfae80cc4c9ae965cb0556efdb364682","src/lib.rs":"af8bae7d775a9ddeb956353e572b553aa2819f7183bb3aed8dde98016f6b4c97","src/rendering_params.rs":"be1d1c433f76926c285d8ecdb747c5d9cc6a6c10c1a1890c0760cd99755ed471","src/test.rs":"d77e45f8866abeea070cbbafd4cbde62d875292e8d191310a04c70091978547c","src/types.rs":"784235c15d61fb0d001373575169aa473c92af18dcbc1709a5b2bbaa3a7ceb22"},"package":"a207eb7b40e25d1d28dc679f451d321fb6954b73ceaa47986702575865469461"}
\ No newline at end of file
--- a/third_party/rust/dwrote/Cargo.toml
+++ b/third_party/rust/dwrote/Cargo.toml
@@ -7,36 +7,36 @@
 #
 # If you believe there's an error in this file please file an
 # issue against the rust-lang/cargo repository. If you're
 # editing this file be aware that the upstream Cargo.toml
 # will likely look very different (and much more reasonable)
 
 [package]
 name = "dwrote"
-version = "0.4.0"
+version = "0.4.1"
 authors = ["Vladimir Vukicevic <vladimir@pobox.com>"]
 description = "Lightweight binding to DirectWrite."
 license = "MPL-2.0"
 repository = "https://github.com/servo/dwrote-rs"
 
 [lib]
 name = "dwrote"
-[dependencies.serde_derive]
-version = "1.0"
-
 [dependencies.kernel32-sys]
 version = "0.2"
 
-[dependencies.serde]
+[dependencies.lazy_static]
+version = "0.2"
+
+[dependencies.serde_derive]
 version = "1.0"
 
 [dependencies.winapi]
 version = "0.2"
 
 [dependencies.gdi32-sys]
 version = "0.2"
 
-[dependencies.lazy_static]
-version = "0.2"
+[dependencies.serde]
+version = "1.0"
 
 [dependencies.libc]
 version = "0.2"
--- a/third_party/rust/dwrote/src/font_face.rs
+++ b/third_party/rust/dwrote/src/font_face.rs
@@ -3,17 +3,17 @@
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 use std::slice;
 use std::ptr;
 use std::cell::UnsafeCell;
 use std::mem::zeroed;
 
 use comptr::ComPtr;
-use super::{FontMetrics, FontFile, DefaultDWriteRenderParams};
+use super::{FontMetrics, FontFile, DefaultDWriteRenderParams, DWriteFactory};
 
 use winapi;
 
 #[derive(Debug)]
 pub struct FontFace {
     native: UnsafeCell<ComPtr<winapi::IDWriteFontFace>>,
     metrics: FontMetrics,
 }
@@ -30,28 +30,54 @@ impl FontFace {
             }
         }
     }
 
     pub unsafe fn as_ptr(&self) -> *mut winapi::IDWriteFontFace {
         (*self.native.get()).as_ptr()
     }
 
+    unsafe fn get_raw_files(&self) -> Vec<*mut winapi::IDWriteFontFile> {
+        let mut number_of_files: u32 = 0;
+        let hr = (*self.native.get()).GetFiles(&mut number_of_files, ptr::null_mut());
+        assert!(hr == 0);
+
+        let mut file_ptrs: Vec<*mut winapi::IDWriteFontFile> =
+            vec![ptr::null_mut(); number_of_files as usize];
+        let hr = (*self.native.get()).GetFiles(&mut number_of_files, file_ptrs.as_mut_ptr());
+        assert!(hr == 0);
+        file_ptrs
+    }
+
     pub fn get_files(&self) -> Vec<FontFile> {
         unsafe {
-            let mut number_of_files: u32 = 0;
-            let hr = (*self.native.get()).GetFiles(&mut number_of_files, ptr::null_mut());
-            assert!(hr == 0);
+            let file_ptrs = self.get_raw_files();
+            file_ptrs.iter().map(|p| FontFile::take(ComPtr::already_addrefed(*p))).collect()
+        }
+    }
 
-            let mut file_ptrs: Vec<*mut winapi::IDWriteFontFile> =
-                vec![ptr::null_mut(); number_of_files as usize];
-            let hr = (*self.native.get()).GetFiles(&mut number_of_files, file_ptrs.as_mut_ptr());
+    pub fn create_font_face_with_simulations(&self, simulations: winapi::DWRITE_FONT_SIMULATIONS) -> FontFace {
+        unsafe {
+            let file_ptrs = self.get_raw_files();
+            let face_type = (*self.native.get()).GetType();
+            let face_index = (*self.native.get()).GetIndex();
+            let mut face: ComPtr<winapi::IDWriteFontFace> = ComPtr::new();
+            let hr = (*DWriteFactory()).CreateFontFace(
+                face_type,
+                file_ptrs.len() as u32,
+                file_ptrs.as_ptr(),
+                face_index,
+                simulations,
+                face.getter_addrefs()
+            );
+            for p in file_ptrs {
+                let _ = ComPtr::<winapi::IDWriteFontFile>::already_addrefed(p);
+            }
             assert!(hr == 0);
-
-            file_ptrs.iter().map(|p| FontFile::take(ComPtr::already_addrefed(*p))).collect()
+            FontFace::take(face)
         }
     }
 
     pub fn get_glyph_count(&self) -> u16 {
         unsafe {
             (*self.native.get()).GetGlyphCount()
         }
     }
--- a/third_party/rust/dwrote/src/lib.rs
+++ b/third_party/rust/dwrote/src/lib.rs
@@ -52,16 +52,17 @@ pub use winapi::{DWRITE_RENDERING_MODE_D
                  DWRITE_RENDERING_MODE_CLEARTYPE_NATURAL_SYMMETRIC};
 pub use winapi::{DWRITE_MEASURING_MODE_NATURAL,
                  DWRITE_MEASURING_MODE_GDI_CLASSIC,
                  DWRITE_MEASURING_MODE_GDI_NATURAL};
 pub use winapi::{DWRITE_FONT_SIMULATIONS_NONE,
                  DWRITE_FONT_SIMULATIONS_BOLD,
                  DWRITE_FONT_SIMULATIONS_OBLIQUE};
 pub use winapi::{DWRITE_TEXTURE_ALIASED_1x1, DWRITE_TEXTURE_CLEARTYPE_3x1};
+pub use winapi::{DWRITE_FONT_SIMULATIONS};
 pub use winapi::{DWRITE_RENDERING_MODE};
 pub use winapi::{DWRITE_MEASURING_MODE};
 pub use winapi::{DWRITE_TEXTURE_TYPE};
 
 #[macro_use] mod com_helpers;
 
 mod bitmap_render_target; pub use bitmap_render_target::BitmapRenderTarget;
 mod font; pub use font::Font;
--- a/third_party/rust/gleam/.cargo-checksum.json
+++ b/third_party/rust/gleam/.cargo-checksum.json
@@ -1,1 +1,1 @@
-{"files":{".travis.yml":"29b74b95210896ce634c11a9037638668473b5a1b3b1716c505cb04dbb6341fa","COPYING":"ec82b96487e9e778ee610c7ab245162464782cfa1f555c2299333f8dbe5c036a","Cargo.toml":"0417239a0f167b2c99eead895cdf7a46c39a84bbd9c172e31e99157e41f5a5d2","LICENSE-APACHE":"a60eea817514531668d7e00765731449fe14d059d3249e0bc93b36de45f759f2","LICENSE-MIT":"62065228e42caebca7e7d7db1204cbb867033de5982ca4009928915e4095f3a3","README.md":"2de24b7458d6b88f20324303a48acf64a4f2bbfb83d2ec4d6ff2b4f4a1fd2275","build.rs":"d2a1c4b40ecbc29ddf005ec32f5b68f9242c8d54b703027bf3a1b605a0882d6a","src/gl.rs":"dea0447dd130a46d648f9526b927e0ba6d52b7ef5d1ec92471ac013119cbdee3","src/gl_fns.rs":"b9460d03ea3178672184bcb11e2075dffa8ce18b842be954d996bce9e701d62e","src/gles_fns.rs":"4344505df0aae7bded0048a2e4761920ddbd61acd0370d830d69c23a1f946fb1","src/lib.rs":"16610c19b45a3f26d56b379a3591aa2e4fc9477e7bd88f86b31c6ea32e834861"},"package":"8bd6aa276bc0bf40348728e916a82f8f9cc10b1922cabf9f2fe9cd5e8b98d55b"}
\ No newline at end of file
+{"files":{".travis.yml":"29b74b95210896ce634c11a9037638668473b5a1b3b1716c505cb04dbb6341fa","COPYING":"ec82b96487e9e778ee610c7ab245162464782cfa1f555c2299333f8dbe5c036a","Cargo.toml":"0b1402356bfafe5636331294d4d6e65a9bdb953f8497d41f757f1c7b70e047ad","LICENSE-APACHE":"a60eea817514531668d7e00765731449fe14d059d3249e0bc93b36de45f759f2","LICENSE-MIT":"62065228e42caebca7e7d7db1204cbb867033de5982ca4009928915e4095f3a3","README.md":"2de24b7458d6b88f20324303a48acf64a4f2bbfb83d2ec4d6ff2b4f4a1fd2275","build.rs":"6c391c6f2dd99a7d1c233a3c4b78a2c8355d5e59c74c15ad9d2ec4c5448ea67a","src/gl.rs":"dea0447dd130a46d648f9526b927e0ba6d52b7ef5d1ec92471ac013119cbdee3","src/gl_fns.rs":"b964929cc066751272cd79036683f525a67ee96fe021f8fdb99af4024fa799b6","src/gles_fns.rs":"45dd524107d20175fd1c4a420c91cc88820312d0a65b5b02dcb6082ca9b8a39a","src/lib.rs":"16610c19b45a3f26d56b379a3591aa2e4fc9477e7bd88f86b31c6ea32e834861"},"package":"dff613336334932baaa2759d001f14e06ea1a08a247c05962d1423aa0e89ee99"}
\ No newline at end of file
--- a/third_party/rust/gleam/Cargo.toml
+++ b/third_party/rust/gleam/Cargo.toml
@@ -7,17 +7,17 @@
 #
 # If you believe there's an error in this file please file an
 # issue against the rust-lang/cargo repository. If you're
 # editing this file be aware that the upstream Cargo.toml
 # will likely look very different (and much more reasonable)
 
 [package]
 name = "gleam"
-version = "0.4.14"
+version = "0.4.15"
 authors = ["The Servo Project Developers"]
 build = "build.rs"
 description = "Generated OpenGL bindings and wrapper for Servo."
 documentation = "http://doc.servo.org/gleam/"
 license = "Apache-2.0/MIT"
 repository = "https://github.com/servo/gleam"
 [build-dependencies.gl_generator]
 version = "0.6.1"
--- a/third_party/rust/gleam/build.rs
+++ b/third_party/rust/gleam/build.rs
@@ -23,16 +23,18 @@ fn main() {
     gl_reg.write_bindings(gl_generator::StructGenerator, &mut file_gl)
           .unwrap();
 
     // GLES 3.0 bindings
     let gles_extensions = [
         "GL_EXT_texture_format_BGRA8888",
         "GL_OES_EGL_image",
         "GL_OES_EGL_image_external",
+        "GL_EXT_disjoint_timer_query",
+        "GL_EXT_debug_marker",
     ];
     let gles_reg = Registry::new(Api::Gles2, (3, 0), Profile::Core, Fallbacks::All, gles_extensions);
     gles_reg.write_bindings(gl_generator::StructGenerator, &mut file_gles)
             .unwrap();
 
     // OpenGL 3.3 + GLES 3.0 bindings. Used to get all enums
     let gl_reg = gl_reg + gles_reg;
     gl_reg.write_bindings(gl_generator::StructGenerator, &mut file_gl_and_gles)
--- a/third_party/rust/gleam/src/gl_fns.rs
+++ b/third_party/rust/gleam/src/gl_fns.rs
@@ -144,21 +144,21 @@ impl Gl for GlFns {
         unsafe {
             let mut result: Vec<_> = repeat(0 as GLuint).take(n as usize).collect();
             self.ffi_gl_.GenVertexArrays(n, result.as_mut_ptr());
             return result;
         }
     }
 
     fn gen_queries(&self, n: GLsizei) -> Vec<GLuint> {
+        let mut result = vec![0; n as usize];
         unsafe {
-            let mut result = vec![0; n as usize];
             self.ffi_gl_.GenQueries(n, result.as_mut_ptr());
-            return result;
         }
+        result
     }
 
     fn begin_query(&self, target: GLenum, id: GLuint) {
         unsafe {
             self.ffi_gl_.BeginQuery(target, id);
         }
     }
 
@@ -170,45 +170,45 @@ impl Gl for GlFns {
 
     fn query_counter(&self, id: GLuint, target: GLenum) {
         unsafe {
             self.ffi_gl_.QueryCounter(id, target);
         }
     }
 
     fn get_query_object_iv(&self, id: GLuint, pname: GLenum) -> i32 {
+        let mut result = 0;
         unsafe {
-            let mut result = 0;
             self.ffi_gl_.GetQueryObjectiv(id, pname, &mut result);
-            result
         }
+        result
     }
 
     fn get_query_object_uiv(&self, id: GLuint, pname: GLenum) -> u32 {
+        let mut result = 0;
         unsafe {
-            let mut result = 0;
             self.ffi_gl_.GetQueryObjectuiv(id, pname, &mut result);
-            result
         }
+        result
     }
 
     fn get_query_object_i64v(&self, id: GLuint, pname: GLenum) -> i64 {
+        let mut result = 0;
         unsafe {
-            let mut result = 0;
             self.ffi_gl_.GetQueryObjecti64v(id, pname, &mut result);
-            result
         }
+        result
     }
 
     fn get_query_object_ui64v(&self, id: GLuint, pname: GLenum) -> u64 {
+        let mut result = 0;
         unsafe {
-            let mut result = 0;
             self.ffi_gl_.GetQueryObjectui64v(id, pname, &mut result);
-            result
         }
+        result
     }
 
     fn delete_queries(&self, queries: &[GLuint]) {
         unsafe {
             self.ffi_gl_.DeleteQueries(queries.len() as GLsizei, queries.as_ptr());
         }
     }
 
--- a/third_party/rust/gleam/src/gles_fns.rs
+++ b/third_party/rust/gleam/src/gles_fns.rs
@@ -140,59 +140,105 @@ impl Gl for GlesFns {
     fn gen_vertex_arrays(&self, n: GLsizei) -> Vec<GLuint> {
         unsafe {
             let mut result: Vec<_> = repeat(0 as GLuint).take(n as usize).collect();
             self.ffi_gl_.GenVertexArrays(n, result.as_mut_ptr());
             return result;
         }
     }
 
-    #[allow(unused_variables)]
     fn gen_queries(&self, n: GLsizei) -> Vec<GLuint> {
-        panic!("not supported")
+        if !self.ffi_gl_.GenQueriesEXT.is_loaded() {
+            return Vec::new();
+        }
+        let mut result = vec![0; n as usize];
+        unsafe {
+            self.ffi_gl_.GenQueriesEXT(n, result.as_mut_ptr());
+        }
+        result
     }
 
-    #[allow(unused_variables)]
     fn begin_query(&self, target: GLenum, id: GLuint) {
-        panic!("not supported")
+        if !self.ffi_gl_.BeginQueryEXT.is_loaded() {
+            return;
+        }
+        unsafe {
+            self.ffi_gl_.BeginQueryEXT(target, id);
+        }
     }
 
-    #[allow(unused_variables)]
     fn end_query(&self, target: GLenum) {
-        panic!("not supported")
+        if !self.ffi_gl_.EndQueryEXT.is_loaded() {
+            return;
+        }
+        unsafe {
+            self.ffi_gl_.EndQueryEXT(target);
+        }
     }
 
-    #[allow(unused_variables)]
     fn query_counter(&self, id: GLuint, target: GLenum) {
-        panic!("not supported")
+        if !self.ffi_gl_.QueryCounterEXT.is_loaded() {
+            return;
+        }
+        unsafe {
+            self.ffi_gl_.QueryCounterEXT(id, target);
+        }
     }
 
-    #[allow(unused_variables)]
     fn get_query_object_iv(&self, id: GLuint, pname: GLenum) -> i32 {
-        panic!("not supported")
+        if !self.ffi_gl_.GetQueryObjectivEXT.is_loaded() {
+            return 0;
+        }
+        let mut result = 0;
+        unsafe {
+            self.ffi_gl_.GetQueryObjectivEXT(id, pname, &mut result);
+        }
+        result
     }
 
-    #[allow(unused_variables)]
     fn get_query_object_uiv(&self, id: GLuint, pname: GLenum) -> u32 {
-        panic!("not supported")
+        if !self.ffi_gl_.GetQueryObjectuivEXT.is_loaded() {
+            return 0;
+        }
+        let mut result = 0;
+        unsafe {
+            self.ffi_gl_.GetQueryObjectuivEXT(id, pname, &mut result);
+        }
+        result
     }
 
-    #[allow(unused_variables)]
     fn get_query_object_i64v(&self, id: GLuint, pname: GLenum) -> i64 {
-        panic!("not supported")
+        if !self.ffi_gl_.GetQueryObjecti64vEXT.is_loaded() {
+            return 0;
+        }
+        let mut result = 0;
+        unsafe {
+            self.ffi_gl_.GetQueryObjecti64vEXT(id, pname, &mut result);
+        }
+        result
     }
 
-    #[allow(unused_variables)]
     fn get_query_object_ui64v(&self, id: GLuint, pname: GLenum) -> u64 {
-        panic!("not supported")
+        if !self.ffi_gl_.GetQueryObjectui64vEXT.is_loaded() {
+            return 0;
+        }
+        let mut result = 0;
+        unsafe {
+            self.ffi_gl_.GetQueryObjectui64vEXT(id, pname, &mut result);
+        }
+        result
     }
 
-    #[allow(unused_variables)]
     fn delete_queries(&self, queries: &[GLuint]) {
-        panic!("not supported")
+        if !self.ffi_gl_.DeleteQueriesEXT.is_loaded() {
+            return;
+        }
+        unsafe {
+            self.ffi_gl_.DeleteQueriesEXT(queries.len() as GLsizei, queries.as_ptr());
+        }
     }
 
     fn delete_vertex_arrays(&self, vertex_arrays: &[GLuint]) {
         unsafe {
             self.ffi_gl_.DeleteVertexArrays(vertex_arrays.len() as GLsizei, vertex_arrays.as_ptr());
         }
     }
 
@@ -1481,26 +1527,38 @@ impl Gl for GlesFns {
     }
 
     fn generate_mipmap(&self, target: GLenum) {
         unsafe {
             self.ffi_gl_.GenerateMipmap(target)
         }
     }
 
-    #[allow(unused_variables)]
     fn insert_event_marker_ext(&self, message: &str) {
+        if self.ffi_gl_.InsertEventMarkerEXT.is_loaded() {
+            unsafe {
+                self.ffi_gl_.InsertEventMarkerEXT(message.len() as GLsizei, message.as_ptr() as *const _);
+            }
+        }
     }
 
-    #[allow(unused_variables)]
     fn push_group_marker_ext(&self, message: &str) {
+        if self.ffi_gl_.PushGroupMarkerEXT.is_loaded() {
+            unsafe {
+                self.ffi_gl_.PushGroupMarkerEXT(message.len() as GLsizei, message.as_ptr() as *const _);
+            }
+        }
     }
 
-    #[allow(unused_variables)]
     fn pop_group_marker_ext(&self) {
+        if self.ffi_gl_.PopGroupMarkerEXT.is_loaded() {
+            unsafe {
+                self.ffi_gl_.PopGroupMarkerEXT();
+            }
+        }
     }
 
     fn fence_sync(&self, condition: GLenum, flags: GLbitfield) -> GLsync {
         unsafe {
            self.ffi_gl_.FenceSync(condition, flags) as *const _
         }
     }
 
--- a/toolkit/library/gtest/rust/Cargo.lock
+++ b/toolkit/library/gtest/rust/Cargo.lock
@@ -96,27 +96,27 @@ name = "binary-space-partition"
 version = "0.1.2"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 
 [[package]]
 name = "bincode"
 version = "0.8.0"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
- "byteorder 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "byteorder 1.2.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "num-traits 0.1.39 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde 1.0.8 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
 name = "bincode"
 version = "0.9.1"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
- "byteorder 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "byteorder 1.2.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde 1.0.8 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
 name = "bindgen"
 version = "0.31.3"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
@@ -155,25 +155,25 @@ source = "registry+https://github.com/ru
 
 [[package]]
 name = "boxfnonce"
 version = "0.0.3"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 
 [[package]]
 name = "byteorder"
-version = "1.0.0"
+version = "1.2.1"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 
 [[package]]
 name = "bytes"
 version = "0.4.5"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
- "byteorder 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "byteorder 1.2.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "iovec 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
 name = "cexpr"
 version = "0.2.0"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
@@ -386,17 +386,17 @@ name = "dtoa-short"
 version = "0.3.1"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
  "dtoa 0.4.2 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
 name = "dwrote"
-version = "0.4.0"
+version = "0.4.1"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
  "gdi32-sys 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "kernel32-sys 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "lazy_static 0.2.8 (registry+https://github.com/rust-lang/crates.io-index)",
  "libc 0.2.24 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde 1.0.8 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde_derive 1.0.8 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -516,17 +516,17 @@ name = "futures"
 version = "0.1.13"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 
 [[package]]
 name = "fxhash"
 version = "0.2.1"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
- "byteorder 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "byteorder 1.2.1 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
 name = "gdi32-sys"
 version = "0.2.0"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
  "winapi 0.2.8 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -593,17 +593,17 @@ source = "registry+https://github.com/ru
 dependencies = [
  "khronos_api 2.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "log 0.3.8 (registry+https://github.com/rust-lang/crates.io-index)",
  "xml-rs 0.7.0 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
 name = "gleam"
-version = "0.4.14"
+version = "0.4.15"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
  "gl_generator 0.6.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "pkg-config 0.3.9 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
 name = "glob"
@@ -818,30 +818,30 @@ dependencies = [
  "ws2_32-sys 0.2.1 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
 name = "mp4parse"
 version = "0.9.0"
 dependencies = [
  "bitreader 0.3.0 (registry+https://github.com/rust-lang/crates.io-index)",
- "byteorder 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "byteorder 1.2.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "mp4parse_fallible 0.0.1",
  "num-traits 0.1.39 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
 name = "mp4parse-gtest"
 version = "0.1.0"
 
 [[package]]
 name = "mp4parse_capi"
 version = "0.9.0"
 dependencies = [
- "byteorder 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "byteorder 1.2.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "mp4parse 0.9.0",
  "num-traits 0.1.39 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
 name = "mp4parse_fallible"
 version = "0.0.1"
 
@@ -1245,17 +1245,17 @@ source = "registry+https://github.com/ru
 name = "style"
 version = "0.0.1"
 dependencies = [
  "app_units 0.5.6 (registry+https://github.com/rust-lang/crates.io-index)",
  "arrayvec 0.3.23 (registry+https://github.com/rust-lang/crates.io-index)",
  "atomic_refcell 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "bindgen 0.31.3 (registry+https://github.com/rust-lang/crates.io-index)",
  "bitflags 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
- "byteorder 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "byteorder 1.2.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "cfg-if 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "cssparser 0.22.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "euclid 0.15.5 (registry+https://github.com/rust-lang/crates.io-index)",
  "fallible 0.0.1",
  "fnv 1.0.5 (registry+https://github.com/rust-lang/crates.io-index)",
  "hashglobe 0.1.0",
  "itertools 0.5.10 (registry+https://github.com/rust-lang/crates.io-index)",
  "itoa 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -1490,71 +1490,71 @@ source = "registry+https://github.com/ru
 dependencies = [
  "kernel32-sys 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "same-file 0.1.3 (registry+https://github.com/rust-lang/crates.io-index)",
  "winapi 0.2.8 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
 name = "webrender"
-version = "0.54.0"
+version = "0.55.0"
 dependencies = [
  "app_units 0.5.6 (registry+https://github.com/rust-lang/crates.io-index)",
  "bincode 0.9.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "bitflags 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
- "byteorder 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "byteorder 1.2.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "core-foundation 0.4.4 (registry+https://github.com/rust-lang/crates.io-index)",
  "core-graphics 0.12.3 (registry+https://github.com/rust-lang/crates.io-index)",
  "core-text 8.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
- "dwrote 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "dwrote 0.4.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "euclid 0.15.5 (registry+https://github.com/rust-lang/crates.io-index)",
  "freetype 0.3.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "fxhash 0.2.1 (registry+https://github.com/rust-lang/crates.io-index)",
- "gleam 0.4.14 (registry+https://github.com/rust-lang/crates.io-index)",
+ "gleam 0.4.15 (registry+https://github.com/rust-lang/crates.io-index)",
  "lazy_static 0.2.8 (registry+https://github.com/rust-lang/crates.io-index)",
  "log 0.3.8 (registry+https://github.com/rust-lang/crates.io-index)",
  "num-traits 0.1.39 (registry+https://github.com/rust-lang/crates.io-index)",
  "plane-split 0.6.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "rayon 0.8.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "thread_profiler 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "time 0.1.36 (registry+https://github.com/rust-lang/crates.io-index)",
- "webrender_api 0.54.0",
+ "webrender_api 0.55.0",
 ]
 
 [[package]]
 name = "webrender_api"
-version = "0.54.0"
+version = "0.55.0"
 dependencies = [
  "app_units 0.5.6 (registry+https://github.com/rust-lang/crates.io-index)",
  "bincode 0.9.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "bitflags 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
- "byteorder 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "byteorder 1.2.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "core-foundation 0.4.4 (registry+https://github.com/rust-lang/crates.io-index)",
  "core-graphics 0.12.3 (registry+https://github.com/rust-lang/crates.io-index)",
- "dwrote 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "dwrote 0.4.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "euclid 0.15.5 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde 1.0.8 (registry+https://github.com/rust-lang/crates.io-index)",
  "time 0.1.36 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
 name = "webrender_bindings"
 version = "0.1.0"
 dependencies = [
  "app_units 0.5.6 (registry+https://github.com/rust-lang/crates.io-index)",
  "core-foundation 0.4.4 (registry+https://github.com/rust-lang/crates.io-index)",
  "core-graphics 0.12.3 (registry+https://github.com/rust-lang/crates.io-index)",
- "dwrote 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "dwrote 0.4.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "euclid 0.15.5 (registry+https://github.com/rust-lang/crates.io-index)",
  "foreign-types 0.3.0 (registry+https://github.com/rust-lang/crates.io-index)",
- "gleam 0.4.14 (registry+https://github.com/rust-lang/crates.io-index)",
+ "gleam 0.4.15 (registry+https://github.com/rust-lang/crates.io-index)",
  "log 0.3.8 (registry+https://github.com/rust-lang/crates.io-index)",
  "rayon 0.8.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "thread_profiler 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)",
- "webrender 0.54.0",
+ "webrender 0.55.0",
 ]
 
 [[package]]
 name = "which"
 version = "1.0.3"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
  "libc 0.2.24 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -1598,17 +1598,17 @@ dependencies = [
 "checksum bincode 0.8.0 (registry+https://github.com/rust-lang/crates.io-index)" = "e103c8b299b28a9c6990458b7013dc4a8356a9b854c51b9883241f5866fac36e"
 "checksum bincode 0.9.1 (registry+https://github.com/rust-lang/crates.io-index)" = "9d3fb369af639822830328794eba2501b3479652fcd021b2aeb1ed4984202afd"
 "checksum bindgen 0.31.3 (registry+https://github.com/rust-lang/crates.io-index)" = "57253399c086f4f29e57ffd3b5cdbc23a806a00292619351aa4cfa39cb49d4ea"
 "checksum bitflags 0.7.0 (registry+https://github.com/rust-lang/crates.io-index)" = "aad18937a628ec6abcd26d1489012cc0e18c21798210f491af69ded9b881106d"
 "checksum bitflags 0.9.1 (registry+https://github.com/rust-lang/crates.io-index)" = "4efd02e230a02e18f92fc2735f44597385ed02ad8f831e7c1c1156ee5e1ab3a5"
 "checksum bitflags 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)" = "f5cde24d1b2e2216a726368b2363a273739c91f4e3eb4e0dd12d672d396ad989"
 "checksum bitreader 0.3.0 (registry+https://github.com/rust-lang/crates.io-index)" = "80b13e2ab064ff3aa0bdbf1eff533f9822dc37899821f5f98c67f263eab51707"
 "checksum boxfnonce 0.0.3 (registry+https://github.com/rust-lang/crates.io-index)" = "8380105befe91099e6f69206164072c05bc92427ff6aa8a5171388317346dd75"
-"checksum byteorder 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)" = "c40977b0ee6b9885c9013cd41d9feffdd22deb3bb4dc3a71d901cc7a77de18c8"
+"checksum byteorder 1.2.1 (registry+https://github.com/rust-lang/crates.io-index)" = "652805b7e73fada9d85e9a6682a4abd490cb52d96aeecc12e33a0de34dfd0d23"
 "checksum bytes 0.4.5 (registry+https://github.com/rust-lang/crates.io-index)" = "d828f97b58cc5de3e40c421d0cf2132d6b2da4ee0e11b8632fa838f0f9333ad6"
 "checksum cexpr 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)" = "393a5f0088efbe41f9d1fcd062f24e83c278608420e62109feb2c8abee07de7d"
 "checksum cfg-if 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)" = "d0c47d456a36ebf0536a6705c83c1cbbcb9255fbc1d905a6ded104f479268a29"
 "checksum clang-sys 0.21.1 (registry+https://github.com/rust-lang/crates.io-index)" = "00048189ee171715296dfe3b2fcfd439563c7bfec0d98d3976ce3402d62c8f07"
 "checksum clap 2.25.0 (registry+https://github.com/rust-lang/crates.io-index)" = "867a885995b4184be051b70a592d4d70e32d7a188db6e8dff626af286a962771"
 "checksum coco 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)" = "c06169f5beb7e31c7c67ebf5540b8b472d23e3eade3b2ec7d1f5b504a85f91bd"
 "checksum core-foundation 0.4.4 (registry+https://github.com/rust-lang/crates.io-index)" = "5909502e547762013619f4c4e01cc7393c20fe2d52d7fa471c1210adb2320dc7"
 "checksum core-foundation-sys 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)" = "41115a6aa5d3e1e5ef98148373f25971d1fad53818553f216495f9e67e90a624"
@@ -1619,34 +1619,34 @@ dependencies = [
 "checksum cose-c 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)" = "07cc8bb85ec2e93541ef9369b85a4b6fb7732bc7f4854d317eab20e726b0fc2f"
 "checksum cssparser 0.22.0 (registry+https://github.com/rust-lang/crates.io-index)" = "44313341610282488e1156ad1fedebca51c54766c87a041d0287b10499c04ba1"
 "checksum cssparser-macros 0.3.0 (registry+https://github.com/rust-lang/crates.io-index)" = "079adec4af52bb5275eadd004292028c79eb3c5f5b4ee8086a36d4197032f6df"
 "checksum darling 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)" = "9861a8495606435477df581bc858ccf15a3469747edf175b94a4704fd9aaedac"
 "checksum darling_core 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)" = "1486a8b00b45062c997f767738178b43219133dd0c8c826cb811e60563810821"
 "checksum darling_macro 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)" = "8a86ec160aa0c3dd492dd4a14ec8104ad8f1a9400a820624db857998cc1f80f9"
 "checksum dtoa 0.4.2 (registry+https://github.com/rust-lang/crates.io-index)" = "09c3753c3db574d215cba4ea76018483895d7bff25a31b49ba45db21c48e50ab"
 "checksum dtoa-short 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)" = "068d4026697c1a18f0b0bb8cfcad1b0c151b90d8edb9bf4c235ad68128920d1d"
-"checksum dwrote 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)" = "36e3b27cd0b8a68e00f07e8d8e1e4f4d8a6b8b873290a734f63bd56d792d23e1"
+"checksum dwrote 0.4.1 (registry+https://github.com/rust-lang/crates.io-index)" = "a207eb7b40e25d1d28dc679f451d321fb6954b73ceaa47986702575865469461"
 "checksum either 1.1.0 (registry+https://github.com/rust-lang/crates.io-index)" = "18785c1ba806c258137c937e44ada9ee7e69a37e3c72077542cd2f069d78562a"
 "checksum encoding_c 0.8.0 (registry+https://github.com/rust-lang/crates.io-index)" = "93ec52324ca72f423237a413ca0e1c60654c8b3d0934fcd5fd888508dfcc4ba7"
 "checksum encoding_rs 0.7.1 (registry+https://github.com/rust-lang/crates.io-index)" = "f5215aabf22b83153be3ee44dfe3f940214541b2ce13d419c55e7a115c8c51a9"
 "checksum env_logger 0.4.3 (registry+https://github.com/rust-lang/crates.io-index)" = "3ddf21e73e016298f5cb37d6ef8e8da8e39f91f9ec8b0df44b7deb16a9f8cd5b"
 "checksum error-chain 0.10.0 (registry+https://github.com/rust-lang/crates.io-index)" = "d9435d864e017c3c6afeac1654189b06cdb491cf2ff73dbf0d73b0f292f42ff8"
 "checksum euclid 0.15.5 (registry+https://github.com/rust-lang/crates.io-index)" = "f5ed7d77e46f6600f490463ad7b6349c3ebb2d2319af56e679e279e4c66495d9"
 "checksum fnv 1.0.5 (registry+https://github.com/rust-lang/crates.io-index)" = "6cc484842f1e2884faf56f529f960cc12ad8c71ce96cc7abba0a067c98fee344"
 "checksum foreign-types 0.3.0 (registry+https://github.com/rust-lang/crates.io-index)" = "5ebc04f19019fff1f2d627b5581574ead502f80c48c88900575a46e0840fe5d0"
 "checksum freetype 0.3.0 (registry+https://github.com/rust-lang/crates.io-index)" = "398b8a11884898184d55aca9806f002b3cf68f0e860e0cbb4586f834ee39b0e7"
 "checksum fs2 0.4.2 (registry+https://github.com/rust-lang/crates.io-index)" = "9ab76cfd2aaa59b7bf6688ad9ba15bbae64bff97f04ea02144cfd3443e5c2866"
 "checksum fuchsia-zircon 0.2.1 (registry+https://github.com/rust-lang/crates.io-index)" = "f6c0581a4e363262e52b87f59ee2afe3415361c6ec35e665924eb08afe8ff159"
 "checksum fuchsia-zircon-sys 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)" = "43f3795b4bae048dc6123a6b972cadde2e676f9ded08aef6bb77f5f157684a82"
 "checksum futures 0.1.13 (registry+https://github.com/rust-lang/crates.io-index)" = "55f0008e13fc853f79ea8fc86e931486860d4c4c156cdffb59fa5f7fa833660a"
 "checksum fxhash 0.2.1 (registry+https://github.com/rust-lang/crates.io-index)" = "c31b6d751ae2c7f11320402d34e41349dd1016f8d5d45e48c4312bc8625af50c"
 "checksum gdi32-sys 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)" = "0912515a8ff24ba900422ecda800b52f4016a56251922d397c576bf92c690518"
 "checksum gl_generator 0.6.1 (registry+https://github.com/rust-lang/crates.io-index)" = "75d69f914b49d9ff32fdf394cbd798f8c716d74fd19f9cc29da3e99797b2a78d"
-"checksum gleam 0.4.14 (registry+https://github.com/rust-lang/crates.io-index)" = "8bd6aa276bc0bf40348728e916a82f8f9cc10b1922cabf9f2fe9cd5e8b98d55b"
+"checksum gleam 0.4.15 (registry+https://github.com/rust-lang/crates.io-index)" = "dff613336334932baaa2759d001f14e06ea1a08a247c05962d1423aa0e89ee99"
 "checksum glob 0.2.11 (registry+https://github.com/rust-lang/crates.io-index)" = "8be18de09a56b60ed0edf84bc9df007e30040691af7acd1c41874faac5895bfb"
 "checksum heapsize 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)" = "4c7593b1522161003928c959c20a2ca421c68e940d63d75573316a009e48a6d4"
 "checksum ident_case 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)" = "3c9826188e666f2ed92071d2dadef6edc430b11b158b5b2b3f4babbcc891eaaa"
 "checksum idna 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)" = "014b298351066f1512874135335d62a789ffe78a9974f94b43ed5621951eaf7d"
 "checksum iovec 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)" = "29d062ee61fccdf25be172e70f34c9f6efc597e1fb8f6526e8437b2046ab26be"
 "checksum itertools 0.5.10 (registry+https://github.com/rust-lang/crates.io-index)" = "4833d6978da405305126af4ac88569b5d71ff758581ce5a987dbfa3755f694fc"
 "checksum itoa 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)" = "eb2f404fbc66fd9aac13e998248505e7ecb2ad8e44ab6388684c5fb11c6c251c"
 "checksum kernel32-sys 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)" = "7507624b29483431c0ba2d82aece8ca6cdba9382bff4ddd0f7490560c056098d"
--- a/toolkit/library/rust/Cargo.lock
+++ b/toolkit/library/rust/Cargo.lock
@@ -96,27 +96,27 @@ name = "binary-space-partition"
 version = "0.1.2"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 
 [[package]]
 name = "bincode"
 version = "0.8.0"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
- "byteorder 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "byteorder 1.2.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "num-traits 0.1.39 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde 1.0.8 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
 name = "bincode"
 version = "0.9.1"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
- "byteorder 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "byteorder 1.2.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde 1.0.8 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
 name = "bindgen"
 version = "0.31.3"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
@@ -155,25 +155,25 @@ source = "registry+https://github.com/ru
 
 [[package]]
 name = "boxfnonce"
 version = "0.0.3"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 
 [[package]]
 name = "byteorder"
-version = "1.0.0"
+version = "1.2.1"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 
 [[package]]
 name = "bytes"
 version = "0.4.5"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
- "byteorder 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "byteorder 1.2.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "iovec 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
 name = "cexpr"
 version = "0.2.0"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
@@ -386,17 +386,17 @@ name = "dtoa-short"
 version = "0.3.1"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
  "dtoa 0.4.2 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
 name = "dwrote"
-version = "0.4.0"
+version = "0.4.1"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
  "gdi32-sys 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "kernel32-sys 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "lazy_static 0.2.8 (registry+https://github.com/rust-lang/crates.io-index)",
  "libc 0.2.24 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde 1.0.8 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde_derive 1.0.8 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -516,17 +516,17 @@ name = "futures"
 version = "0.1.13"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 
 [[package]]
 name = "fxhash"
 version = "0.2.1"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
- "byteorder 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "byteorder 1.2.1 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
 name = "gdi32-sys"
 version = "0.2.0"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
  "winapi 0.2.8 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -592,17 +592,17 @@ source = "registry+https://github.com/ru
 dependencies = [
  "khronos_api 2.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "log 0.3.8 (registry+https://github.com/rust-lang/crates.io-index)",
  "xml-rs 0.7.0 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
 name = "gleam"
-version = "0.4.14"
+version = "0.4.15"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
  "gl_generator 0.6.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "pkg-config 0.3.9 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
 name = "glob"
@@ -817,26 +817,26 @@ dependencies = [
  "ws2_32-sys 0.2.1 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
 name = "mp4parse"
 version = "0.9.0"
 dependencies = [
  "bitreader 0.3.0 (registry+https://github.com/rust-lang/crates.io-index)",
- "byteorder 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "byteorder 1.2.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "mp4parse_fallible 0.0.1",
  "num-traits 0.1.39 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
 name = "mp4parse_capi"
 version = "0.9.0"
 dependencies = [
- "byteorder 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "byteorder 1.2.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "mp4parse 0.9.0",
  "num-traits 0.1.39 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
 name = "mp4parse_fallible"
 version = "0.0.1"
 
@@ -1237,17 +1237,17 @@ source = "registry+https://github.com/ru
 name = "style"
 version = "0.0.1"
 dependencies = [
  "app_units 0.5.6 (registry+https://github.com/rust-lang/crates.io-index)",
  "arrayvec 0.3.23 (registry+https://github.com/rust-lang/crates.io-index)",
  "atomic_refcell 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "bindgen 0.31.3 (registry+https://github.com/rust-lang/crates.io-index)",
  "bitflags 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
- "byteorder 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "byteorder 1.2.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "cfg-if 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "cssparser 0.22.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "euclid 0.15.5 (registry+https://github.com/rust-lang/crates.io-index)",
  "fallible 0.0.1",
  "fnv 1.0.5 (registry+https://github.com/rust-lang/crates.io-index)",
  "hashglobe 0.1.0",
  "itertools 0.5.10 (registry+https://github.com/rust-lang/crates.io-index)",
  "itoa 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -1502,71 +1502,71 @@ source = "registry+https://github.com/ru
 dependencies = [
  "kernel32-sys 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "same-file 0.1.3 (registry+https://github.com/rust-lang/crates.io-index)",
  "winapi 0.2.8 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
 name = "webrender"
-version = "0.54.0"
+version = "0.55.0"
 dependencies = [
  "app_units 0.5.6 (registry+https://github.com/rust-lang/crates.io-index)",
  "bincode 0.9.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "bitflags 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
- "byteorder 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "byteorder 1.2.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "core-foundation 0.4.4 (registry+https://github.com/rust-lang/crates.io-index)",
  "core-graphics 0.12.3 (registry+https://github.com/rust-lang/crates.io-index)",
  "core-text 8.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
- "dwrote 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "dwrote 0.4.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "euclid 0.15.5 (registry+https://github.com/rust-lang/crates.io-index)",
  "freetype 0.3.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "fxhash 0.2.1 (registry+https://github.com/rust-lang/crates.io-index)",
- "gleam 0.4.14 (registry+https://github.com/rust-lang/crates.io-index)",
+ "gleam 0.4.15 (registry+https://github.com/rust-lang/crates.io-index)",
  "lazy_static 0.2.8 (registry+https://github.com/rust-lang/crates.io-index)",
  "log 0.3.8 (registry+https://github.com/rust-lang/crates.io-index)",
  "num-traits 0.1.39 (registry+https://github.com/rust-lang/crates.io-index)",
  "plane-split 0.6.0 (registry+https://github.com/rust-lang/crates.io-index)",
  "rayon 0.8.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "thread_profiler 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "time 0.1.36 (registry+https://github.com/rust-lang/crates.io-index)",
- "webrender_api 0.54.0",
+ "webrender_api 0.55.0",
 ]
 
 [[package]]
 name = "webrender_api"
-version = "0.54.0"
+version = "0.55.0"
 dependencies = [
  "app_units 0.5.6 (registry+https://github.com/rust-lang/crates.io-index)",
  "bincode 0.9.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "bitflags 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
- "byteorder 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "byteorder 1.2.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "core-foundation 0.4.4 (registry+https://github.com/rust-lang/crates.io-index)",
  "core-graphics 0.12.3 (registry+https://github.com/rust-lang/crates.io-index)",
- "dwrote 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "dwrote 0.4.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "euclid 0.15.5 (registry+https://github.com/rust-lang/crates.io-index)",
  "serde 1.0.8 (registry+https://github.com/rust-lang/crates.io-index)",
  "time 0.1.36 (registry+https://github.com/rust-lang/crates.io-index)",
 ]
 
 [[package]]
 name = "webrender_bindings"
 version = "0.1.0"
 dependencies = [
  "app_units 0.5.6 (registry+https://github.com/rust-lang/crates.io-index)",
  "core-foundation 0.4.4 (registry+https://github.com/rust-lang/crates.io-index)",
  "core-graphics 0.12.3 (registry+https://github.com/rust-lang/crates.io-index)",
- "dwrote 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
+ "dwrote 0.4.1 (registry+https://github.com/rust-lang/crates.io-index)",
  "euclid 0.15.5 (registry+https://github.com/rust-lang/crates.io-index)",
  "foreign-types 0.3.0 (registry+https://github.com/rust-lang/crates.io-index)",
- "gleam 0.4.14 (registry+https://github.com/rust-lang/crates.io-index)",
+ "gleam 0.4.15 (registry+https://github.com/rust-lang/crates.io-index)",
  "log 0.3.8 (registry+https://github.com/rust-lang/crates.io-index)",
  "rayon 0.8.2 (registry+https://github.com/rust-lang/crates.io-index)",
  "thread_profiler 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)",
- "webrender 0.54.0",
+ "webrender 0.55.0",
 ]
 
 [[package]]
 name = "which"
 version = "1.0.3"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 dependencies = [
  "libc 0.2.24 (registry+https://github.com/rust-lang/crates.io-index)",
@@ -1610,17 +1610,17 @@ dependencies = [
 "checksum bincode 0.8.0 (registry+https://github.com/rust-lang/crates.io-index)" = "e103c8b299b28a9c6990458b7013dc4a8356a9b854c51b9883241f5866fac36e"
 "checksum bincode 0.9.1 (registry+https://github.com/rust-lang/crates.io-index)" = "9d3fb369af639822830328794eba2501b3479652fcd021b2aeb1ed4984202afd"
 "checksum bindgen 0.31.3 (registry+https://github.com/rust-lang/crates.io-index)" = "57253399c086f4f29e57ffd3b5cdbc23a806a00292619351aa4cfa39cb49d4ea"
 "checksum bitflags 0.7.0 (registry+https://github.com/rust-lang/crates.io-index)" = "aad18937a628ec6abcd26d1489012cc0e18c21798210f491af69ded9b881106d"
 "checksum bitflags 0.9.1 (registry+https://github.com/rust-lang/crates.io-index)" = "4efd02e230a02e18f92fc2735f44597385ed02ad8f831e7c1c1156ee5e1ab3a5"
 "checksum bitflags 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)" = "f5cde24d1b2e2216a726368b2363a273739c91f4e3eb4e0dd12d672d396ad989"
 "checksum bitreader 0.3.0 (registry+https://github.com/rust-lang/crates.io-index)" = "80b13e2ab064ff3aa0bdbf1eff533f9822dc37899821f5f98c67f263eab51707"
 "checksum boxfnonce 0.0.3 (registry+https://github.com/rust-lang/crates.io-index)" = "8380105befe91099e6f69206164072c05bc92427ff6aa8a5171388317346dd75"
-"checksum byteorder 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)" = "c40977b0ee6b9885c9013cd41d9feffdd22deb3bb4dc3a71d901cc7a77de18c8"
+"checksum byteorder 1.2.1 (registry+https://github.com/rust-lang/crates.io-index)" = "652805b7e73fada9d85e9a6682a4abd490cb52d96aeecc12e33a0de34dfd0d23"
 "checksum bytes 0.4.5 (registry+https://github.com/rust-lang/crates.io-index)" = "d828f97b58cc5de3e40c421d0cf2132d6b2da4ee0e11b8632fa838f0f9333ad6"
 "checksum cexpr 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)" = "393a5f0088efbe41f9d1fcd062f24e83c278608420e62109feb2c8abee07de7d"
 "checksum cfg-if 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)" = "d0c47d456a36ebf0536a6705c83c1cbbcb9255fbc1d905a6ded104f479268a29"
 "checksum clang-sys 0.21.1 (registry+https://github.com/rust-lang/crates.io-index)" = "00048189ee171715296dfe3b2fcfd439563c7bfec0d98d3976ce3402d62c8f07"
 "checksum clap 2.25.0 (registry+https://github.com/rust-lang/crates.io-index)" = "867a885995b4184be051b70a592d4d70e32d7a188db6e8dff626af286a962771"
 "checksum coco 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)" = "c06169f5beb7e31c7c67ebf5540b8b472d23e3eade3b2ec7d1f5b504a85f91bd"
 "checksum core-foundation 0.4.4 (registry+https://github.com/rust-lang/crates.io-index)" = "5909502e547762013619f4c4e01cc7393c20fe2d52d7fa471c1210adb2320dc7"
 "checksum core-foundation-sys 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)" = "41115a6aa5d3e1e5ef98148373f25971d1fad53818553f216495f9e67e90a624"
@@ -1631,34 +1631,34 @@ dependencies = [
 "checksum cose-c 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)" = "07cc8bb85ec2e93541ef9369b85a4b6fb7732bc7f4854d317eab20e726b0fc2f"
 "checksum cssparser 0.22.0 (registry+https://github.com/rust-lang/crates.io-index)" = "44313341610282488e1156ad1fedebca51c54766c87a041d0287b10499c04ba1"
 "checksum cssparser-macros 0.3.0 (registry+https://github.com/rust-lang/crates.io-index)" = "079adec4af52bb5275eadd004292028c79eb3c5f5b4ee8086a36d4197032f6df"
 "checksum darling 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)" = "9861a8495606435477df581bc858ccf15a3469747edf175b94a4704fd9aaedac"
 "checksum darling_core 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)" = "1486a8b00b45062c997f767738178b43219133dd0c8c826cb811e60563810821"
 "checksum darling_macro 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)" = "8a86ec160aa0c3dd492dd4a14ec8104ad8f1a9400a820624db857998cc1f80f9"
 "checksum dtoa 0.4.2 (registry+https://github.com/rust-lang/crates.io-index)" = "09c3753c3db574d215cba4ea76018483895d7bff25a31b49ba45db21c48e50ab"
 "checksum dtoa-short 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)" = "068d4026697c1a18f0b0bb8cfcad1b0c151b90d8edb9bf4c235ad68128920d1d"
-"checksum dwrote 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)" = "36e3b27cd0b8a68e00f07e8d8e1e4f4d8a6b8b873290a734f63bd56d792d23e1"
+"checksum dwrote 0.4.1 (registry+https://github.com/rust-lang/crates.io-index)" = "a207eb7b40e25d1d28dc679f451d321fb6954b73ceaa47986702575865469461"
 "checksum either 1.1.0 (registry+https://github.com/rust-lang/crates.io-index)" = "18785c1ba806c258137c937e44ada9ee7e69a37e3c72077542cd2f069d78562a"
 "checksum encoding_c 0.8.0 (registry+https://github.com/rust-lang/crates.io-index)" = "93ec52324ca72f423237a413ca0e1c60654c8b3d0934fcd5fd888508dfcc4ba7"
 "checksum encoding_rs 0.7.1 (registry+https://github.com/rust-lang/crates.io-index)" = "f5215aabf22b83153be3ee44dfe3f940214541b2ce13d419c55e7a115c8c51a9"
 "checksum env_logger 0.4.3 (registry+https://github.com/rust-lang/crates.io-index)" = "3ddf21e73e016298f5cb37d6ef8e8da8e39f91f9ec8b0df44b7deb16a9f8cd5b"
 "checksum error-chain 0.10.0 (registry+https://github.com/rust-lang/crates.io-index)" = "d9435d864e017c3c6afeac1654189b06cdb491cf2ff73dbf0d73b0f292f42ff8"
 "checksum euclid 0.15.5 (registry+https://github.com/rust-lang/crates.io-index)" = "f5ed7d77e46f6600f490463ad7b6349c3ebb2d2319af56e679e279e4c66495d9"
 "checksum fnv 1.0.5 (registry+https://github.com/rust-lang/crates.io-index)" = "6cc484842f1e2884faf56f529f960cc12ad8c71ce96cc7abba0a067c98fee344"
 "checksum foreign-types 0.3.0 (registry+https://github.com/rust-lang/crates.io-index)" = "5ebc04f19019fff1f2d627b5581574ead502f80c48c88900575a46e0840fe5d0"
 "checksum freetype 0.3.0 (registry+https://github.com/rust-lang/crates.io-index)" = "398b8a11884898184d55aca9806f002b3cf68f0e860e0cbb4586f834ee39b0e7"
 "checksum fs2 0.4.2 (registry+https://github.com/rust-lang/crates.io-index)" = "9ab76cfd2aaa59b7bf6688ad9ba15bbae64bff97f04ea02144cfd3443e5c2866"
 "checksum fuchsia-zircon 0.2.1 (registry+https://github.com/rust-lang/crates.io-index)" = "f6c0581a4e363262e52b87f59ee2afe3415361c6ec35e665924eb08afe8ff159"
 "checksum fuchsia-zircon-sys 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)" = "43f3795b4bae048dc6123a6b972cadde2e676f9ded08aef6bb77f5f157684a82"
 "checksum futures 0.1.13 (registry+https://github.com/rust-lang/crates.io-index)" = "55f0008e13fc853f79ea8fc86e931486860d4c4c156cdffb59fa5f7fa833660a"
 "checksum fxhash 0.2.1 (registry+https://github.com/rust-lang/crates.io-index)" = "c31b6d751ae2c7f11320402d34e41349dd1016f8d5d45e48c4312bc8625af50c"
 "checksum gdi32-sys 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)" = "0912515a8ff24ba900422ecda800b52f4016a56251922d397c576bf92c690518"
 "checksum gl_generator 0.6.1 (registry+https://github.com/rust-lang/crates.io-index)" = "75d69f914b49d9ff32fdf394cbd798f8c716d74fd19f9cc29da3e99797b2a78d"
-"checksum gleam 0.4.14 (registry+https://github.com/rust-lang/crates.io-index)" = "8bd6aa276bc0bf40348728e916a82f8f9cc10b1922cabf9f2fe9cd5e8b98d55b"
+"checksum gleam 0.4.15 (registry+https://github.com/rust-lang/crates.io-index)" = "dff613336334932baaa2759d001f14e06ea1a08a247c05962d1423aa0e89ee99"
 "checksum glob 0.2.11 (registry+https://github.com/rust-lang/crates.io-index)" = "8be18de09a56b60ed0edf84bc9df007e30040691af7acd1c41874faac5895bfb"
 "checksum heapsize 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)" = "4c7593b1522161003928c959c20a2ca421c68e940d63d75573316a009e48a6d4"
 "checksum ident_case 1.0.0 (registry+https://github.com/rust-lang/crates.io-index)" = "3c9826188e666f2ed92071d2dadef6edc430b11b158b5b2b3f4babbcc891eaaa"
 "checksum idna 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)" = "014b298351066f1512874135335d62a789ffe78a9974f94b43ed5621951eaf7d"
 "checksum iovec 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)" = "29d062ee61fccdf25be172e70f34c9f6efc597e1fb8f6526e8437b2046ab26be"
 "checksum itertools 0.5.10 (registry+https://github.com/rust-lang/crates.io-index)" = "4833d6978da405305126af4ac88569b5d71ff758581ce5a987dbfa3755f694fc"
 "checksum itoa 0.3.1 (registry+https://github.com/rust-lang/crates.io-index)" = "eb2f404fbc66fd9aac13e998248505e7ecb2ad8e44ab6388684c5fb11c6c251c"
 "checksum kernel32-sys 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)" = "7507624b29483431c0ba2d82aece8ca6cdba9382bff4ddd0f7490560c056098d"