about summary refs log tree commit diff
path: root/src/librustc_driver
diff options
context:
space:
mode:
authorEduard-Mihai Burtescu <edy.burt@gmail.com>2019-06-12 00:11:55 +0300
committerEduard-Mihai Burtescu <edy.burt@gmail.com>2019-06-12 13:38:28 +0300
commitfff08cb04389497d254fb40948674cbbee402908 (patch)
treeacf887abc09ef60cbd7e18e733da83c50a4f3939 /src/librustc_driver
parent21ac960334485bfad6818510bc12dc65129f2c39 (diff)
downloadrust-fff08cb04389497d254fb40948674cbbee402908.tar.gz
rust-fff08cb04389497d254fb40948674cbbee402908.zip
Run `rustfmt --file-lines ...` for changes from previous commits.
Diffstat (limited to 'src/librustc_driver')
-rw-r--r--src/librustc_driver/pretty.rs42
1 files changed, 21 insertions, 21 deletions
diff --git a/src/librustc_driver/pretty.rs b/src/librustc_driver/pretty.rs
index a447baa7f41..4f19a7bbc8b 100644
--- a/src/librustc_driver/pretty.rs
+++ b/src/librustc_driver/pretty.rs
@@ -154,12 +154,14 @@ pub fn parse_pretty(sess: &Session,
 
 impl PpSourceMode {
     /// Constructs a `PrinterSupport` object and passes it to `f`.
-    fn call_with_pp_support<'tcx, A, F>(&self,
-                                        sess: &'tcx Session,
-                                        tcx: Option<TyCtxt<'tcx, 'tcx>>,
-                                        f: F)
-                                        -> A
-        where F: FnOnce(&dyn PrinterSupport) -> A
+    fn call_with_pp_support<'tcx, A, F>(
+        &self,
+        sess: &'tcx Session,
+        tcx: Option<TyCtxt<'tcx, 'tcx>>,
+        f: F,
+    ) -> A
+    where
+        F: FnOnce(&dyn PrinterSupport) -> A,
     {
         match *self {
             PpmNormal | PpmEveryBodyLoops | PpmExpanded => {
@@ -186,12 +188,9 @@ impl PpSourceMode {
             _ => panic!("Should use call_with_pp_support_hir"),
         }
     }
-    fn call_with_pp_support_hir<'tcx, A, F>(
-        &self,
-        tcx: TyCtxt<'tcx, 'tcx>,
-        f: F
-    ) -> A
-        where F: FnOnce(&dyn HirPrinterSupport<'_>, &hir::Crate) -> A
+    fn call_with_pp_support_hir<'tcx, A, F>(&self, tcx: TyCtxt<'tcx, 'tcx>, f: F) -> A
+    where
+        F: FnOnce(&dyn HirPrinterSupport<'_>, &hir::Crate) -> A,
     {
         match *self {
             PpmNormal => {
@@ -454,7 +453,6 @@ impl<'a> pprust::PpAnn for HygieneAnnotation<'a> {
     }
 }
 
-
 struct TypedAnnotation<'a, 'tcx: 'a> {
     tcx: TyCtxt<'tcx, 'tcx>,
     tables: Cell<&'a ty::TypeckTables<'tcx>>,
@@ -617,12 +615,13 @@ impl UserIdentifiedItem {
     }
 }
 
-fn print_flowgraph<'tcx, W: Write>(variants: Vec<borrowck_dot::Variant>,
-                                       tcx: TyCtxt<'tcx, 'tcx>,
-                                       code: blocks::Code<'tcx>,
-                                       mode: PpFlowGraphMode,
-                                       mut out: W)
-                                       -> io::Result<()> {
+fn print_flowgraph<'tcx, W: Write>(
+    variants: Vec<borrowck_dot::Variant>,
+    tcx: TyCtxt<'tcx, 'tcx>,
+    code: blocks::Code<'tcx>,
+    mode: PpFlowGraphMode,
+    mut out: W,
+) -> io::Result<()> {
     let body_id = match code {
         blocks::Code::Expr(expr) => {
             // Find the function this expression is from.
@@ -760,7 +759,8 @@ pub fn print_after_hir_lowering<'tcx>(
     krate: &ast::Crate,
     ppm: PpMode,
     opt_uii: Option<UserIdentifiedItem>,
-    ofile: Option<&Path>) {
+    ofile: Option<&Path>,
+) {
     if ppm.needs_analysis() {
         abort_on_err(print_with_analysis(
             tcx,
@@ -869,7 +869,7 @@ fn print_with_analysis<'tcx>(
     tcx: TyCtxt<'tcx, 'tcx>,
     ppm: PpMode,
     uii: Option<UserIdentifiedItem>,
-    ofile: Option<&Path>
+    ofile: Option<&Path>,
 ) -> Result<(), ErrorReported> {
     let nodeid = if let Some(uii) = uii {
         debug!("pretty printing for {:?}", uii);