Skip to content

Commit

Permalink
refactor(ast): remove excess line breaks from generated code (#8830)
Browse files Browse the repository at this point in the history
Pure refactor. Just remove excess line breaks.
  • Loading branch information
overlookmotel committed Feb 1, 2025
1 parent 30eec26 commit 0568210
Show file tree
Hide file tree
Showing 10 changed files with 2 additions and 26 deletions.
4 changes: 0 additions & 4 deletions crates/oxc_ast/src/generated/derive_clone_in.rs
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,9 @@
use oxc_allocator::{Allocator, CloneIn};

use crate::ast::comment::*;

use crate::ast::js::*;

use crate::ast::jsx::*;

use crate::ast::literal::*;

use crate::ast::ts::*;

impl<'alloc> CloneIn<'alloc> for BooleanLiteral {
Expand Down
4 changes: 0 additions & 4 deletions crates/oxc_ast/src/generated/derive_content_eq.rs
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,9 @@
use oxc_span::cmp::ContentEq;

use crate::ast::comment::*;

use crate::ast::js::*;

use crate::ast::jsx::*;

use crate::ast::literal::*;

use crate::ast::ts::*;

impl ContentEq for BooleanLiteral {
Expand Down
3 changes: 0 additions & 3 deletions crates/oxc_ast/src/generated/derive_estree.rs
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,8 @@
use serde::{ser::SerializeMap, Serialize, Serializer};

use crate::ast::js::*;

use crate::ast::jsx::*;

use crate::ast::literal::*;

use crate::ast::ts::*;

impl Serialize for BooleanLiteral {
Expand Down
2 changes: 0 additions & 2 deletions crates/oxc_ast/src/generated/derive_get_address.rs
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,7 @@
use oxc_allocator::{Address, GetAddress};

use crate::ast::js::*;

use crate::ast::jsx::*;

use crate::ast::ts::*;

impl GetAddress for Expression<'_> {
Expand Down
3 changes: 0 additions & 3 deletions crates/oxc_ast/src/generated/derive_get_span.rs
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,8 @@
use oxc_span::{GetSpan, Span};

use crate::ast::js::*;

use crate::ast::jsx::*;

use crate::ast::literal::*;

use crate::ast::ts::*;

impl GetSpan for BooleanLiteral {
Expand Down
3 changes: 0 additions & 3 deletions crates/oxc_ast/src/generated/derive_get_span_mut.rs
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,8 @@
use oxc_span::{GetSpanMut, Span};

use crate::ast::js::*;

use crate::ast::jsx::*;

use crate::ast::literal::*;

use crate::ast::ts::*;

impl GetSpanMut for BooleanLiteral {
Expand Down
1 change: 0 additions & 1 deletion crates/oxc_span/src/generated/derive_estree.rs
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@
use serde::{ser::SerializeMap, Serialize, Serializer};

use crate::source_type::*;

use crate::span::types::*;

impl Serialize for Span {
Expand Down
1 change: 0 additions & 1 deletion crates/oxc_syntax/src/generated/derive_clone_in.rs
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@
use oxc_allocator::{Allocator, CloneIn};

use crate::number::*;

use crate::operator::*;

impl<'alloc> CloneIn<'alloc> for NumberBase {
Expand Down
1 change: 0 additions & 1 deletion crates/oxc_syntax/src/generated/derive_content_eq.rs
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@
use oxc_span::cmp::ContentEq;

use crate::number::*;

use crate::operator::*;

impl ContentEq for NumberBase {
Expand Down
6 changes: 2 additions & 4 deletions tasks/ast_tools/src/derives/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -52,15 +52,13 @@ pub trait Derive {
.chain(["*"])
.join("::");
let use_module: ItemUse = parse_str(format!("use {local_path};").as_str()).unwrap();
quote! {
///@@line_break
#use_module
}
quote!( #use_module )
});

quote! {
#prelude

///@@line_break
#(#use_modules)*

///@@line_break
Expand Down

0 comments on commit 0568210

Please sign in to comment.