mirror of
https://github.com/servo/servo.git
synced 2025-08-06 22:15:33 +01:00
style: Update stylo to itertools:0.10, itoa:1.0 and toml:0.5
Differential Revision: https://phabricator.services.mozilla.com/D149454
This commit is contained in:
parent
becb855b3a
commit
fb95cb7993
3 changed files with 22 additions and 16 deletions
|
@ -48,8 +48,8 @@ euclid = "0.22"
|
|||
fxhash = "0.2"
|
||||
html5ever = { version = "0.26", optional = true }
|
||||
indexmap = "1.0"
|
||||
itertools = "0.8"
|
||||
itoa = "0.4"
|
||||
itertools = "0.10"
|
||||
itoa = "1.0"
|
||||
lazy_static = "1"
|
||||
log = { version = "0.4", features = ["std"] }
|
||||
malloc_size_of = { path = "../malloc_size_of" }
|
||||
|
|
|
@ -619,7 +619,10 @@ impl Color {
|
|||
let mut serialization = [b'0'; 6];
|
||||
let space_padding = 6 - total;
|
||||
let mut written = space_padding;
|
||||
written += itoa::write(&mut serialization[written..], value).unwrap();
|
||||
let mut buf = itoa::Buffer::new();
|
||||
let s = buf.format(value);
|
||||
(&mut serialization[written..]).write_all(s.as_bytes()).unwrap();
|
||||
written += s.len();
|
||||
if let Some(unit) = unit {
|
||||
written += (&mut serialization[written..])
|
||||
.write(unit.as_bytes())
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue