]> git.lizzy.rs Git - rust.git/commitdiff
return TargetResult
authorJorge Aparicio <japaricious@gmail.com>
Sat, 30 Jul 2016 20:44:59 +0000 (15:44 -0500)
committerJorge Aparicio <japaricious@gmail.com>
Sat, 30 Jul 2016 20:44:59 +0000 (15:44 -0500)
src/librustc_back/target/arm_unknown_linux_musleabi.rs
src/librustc_back/target/arm_unknown_linux_musleabihf.rs
src/librustc_back/target/armv7_unknown_linux_musleabihf.rs

index 4bc363d0ffda1244320aaf2b174ffa3083995076..028c91eadaeb3e672b00f016a1f9df6278c13f08 100644 (file)
@@ -8,16 +8,16 @@
 // option. This file may not be copied, modified, or distributed
 // except according to those terms.
 
-use target::Target;
+use target::{Target, TargetResult};
 
-pub fn target() -> Target {
+pub fn target() -> TargetResult {
     let mut base = super::linux_musl_base::opts();
 
     // Most of these settings are copied from the arm_unknown_linux_gnueabi
     // target.
     base.features = "+v6".to_string();
     base.max_atomic_width = 64;
-    Target {
+    Ok(Target {
         // It's important we use "gnueabi" and not "musleabi" here. LLVM uses it
         // to determine the calling convention and float ABI, and it doesn't
         // support the "musleabi" value.
@@ -30,5 +30,5 @@ pub fn target() -> Target {
         target_env: "musl".to_string(),
         target_vendor: "unknown".to_string(),
         options: base,
-    }
+    })
 }
index d96f7443dd9c6a7e2f08c8f02a2dfabb11458795..c7dda186f42589cb97a8be622a7e5c635381aa86 100644 (file)
@@ -8,16 +8,16 @@
 // option. This file may not be copied, modified, or distributed
 // except according to those terms.
 
-use target::Target;
+use target::{Target, TargetResult};
 
-pub fn target() -> Target {
+pub fn target() -> TargetResult {
     let mut base = super::linux_musl_base::opts();
 
     // Most of these settings are copied from the arm_unknown_linux_gnueabihf
     // target.
     base.features = "+v6,+vfp2".to_string();
     base.max_atomic_width = 64;
-    Target {
+    Ok(Target {
         // It's important we use "gnueabihf" and not "musleabihf" here. LLVM
         // uses it to determine the calling convention and float ABI, and it
         // doesn't support the "musleabihf" value.
@@ -30,5 +30,5 @@ pub fn target() -> Target {
         target_env: "musl".to_string(),
         target_vendor: "unknown".to_string(),
         options: base,
-    }
+    })
 }
index 6cb75cbf04cbf2439bbd22c59a0e04876ad59bff..e40704e5d49975e56c51bb88b22b0485bba7f530 100644 (file)
@@ -8,9 +8,9 @@
 // option. This file may not be copied, modified, or distributed
 // except according to those terms.
 
-use target::Target;
+use target::{Target, TargetResult};
 
-pub fn target() -> Target {
+pub fn target() -> TargetResult {
     let mut base = super::linux_musl_base::opts();
 
     // Most of these settings are copied from the armv7_unknown_linux_gnueabihf
@@ -18,7 +18,7 @@ pub fn target() -> Target {
     base.features = "+v7,+vfp3,+neon".to_string();
     base.cpu = "cortex-a8".to_string();
     base.max_atomic_width = 64;
-    Target {
+    Ok(Target {
         // It's important we use "gnueabihf" and not "musleabihf" here. LLVM
         // uses it to determine the calling convention and float ABI, and LLVM
         // doesn't support the "musleabihf" value.
@@ -31,5 +31,5 @@ pub fn target() -> Target {
         target_env: "musl".to_string(),
         target_vendor: "unknown".to_string(),
         options: base,
-    }
+    })
 }