]> git.lizzy.rs Git - rust.git/blobdiff - compiler/rustc_codegen_cranelift/example/mini_core_hello_world.rs
Merge commit '03f01bbe901d60b71cf2c5ec766aef5e532ab79d' into update_cg_clif-2020...
[rust.git] / compiler / rustc_codegen_cranelift / example / mini_core_hello_world.rs
index 376056e19383fd1f4ac71043726ecc40e7630e43..4a8375afac3cef46815d38becae87267dcc7461c 100644 (file)
@@ -287,6 +287,8 @@ struct ExternTypeWrapper {
     assert_eq!(repeat[0], Some(42));
     assert_eq!(repeat[1], Some(42));
 
+    from_decimal_string();
+
     #[cfg(not(jit))]
     test_tls();
 
@@ -446,3 +448,23 @@ fn check_niche_behavior () {
         intrinsics::abort();
     }
 }
+
+fn from_decimal_string() {
+    loop {
+        let multiplier = 1;
+
+        take_multiplier_ref(&multiplier);
+
+        if multiplier == 1 {
+            break;
+        }
+
+        unreachable();
+    }
+}
+
+fn take_multiplier_ref(_multiplier: &u128) {}
+
+fn unreachable() -> ! {
+    panic("unreachable")
+}