mirror of
https://github.com/danbulant/oxc
synced 2026-05-23 06:08:47 +00:00
refactor(ast_codegen): consistent import order (#4761)
Pure refactor. Alter import order in generated code to consistent order - `std`, external crates, `crate`, `super`.
This commit is contained in:
parent
41f861fd15
commit
2dea0caae0
4 changed files with 8 additions and 5 deletions
|
|
@ -3,10 +3,11 @@
|
||||||
|
|
||||||
use std::mem::{align_of, offset_of, size_of};
|
use std::mem::{align_of, offset_of, size_of};
|
||||||
|
|
||||||
use crate::ast::*;
|
|
||||||
use oxc_span::*;
|
use oxc_span::*;
|
||||||
use oxc_syntax::{number::*, operator::*};
|
use oxc_syntax::{number::*, operator::*};
|
||||||
|
|
||||||
|
use crate::ast::*;
|
||||||
|
|
||||||
#[cfg(target_pointer_width = "64")]
|
#[cfg(target_pointer_width = "64")]
|
||||||
const _: () = {
|
const _: () = {
|
||||||
assert!(size_of::<BooleanLiteral>() == 12usize);
|
assert!(size_of::<BooleanLiteral>() == 12usize);
|
||||||
|
|
|
||||||
|
|
@ -1,9 +1,10 @@
|
||||||
// Auto-generated code, DO NOT EDIT DIRECTLY!
|
// Auto-generated code, DO NOT EDIT DIRECTLY!
|
||||||
// To edit this generated file you have to edit `tasks/ast_codegen/src/generators/ast_kind.rs`
|
// To edit this generated file you have to edit `tasks/ast_codegen/src/generators/ast_kind.rs`
|
||||||
|
|
||||||
use crate::ast::*;
|
|
||||||
use oxc_span::{GetSpan, Span};
|
use oxc_span::{GetSpan, Span};
|
||||||
|
|
||||||
|
use crate::ast::*;
|
||||||
|
|
||||||
#[derive(Debug, Clone, Copy)]
|
#[derive(Debug, Clone, Copy)]
|
||||||
pub enum AstType {
|
pub enum AstType {
|
||||||
BooleanLiteral,
|
BooleanLiteral,
|
||||||
|
|
|
||||||
|
|
@ -41,11 +41,11 @@ impl Generator for AssertLayouts {
|
||||||
|
|
||||||
endl!();
|
endl!();
|
||||||
|
|
||||||
use crate::ast::*;
|
|
||||||
use oxc_span::*;
|
use oxc_span::*;
|
||||||
use oxc_syntax::{number::*, operator::*};
|
use oxc_syntax::{number::*, operator::*};
|
||||||
|
endl!();
|
||||||
|
|
||||||
|
use crate::ast::*;
|
||||||
endl!();
|
endl!();
|
||||||
|
|
||||||
#[cfg(target_pointer_width = "64")]
|
#[cfg(target_pointer_width = "64")]
|
||||||
|
|
|
||||||
|
|
@ -170,9 +170,10 @@ impl Generator for AstKindGenerator {
|
||||||
quote! {
|
quote! {
|
||||||
#header
|
#header
|
||||||
|
|
||||||
use crate::ast::*;
|
|
||||||
use oxc_span::{GetSpan, Span};
|
use oxc_span::{GetSpan, Span};
|
||||||
|
endl!();
|
||||||
|
|
||||||
|
use crate::ast::*;
|
||||||
endl!();
|
endl!();
|
||||||
|
|
||||||
#[derive(Debug, Clone, Copy)]
|
#[derive(Debug, Clone, Copy)]
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue