about summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--example/mini_core_hello_world.rs6
-rw-r--r--src/main_shim.rs4
2 files changed, 4 insertions, 6 deletions
diff --git a/example/mini_core_hello_world.rs b/example/mini_core_hello_world.rs
index 09d5b73fd3d..0b3a7281d5a 100644
--- a/example/mini_core_hello_world.rs
+++ b/example/mini_core_hello_world.rs
@@ -387,11 +387,9 @@ global_asm! {
 }
 
 #[cfg(all(not(jit), target_arch = "x86_64"))]
-#[naked]
+#[unsafe(naked)]
 extern "C" fn naked_test() {
-    unsafe {
-        naked_asm!("ret");
-    }
+    naked_asm!("ret")
 }
 
 #[repr(C)]
diff --git a/src/main_shim.rs b/src/main_shim.rs
index 3b48adb7e91..6eef97c14dd 100644
--- a/src/main_shim.rs
+++ b/src/main_shim.rs
@@ -1,6 +1,6 @@
 use cranelift_frontend::{FunctionBuilder, FunctionBuilderContext};
 use rustc_hir::LangItem;
-use rustc_middle::ty::{AssocKind, GenericArg};
+use rustc_middle::ty::{AssocTag, GenericArg};
 use rustc_session::config::EntryFnType;
 use rustc_span::{DUMMY_SP, Ident};
 
@@ -107,7 +107,7 @@ pub(crate) fn maybe_create_entry_wrapper(
                     .find_by_ident_and_kind(
                         tcx,
                         Ident::from_str("report"),
-                        AssocKind::Fn,
+                        AssocTag::Fn,
                         termination_trait,
                     )
                     .unwrap();