Skip to content

Commit

Permalink
Renamed fn_asm_traits.rs to asm_traits.rs and exported it
Browse files Browse the repository at this point in the history
  • Loading branch information
Kixiron committed Dec 6, 2021
1 parent 28e9b13 commit a5c7f62
Show file tree
Hide file tree
Showing 5 changed files with 6 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -453,7 +453,7 @@ static void WriteGenericParameterTypes(FileWriter writer, int count) {
}

void GenerateAsmTraits(TraitGroup[] traitGroups) {
var filename = genTypes.Dirs.GetRustFilename("code_asm", "fn_asm_traits.rs");
var filename = genTypes.Dirs.GetRustFilename("code_asm", "asm_traits.rs");
using (var writer = new FileWriter(TargetLanguage.Rust, FileUtils.OpenWrite(filename))) {
writer.WriteFileHeader();
writer.WriteLine(RustConstants.InnerAttributeAllowNonCamelCaseTypes);
Expand Down Expand Up @@ -565,7 +565,7 @@ void GenerateAsmPub(TraitGroup[] traitGroups) {
var filename = genTypes.Dirs.GetRustFilename("code_asm", "fn_asm_pub.rs");
using (var writer = new FileWriter(TargetLanguage.Rust, FileUtils.OpenWrite(filename))) {
writer.WriteFileHeader();
writer.WriteLine("use crate::code_asm::fn_asm_traits::*;");
writer.WriteLine("use crate::code_asm::asm_traits::*;");
writer.WriteLine($"use crate::code_asm::{CodeAssembler};");
writer.WriteLine($"use crate::{ErrorType};");
writer.WriteLine();
Expand Down Expand Up @@ -696,7 +696,7 @@ void GenerateAsmImpl(TraitGroup[] traitGroups) {
writer.WriteFileHeader();
writer.WriteLine("#![allow(clippy::if_same_then_else)]");
writer.WriteLine();
writer.WriteLine("use crate::code_asm::fn_asm_traits::*;");
writer.WriteLine("use crate::code_asm::asm_traits::*;");
writer.WriteLine("use crate::code_asm::mem::*;");
writer.WriteLine($"use crate::code_asm::op_state::{memoryOperandSizeType.Name(idConverter)};");
writer.WriteLine("use crate::code_asm::reg::*;");
Expand Down
3 changes: 1 addition & 2 deletions src/rust/iced-x86/src/code_asm.rs
Original file line number Diff line number Diff line change
Expand Up @@ -15,18 +15,17 @@
//!
//! [`CodeAssembler`]: struct.CodeAssembler.html

pub mod asm_traits;
mod code_asm_methods;
mod fn_asm_impl;
mod fn_asm_pub;
mod fn_asm_traits;
mod mem;
mod op_state;
mod reg;
pub mod registers;
#[cfg(test)]
mod tests;

pub use crate::code_asm::fn_asm_traits as asm_traits;
pub use crate::code_asm::mem::*;
pub use crate::code_asm::reg::*;
pub use crate::code_asm::registers::*;
Expand Down
2 changes: 1 addition & 1 deletion src/rust/iced-x86/src/code_asm/fn_asm_impl.rs
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

#![allow(clippy::if_same_then_else)]

use crate::code_asm::fn_asm_traits::*;
use crate::code_asm::asm_traits::*;
use crate::code_asm::mem::*;
use crate::code_asm::op_state::MemoryOperandSize;
use crate::code_asm::reg::*;
Expand Down
2 changes: 1 addition & 1 deletion src/rust/iced-x86/src/code_asm/fn_asm_pub.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

// ⚠️This file was generated by GENERATOR!🦹‍♂️

use crate::code_asm::fn_asm_traits::*;
use crate::code_asm::asm_traits::*;
use crate::code_asm::CodeAssembler;
use crate::IcedError;

Expand Down

0 comments on commit a5c7f62

Please sign in to comment.