Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions crates/oxc_ast/src/ast/js.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1170,8 +1170,8 @@ pub struct VariableDeclaration<'a> {
#[generate_derive(CloneIn, ContentEq, ESTree)]
pub enum VariableDeclarationKind {
Var = 0,
Const = 1,
Let = 2,
Let = 1,
Const = 2,
Using = 3,
#[estree(rename = "await using")]
AwaitUsing = 4,
Expand Down
2 changes: 1 addition & 1 deletion crates/oxc_ast/src/generated/derive_clone_in.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1314,8 +1314,8 @@ impl<'alloc> CloneIn<'alloc> for VariableDeclarationKind {
fn clone_in(&self, _: &'alloc Allocator) -> Self::Cloned {
match self {
Self::Var => VariableDeclarationKind::Var,
Self::Const => VariableDeclarationKind::Const,
Self::Let => VariableDeclarationKind::Let,
Self::Const => VariableDeclarationKind::Const,
Self::Using => VariableDeclarationKind::Using,
Self::AwaitUsing => VariableDeclarationKind::AwaitUsing,
}
Expand Down
2 changes: 1 addition & 1 deletion crates/oxc_ast/src/generated/derive_estree.rs
Original file line number Diff line number Diff line change
Expand Up @@ -913,8 +913,8 @@ impl ESTree for VariableDeclarationKind {
fn serialize<S: Serializer>(&self, serializer: S) {
match self {
Self::Var => JsonSafeString("var").serialize(serializer),
Self::Const => JsonSafeString("const").serialize(serializer),
Self::Let => JsonSafeString("let").serialize(serializer),
Self::Const => JsonSafeString("const").serialize(serializer),
Self::Using => JsonSafeString("using").serialize(serializer),
Self::AwaitUsing => JsonSafeString("await using").serialize(serializer),
}
Expand Down
4 changes: 2 additions & 2 deletions napi/parser/deserialize-js.js
Original file line number Diff line number Diff line change
Expand Up @@ -2919,9 +2919,9 @@ function deserializeVariableDeclarationKind(pos) {
case 0:
return 'var';
case 1:
return 'const';
case 2:
return 'let';
case 2:
return 'const';
case 3:
return 'using';
case 4:
Expand Down
4 changes: 2 additions & 2 deletions napi/parser/deserialize-ts.js
Original file line number Diff line number Diff line change
Expand Up @@ -2974,9 +2974,9 @@ function deserializeVariableDeclarationKind(pos) {
case 0:
return 'var';
case 1:
return 'const';
case 2:
return 'let';
case 2:
return 'const';
case 3:
return 'using';
case 4:
Expand Down
2 changes: 1 addition & 1 deletion npm/oxc-types/types.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -368,7 +368,7 @@ export interface VariableDeclaration extends Span {
declare: boolean;
}

export type VariableDeclarationKind = 'var' | 'const' | 'let' | 'using' | 'await using';
export type VariableDeclarationKind = 'var' | 'let' | 'const' | 'using' | 'await using';

export interface VariableDeclarator extends Span {
type: 'VariableDeclarator';
Expand Down
Loading