about summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--src/librustc/middle/borrowck/preserve.rs16
-rw-r--r--src/librustc/middle/trans/consts.rs3
2 files changed, 10 insertions, 9 deletions
diff --git a/src/librustc/middle/borrowck/preserve.rs b/src/librustc/middle/borrowck/preserve.rs
index 61c6fc8199d..2cb188110fe 100644
--- a/src/librustc/middle/borrowck/preserve.rs
+++ b/src/librustc/middle/borrowck/preserve.rs
@@ -358,14 +358,14 @@ priv impl &preserve_ctxt {
                 debug!("Elected to root");
                 let rk = {id: base.id, derefs: derefs};
                 // This code could potentially lead cause boxes to be frozen
-                // for longer than necessarily at runtime. It prevents an ICE
-                // in trans; the fundamental problem is that it's hard to make
-                // sure trans and borrowck have the same notion of scope. The
-                // real fix is to clean up how trans handles cleanups, but
-                // that's hard. If this becomes an issue, it's an option to just
-                // change this to `let scope_to_use = scope_id;`. Though that
-                // would potentially re-introduce the ICE. See #3511 for more
-                // details.
+                // for longer than necessarily at runtime. It prevents an
+                // ICE in trans; the fundamental problem is that it's hard
+                // to make sure trans and borrowck have the same notion of
+                // scope. The real fix is to clean up how trans handles
+                // cleanups, but that's hard. If this becomes an issue, it's
+                // an option to just change this to `let scope_to_use =
+                // scope_id;`. Though that would potentially re-introduce
+                // the ICE. See #3511 for more details.
                 let scope_to_use = if
                     self.bccx.stmt_map.contains_key(scope_id) {
                     // Root it in its parent scope, b/c
diff --git a/src/librustc/middle/trans/consts.rs b/src/librustc/middle/trans/consts.rs
index c36afb8355f..11d18706b90 100644
--- a/src/librustc/middle/trans/consts.rs
+++ b/src/librustc/middle/trans/consts.rs
@@ -405,7 +405,8 @@ fn const_expr(cx: @crate_ctxt, e: @ast::expr) -> ValueRef {
                     assert ast_util::is_local(def_id);
                     let f = base::get_item_val(cx, def_id.node);
                     match purity {
-                      ast::extern_fn => llvm::LLVMConstPointerCast(f, T_ptr(T_i8())),
+                      ast::extern_fn =>
+                        llvm::LLVMConstPointerCast(f, T_ptr(T_i8())),
                       _ => C_struct(~[f, C_null(T_opaque_box_ptr(cx))])
                     }
                 }