diff options
| author | Jubilee Young <workingjubilee@gmail.com> | 2024-10-08 19:07:43 -0700 |
|---|---|---|
| committer | Jubilee Young <workingjubilee@gmail.com> | 2024-10-11 17:41:52 -0700 |
| commit | 559de745626901cf1fba5aaa5a2b96fbc92e09ff (patch) | |
| tree | d0a723728bd1c7f655c4414c9ec75713af723c20 | |
| parent | 1bc403daadbebb553ccc211a0a8eebb73989665f (diff) | |
| download | rust-559de745626901cf1fba5aaa5a2b96fbc92e09ff.tar.gz rust-559de745626901cf1fba5aaa5a2b96fbc92e09ff.zip | |
compiler: Move impl of ToJson for abi::Endian
| -rw-r--r-- | compiler/rustc_target/src/abi/mod.rs | 8 | ||||
| -rw-r--r-- | compiler/rustc_target/src/json.rs | 6 |
2 files changed, 6 insertions, 8 deletions
diff --git a/compiler/rustc_target/src/abi/mod.rs b/compiler/rustc_target/src/abi/mod.rs index b744d5ad4ed..9f26c98df86 100644 --- a/compiler/rustc_target/src/abi/mod.rs +++ b/compiler/rustc_target/src/abi/mod.rs @@ -6,19 +6,11 @@ use Primitive::*; use rustc_data_structures::intern::Interned; use rustc_macros::HashStable_Generic; -use crate::json::{Json, ToJson}; - pub mod call; // Explicitly import `Float` to avoid ambiguity with `Primitive::Float`. pub use rustc_abi::{Float, *}; -impl ToJson for Endian { - fn to_json(&self) -> Json { - self.as_str().to_json() - } -} - rustc_index::newtype_index! { /// The *source-order* index of a field in a variant. /// diff --git a/compiler/rustc_target/src/json.rs b/compiler/rustc_target/src/json.rs index 2c367defe7b..b09d8d724ef 100644 --- a/compiler/rustc_target/src/json.rs +++ b/compiler/rustc_target/src/json.rs @@ -134,3 +134,9 @@ impl ToJson for TargetMetadata { }) } } + +impl ToJson for rustc_abi::Endian { + fn to_json(&self) -> Json { + self.as_str().to_json() + } +} |
