Skip to content

Commit

Permalink
format
Browse files Browse the repository at this point in the history
  • Loading branch information
dsherret committed Dec 12, 2024
1 parent 46540b2 commit 5781038
Showing 1 changed file with 8 additions and 9 deletions.
17 changes: 8 additions & 9 deletions crates/swc_ecma_parser/src/parser/typescript.rs
Original file line number Diff line number Diff line change
Expand Up @@ -318,15 +318,14 @@ impl<I: Tokens> Parser<I> {

// the "assert" keyword is deprecated and this syntax is niche, so
// don't support it
let with =
if eat!(self, ',') && self.input.syntax().import_attributes() && is!(self, '{') {
match *self.parse_object::<Box<Expr>>()? {
Expr::Object(v) => Some(Box::new(v)),
_ => unreachable!(),
}
} else {
None
};
let with = if eat!(self, ',') && self.input.syntax().import_attributes() && is!(self, '{') {
match *self.parse_object::<Box<Expr>>()? {
Expr::Object(v) => Some(Box::new(v)),
_ => unreachable!(),
}
} else {
None
};

expect!(self, ')');

Expand Down

0 comments on commit 5781038

Please sign in to comment.