diff options
| author | David Tolnay <dtolnay@gmail.com> | 2022-01-14 21:12:39 -0800 |
|---|---|---|
| committer | David Tolnay <dtolnay@gmail.com> | 2022-01-14 21:12:39 -0800 |
| commit | 953da9832da3ceeb6927d177e86868039f95e08a (patch) | |
| tree | 7a8e488d3df4c30e69b261793830eaf82c2e9311 /compiler/rustc_hir_pretty | |
| parent | de9b573eedaaa6d6e7c00c986cccbee802f9287b (diff) | |
| download | rust-953da9832da3ceeb6927d177e86868039f95e08a.tar.gz rust-953da9832da3ceeb6927d177e86868039f95e08a.zip | |
Rename Printer constructor from mk_printer() to Printer::new()
Diffstat (limited to 'compiler/rustc_hir_pretty')
| -rw-r--r-- | compiler/rustc_hir_pretty/src/lib.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/compiler/rustc_hir_pretty/src/lib.rs b/compiler/rustc_hir_pretty/src/lib.rs index 4c9e2d7fe42..88561f8afc5 100644 --- a/compiler/rustc_hir_pretty/src/lib.rs +++ b/compiler/rustc_hir_pretty/src/lib.rs @@ -170,7 +170,7 @@ impl<'a> State<'a> { ann: &'a dyn PpAnn, ) -> State<'a> { State { - s: pp::mk_printer(), + s: pp::Printer::new(), comments: Some(Comments::new(sm, filename, input)), attrs, ann, @@ -186,7 +186,7 @@ pub fn to_string<F>(ann: &dyn PpAnn, f: F) -> String where F: FnOnce(&mut State<'_>), { - let mut printer = State { s: pp::mk_printer(), comments: None, attrs: &|_| &[], ann }; + let mut printer = State { s: pp::Printer::new(), comments: None, attrs: &|_| &[], ann }; f(&mut printer); printer.s.eof() } |
