diff options
Diffstat (limited to 'src/librustdoc/html/format.rs')
| -rw-r--r-- | src/librustdoc/html/format.rs | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/src/librustdoc/html/format.rs b/src/librustdoc/html/format.rs index 4cde868201e..fd620d467de 100644 --- a/src/librustdoc/html/format.rs +++ b/src/librustdoc/html/format.rs @@ -63,6 +63,13 @@ impl Buffer { } } + crate fn new() -> Buffer { + Buffer { + for_html: false, + buffer: String::new(), + } + } + crate fn is_empty(&self) -> bool { self.buffer.is_empty() } @@ -106,6 +113,10 @@ impl Buffer { write!(self, "{:#}", t); } } + + crate fn is_for_html(&self) -> bool { + self.for_html + } } /// Wrapper struct for properly emitting a function or method declaration. |
