Skip to content

Commit 88d6b60

Browse files
committed
---
yaml --- r: 212599 b: refs/heads/auto c: 63da18b h: refs/heads/master i: 212597: 0913f8e 212595: e52978c 212591: da6c127 v: v3
1 parent bcb9ff8 commit 88d6b60

File tree

3 files changed

+17
-9
lines changed

3 files changed

+17
-9
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ refs/tags/release-0.3: b5f0d0f648d9a6153664837026ba1be43d3e2503
1010
refs/tags/release-0.3.1: 495bae036dfe5ec6ceafd3312b4dca48741e845b
1111
refs/tags/release-0.4: e828ea2080499553b97dfe33b3f4d472b4562ad7
1212
refs/tags/release-0.5: 7e3bcfbf21278251ee936ad53e92e9b719702d73
13-
refs/heads/auto: 15b028c5859f98b32cde69b81dd62468039db0be
13+
refs/heads/auto: 63da18b269128c6594b0fa60064b187a9b5d0418
1414
refs/heads/servo: af82457af293e2a842ba6b7759b70288da276167
1515
refs/tags/release-0.6: b4ebcfa1812664df5e142f0134a5faea3918544c
1616
refs/tags/0.1: b19db808c2793fe2976759b85a355c3ad8c8b336

branches/auto/src/libcore/fmt/mod.rs

Lines changed: 15 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -731,13 +731,6 @@ impl<'a> Formatter<'a> {
731731
self.buf.write_str(data)
732732
}
733733

734-
/// Writes a `char` to the underlying buffer contained within this
735-
/// formatter.
736-
#[stable(feature = "fmt_write_char", since = "1.1.0")]
737-
pub fn write_char(&mut self, c: char) -> Result {
738-
self.buf.write_char(c)
739-
}
740-
741734
/// Writes some formatted information into this instance
742735
#[stable(feature = "rust1", since = "1.0.0")]
743736
pub fn write_fmt(&mut self, fmt: Arguments) -> Result {
@@ -899,6 +892,21 @@ impl<'a> Formatter<'a> {
899892
}
900893
}
901894

895+
#[stable(since = "1.2.0", feature = "formatter_write")]
896+
impl<'a> Write for Formatter<'a> {
897+
fn write_str(&mut self, s: &str) -> Result {
898+
self.buf.write_str(s)
899+
}
900+
901+
fn write_char(&mut self, c: char) -> Result {
902+
self.buf.write_char(c)
903+
}
904+
905+
fn write_fmt(&mut self, args: Arguments) -> Result {
906+
write(self.buf, args)
907+
}
908+
}
909+
902910
#[stable(feature = "rust1", since = "1.0.0")]
903911
impl Display for Error {
904912
fn fmt(&self, f: &mut Formatter) -> Result {

branches/auto/src/test/run-pass/ifmt.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
#![allow(unknown_features)]
1616
#![feature(box_syntax)]
1717

18-
use std::fmt;
18+
use std::fmt::{self, Write};
1919
use std::usize;
2020

2121
struct A;

0 commit comments

Comments
 (0)