about summary refs log tree commit diff
diff options
context:
space:
mode:
authorbjorn3 <bjorn3@users.noreply.github.com>2021-08-20 15:06:07 +0200
committerbjorn3 <bjorn3@users.noreply.github.com>2021-08-20 15:06:07 +0200
commit7a781a53f032f61c3dc306be87fd8648060bf1cc (patch)
tree3fbe4aea873b9afe27c298ff4e989e54d48cd2bb
parentd498e6d6971575714353f11aa4d3e63a9d2030b2 (diff)
parent8b8ab5f599f04d83f31994a47cf2345dbaddd38b (diff)
downloadrust-7a781a53f032f61c3dc306be87fd8648060bf1cc.tar.gz
rust-7a781a53f032f61c3dc306be87fd8648060bf1cc.zip
Sync from rust 9ccf661694423895b02e513c69e6ad263b2f3d8e
-rw-r--r--example/alloc_example.rs2
-rw-r--r--example/mini_core_hello_world.rs2
-rw-r--r--example/mod_bench.rs2
-rw-r--r--src/debuginfo/mod.rs2
-rw-r--r--src/intrinsics/mod.rs5
5 files changed, 9 insertions, 4 deletions
diff --git a/example/alloc_example.rs b/example/alloc_example.rs
index 71e93e87b6c..2a9f7e58e01 100644
--- a/example/alloc_example.rs
+++ b/example/alloc_example.rs
@@ -1,4 +1,4 @@
-#![feature(start, box_syntax, core_intrinsics, alloc_prelude, alloc_error_handler)]
+#![feature(start, core_intrinsics, alloc_prelude, alloc_error_handler)]
 #![no_std]
 
 extern crate alloc;
diff --git a/example/mini_core_hello_world.rs b/example/mini_core_hello_world.rs
index d997ce6d1b3..6e13e4dcbfb 100644
--- a/example/mini_core_hello_world.rs
+++ b/example/mini_core_hello_world.rs
@@ -1,4 +1,4 @@
-#![feature(no_core, lang_items, box_syntax, never_type, linkage, extern_types, thread_local)]
+#![feature(no_core, lang_items, never_type, linkage, extern_types, thread_local)]
 #![no_core]
 #![allow(dead_code, non_camel_case_types)]
 
diff --git a/example/mod_bench.rs b/example/mod_bench.rs
index 152041aa9ed..e3e8a3c2d6a 100644
--- a/example/mod_bench.rs
+++ b/example/mod_bench.rs
@@ -1,4 +1,4 @@
-#![feature(start, box_syntax, core_intrinsics, lang_items)]
+#![feature(start, core_intrinsics, lang_items)]
 #![no_std]
 
 #[cfg_attr(unix, link(name = "c"))]
diff --git a/src/debuginfo/mod.rs b/src/debuginfo/mod.rs
index ceef65d5478..c471da83de2 100644
--- a/src/debuginfo/mod.rs
+++ b/src/debuginfo/mod.rs
@@ -66,7 +66,7 @@ impl<'tcx> DebugContext<'tcx> {
             rustc_interface::util::version_str().unwrap_or("unknown version"),
             cranelift_codegen::VERSION,
         );
-        let comp_dir = tcx.sess.working_dir.to_string_lossy(false).into_owned();
+        let comp_dir = tcx.sess.opts.working_dir.to_string_lossy(false).into_owned();
         let (name, file_info) = match tcx.sess.local_crate_source_file.clone() {
             Some(path) => {
                 let name = path.to_string_lossy().into_owned();
diff --git a/src/intrinsics/mod.rs b/src/intrinsics/mod.rs
index 86698460747..1c4d307fc50 100644
--- a/src/intrinsics/mod.rs
+++ b/src/intrinsics/mod.rs
@@ -1136,6 +1136,11 @@ pub(crate) fn codegen_intrinsic_call<'tcx>(
                 };
             ret.write_cvalue(fx, CValue::by_val(is_eq_value, ret.layout()));
         };
+
+        black_box, (c a) {
+            // FIXME implement black_box semantics
+            ret.write_cvalue(fx, a);
+        };
     }
 
     if let Some((_, dest)) = destination {