Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
71 commits
Select commit Hold shift + click to select a range
0d4e5cb
chore: fork initialization
Zamralik Jan 15, 2026
36ad869
chore: change extensions from .ts to .mts
Zamralik Jan 15, 2026
c1e5039
chore: convert indentation to tabs
Zamralik Jan 15, 2026
7934895
fix: various errors
Zamralik Jan 15, 2026
d6d9ee4
fix: various errors
Zamralik Jan 20, 2026
6199e9d
feat: asynchronous bindings
Zamralik Jan 20, 2026
610b17b
chore: Added CI skeleton.
SmashingQuasar Jan 20, 2026
52c0cb0
chore: update eslint rules
Zamralik Jan 21, 2026
f291f4d
fix: replace 'const enum' to work as dependency and fix exports
Zamralik Jan 22, 2026
b6d5add
chore: Removed a broken line in pipeline.
SmashingQuasar Jan 23, 2026
dced13b
chore: Made publication manual.
SmashingQuasar Jan 23, 2026
ef375c7
chore: Added temporary publication.
SmashingQuasar Jan 23, 2026
e222203
chore: Changed package name to adequate name.
SmashingQuasar Jan 23, 2026
30bc599
chore: Version 0.1.1.
SmashingQuasar Jan 23, 2026
59cb833
chore: Added missing exports.
SmashingQuasar Jan 23, 2026
a525776
chore: fix eslint errors
Zamralik Jan 31, 2026
f9dc478
fix: Moved ValueKind to its own file and renamed it ValueKindEnum.
SmashingQuasar Jan 31, 2026
6132300
fix: Moved ExpressionKind to its own file and renamed it ExpressionKi…
SmashingQuasar Jan 31, 2026
220a7fa
fix: Moved StatementKind to its own file and renamed it StatementKind…
SmashingQuasar Jan 31, 2026
0c88c3d
fix: Moved OpCode to its own file and renamed it OpCodeEnum.
SmashingQuasar Jan 31, 2026
e9cba40
fix: Moved State to its file and renamed it StateEnum.
SmashingQuasar Jan 31, 2026
889e507
fix: Moved TokenKind to its own file and renamed it TokenKindEnum.
SmashingQuasar Jan 31, 2026
922285a
fix: Refactored opcode.mjs in multiple files.
SmashingQuasar Jan 31, 2026
4267637
fix: Moved LuaFunction to its own file and renamed it LuaFunctionInte…
SmashingQuasar Jan 31, 2026
5672cb9
fix: Moved Value to its own file and renamed it ValueInterface.
SmashingQuasar Jan 31, 2026
e9e7fbb
fix: Moved Expression to its own file and renamed it ExpressionInterf…
SmashingQuasar Jan 31, 2026
5439b02
fix: Moved Assignment to its own file and renamed it AssignmentInterf…
SmashingQuasar Jan 31, 2026
89b277f
fix: Moved Local to its own file and renamed it LocalInterface.
SmashingQuasar Jan 31, 2026
a4fc6e5
fix: Moved ElseIfBlock to its own file and renamed it ElseIfBlockInte…
SmashingQuasar Jan 31, 2026
de4b7ce
fix: Moved IfBlock to its own file and renamed it IfBlockInterface.
SmashingQuasar Jan 31, 2026
c70a5b2
fix: Moved While to its own file and renamed it WhileInterface.
SmashingQuasar Jan 31, 2026
4542186
fix: Moved For to its own file and renamed it ForInterface.
SmashingQuasar Jan 31, 2026
ded0dba
fix: Moved NumericFor to its own file and renamed it NumericForInterf…
SmashingQuasar Jan 31, 2026
f48c39b
fix: Moved Repeat to its own file and renamed it RepeatInterface.
SmashingQuasar Jan 31, 2026
22c039c
fix: Moved Do to its own file and renamed it DoInterface.
SmashingQuasar Jan 31, 2026
866f77f
fix: Moved Return to its own file and renamed it ReturnInterface.
SmashingQuasar Jan 31, 2026
9b62c8e
fix: Moved Statement to its own file and renamed it StatementInterface.
SmashingQuasar Jan 31, 2026
caf7082
fix: Moved Chunk to its own file and renamed it ChunkInterface.
SmashingQuasar Jan 31, 2026
25ebc91
fix: Deleted ast.mts as it became empty.
SmashingQuasar Jan 31, 2026
3f4039f
fix: Moved index to its own file.
SmashingQuasar Jan 31, 2026
ffe98e7
fix: Moved LuaOptions to its own file and renamed it LuaOptionsInterf…
SmashingQuasar Jan 31, 2026
80cf031
fix: Made Engine class constructor scope explicit.
SmashingQuasar Jan 31, 2026
cac0714
fix: Moved token_kind_to_string to its own file.
SmashingQuasar Jan 31, 2026
3ab62a5
fix: Moved Debug to its own file and renamed it DebugInterface.
SmashingQuasar Jan 31, 2026
14b061d
fix: Moved Token to its own file and renamed it TokenInterface.
SmashingQuasar Jan 31, 2026
4978cf2
fix: Made TokenStream class constructor scope explicit.
SmashingQuasar Jan 31, 2026
fbf102f
fix: Moved table_size to its own file.
SmashingQuasar Jan 31, 2026
c10f87b
fix: Moved variable_to_string to its own file.
SmashingQuasar Jan 31, 2026
60caf68
fix: Moved print to its own file.
SmashingQuasar Jan 31, 2026
51c98c3
fix: Moved type to its own file.
SmashingQuasar Jan 31, 2026
ca43a87
fix: Moved make_boolean to its own file.
SmashingQuasar Jan 31, 2026
53a1d6e
fix: Moved make_number to its own file.
SmashingQuasar Jan 31, 2026
a4aa20e
fix: Moved make_string to its own file.
SmashingQuasar Jan 31, 2026
c67b545
fix: Moved handle_error to its own file and slightly improve its syntax.
SmashingQuasar Jan 31, 2026
be97803
fix: Moved error to its own file and renamed it to-error to avoid sha…
SmashingQuasar Jan 31, 2026
9897cae
fix: Moved expect to its own file.
SmashingQuasar Jan 31, 2026
aacbb07
fix: Moved consume to its own file.
SmashingQuasar Jan 31, 2026
3ec0f1d
fix: Moved unary_type_to_expression_kind to its own file.
SmashingQuasar Jan 31, 2026
858ee53
fix: Moved parse to its own file.
SmashingQuasar Jan 31, 2026
0a01721
fix: Moved parse_statement to its own file.
SmashingQuasar Jan 31, 2026
b2eef4f
fix: Moved parse_function_params to its own file.
SmashingQuasar Jan 31, 2026
11cae4d
fix: Moved operation_type_to_expression_kind to its own file.
SmashingQuasar Jan 31, 2026
762d4a2
fix: Moved parse_local_statement to its own file.
SmashingQuasar Jan 31, 2026
5a29a96
fix: Moved parse_break to its own file.
SmashingQuasar Jan 31, 2026
5403719
fix: Resolved a wrong syntax call on debug options.
SmashingQuasar Feb 1, 2026
a83eff6
fix: convert remaining enums + fix TS errors
Zamralik Feb 1, 2026
3904b7a
fix: Moved single_token_map to its own file and made it a function.
SmashingQuasar Feb 1, 2026
16c38a9
fix: Moved double_token_map to its own file and made it a function.
SmashingQuasar Feb 1, 2026
257064d
fix: Moved keyword_map to its own file and made it a function.
SmashingQuasar Feb 1, 2026
bad75b8
fix: Moved UNARY to its own file and made it a guard.
SmashingQuasar Feb 1, 2026
a1635f2
fix: Moved ORDERS to its own file and made it a function.
SmashingQuasar Feb 1, 2026
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
19 changes: 19 additions & 0 deletions .eslint/configuration/_index.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
import { configuration as disabled_configuration } from "./disabled/config.mjs";
import { configuration as default_configuration } from "./global/default.mjs";
import { configuration as ignores_configuration } from "./global/ignores.mjs";
import { configuration as strict_configuration } from "./strict/config.mjs";
import { configuration as style_configuration } from "./style/config.mjs";
import { configuration as test_configuration } from "./test/config.mjs";
import { configurations as file_specific_configurations } from "./file-specific/config.mjs";

const CONFIGURATIONS = [
disabled_configuration,
default_configuration,
ignores_configuration,
strict_configuration,
style_configuration,
test_configuration,
...file_specific_configurations,
];

export { CONFIGURATIONS as configurations };
12 changes: 12 additions & 0 deletions .eslint/configuration/disabled/config.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
import { rules } from "./rules.mjs";

const CONFIGURATION = {
name: "disabled",
files: [
".disabled",
],
ignores: [],
rules: rules,
};

export { CONFIGURATION as configuration };
258 changes: 258 additions & 0 deletions .eslint/configuration/disabled/rules.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,258 @@
/*
* List disabled rules to help with configuration inspection
* It's easier to see the new rules in the unused rules list
**/
const RULES = {
// Buggy rule
"@style/indent": "off",
// Buggy rule
"@style/indent-binary-ops": "off",
// We don't do JSX
"@style/jsx-child-element-spacing": "off",
// We don't do JSX
"@style/jsx-closing-bracket-location": "off",
// We don't do JSX
"@style/jsx-closing-tag-location": "off",
// We don't do JSX
"@style/jsx-curly-brace-presence": "off",
// We don't do JSX
"@style/jsx-curly-newline": "off",
// We don't do JSX
"@style/jsx-curly-spacing": "off",
// We don't do JSX
"@style/jsx-equals-spacing": "off",
// We don't do JSX
"@style/jsx-first-prop-new-line": "off",
// We don't do JSX
"@style/jsx-function-call-newline": "off",
// We don't do JSX
"@style/jsx-indent-props": "off",
// We don't do JSX
"@style/jsx-max-props-per-line": "off",
// We don't do JSX
"@style/jsx-newline": "off",
// We don't do JSX
"@style/jsx-one-expression-per-line": "off",
// We don't do JSX
"@style/jsx-pascal-case": "off",
// We don't do JSX
"@style/jsx-props-no-multi-spaces": "off",
// We don't do JSX
"@style/jsx-self-closing-comp": "off",
// We don't do JSX
"@style/jsx-sort-props": "off",
// We don't do JSX
"@style/jsx-tag-spacing": "off",
// We don't do JSX
"@style/jsx-wrap-multilines": "off",
// We don't do JSX
"@style/wrap-regex": "off",
// Free choice
"@style/lines-around-comment": "off",
// Case by case
"@style/multiline-comment-style": "off",
// The @ts/typedef rule make this rule obsolete
"@style/no-confusing-arrow": "off",
// Shouldn't be an issue with TypeScript
"@style/no-mixed-operators": "off",
// The curly rule make this rule obsolete
"@style/nonblock-statement-body-position": "off",
// The one-var rule make this rule obsolete
"@style/one-var-declaration-per-line": "off",
// The @style/comma-spacing rule make this rule obsolete
"@style/type-generic-spacing": "off",
// TypeScript prevent such confusion
"@style/wrap-regexp": "off",
// Handled by TypeScript option noImplicitReturns
"@ts/consistent-return": "off",
// Not formally defined
"@ts/naming-convention": "off",
// Handled by TypeScript
"@ts/no-dupe-class-members": "off",
// Incompatible with the @ts/typedef rule
"@ts/no-inferrable-types": "off",
// Handled by TypeScript option noImplicitThis
"@ts/no-invalid-this": "off",
// Mixed enums are good for holding configuration values
"@ts/no-mixed-enums": "off",
// Handled by TypeScript
"@ts/no-redeclare": "off",
// It was not necessary so far
"@ts/no-restricted-imports": "off",
// Not needed so far
"@ts/no-restricted-types": "off",
// The @ts/parameter-properties rule make this rule obsolete
"@ts/no-unnecessary-parameter-property-assignment": "off",
// Explicit qualifiers improve readability
"@ts/no-unnecessary-qualifier": "off",
// Being explicit is never bad
"@ts/no-unnecessary-type-arguments": "off",
// Being explicit is never bad
"@ts/no-unnecessary-type-parameters": "off",
// Enum comparison is necessary for comparing values with magic numbers or string constants
"@ts/no-unsafe-enum-comparison": "off",
// Type assertions are forbidden
"@ts/no-unsafe-type-assertion": "off",
// Traditional type assertion is more explicit
"@ts/non-nullable-type-assertion-style": "off",
// Destructuring is not always the best choice
"@ts/prefer-destructuring": "off",
// The @ts/no-namespace rule make this rule obsolete
"@ts/prefer-namespace-keyword": "off",
// Conflict with the no-param-reassign rule props option
"@ts/prefer-readonly-parameter-types": "off",
// The type is often implied by the callable return type
"@ts/prefer-reduce-type-parameter": "off",
// Distinct signatures can improve readability
"@ts/unified-signatures": "off",
// The no-var rule make this rule obsolete
"block-scoped-var": "off",
// Conflict with some dependencies and APIs
"camelcase": "off",
// Some comments may need to begin with a lowercase
"capitalized-comments": "off",
// Redefined as @ts/class-methods-use-this
"class-methods-use-this": "off",
// Redefined as @ts/consistent-return
"consistent-return": "off",
// The prefer-arrow-callback rule make this rule obsolete
"consistent-this": "off",
// Handled by TypeScript
"constructor-super": "off",
// Conflict with @ts/switch-exhaustiveness-check option allowDefaultCaseForExhaustiveSwitch
"default-case": "off",
// Redefined as @ts/default-param-last
"default-param-last": "off",
// Redefined as @ts/dot-notation
"dot-notation": "off",
// The prefer-arrow-callback rule make this rule obsolete
"func-name-matching": "off",
// Handled by TypeScript
"getter-return": "off",
// Handled by TypeScript
"guard-for-in": "off",
// The rules id-denylist and id-length make this rule obsolete
"id-match": "off",
// Redefined as @ts/init-declarations
"init-declarations": "off",
// Redefined as @ts/max-params
"max-params": "off",
// All variables follow the same naming convention
"new-cap": "off",
// The rule is only for a browser environment
"no-alert": "off",
// Redefined as @ts/no-array-constructor
"no-array-constructor": "off",
// It is not always desirable to perform multiple asynchronous operations in parallel
"no-await-in-loop": "off",
// Bitwise operations are useful in some cases
"no-bitwise": "off",
// Handled by TypeScript
"no-const-assign": "off",
// Early interruption improve readability
"no-continue": "off",
// Using ASCII or unicode code points in RegExp patterns is not bad
"no-control-regex": "off",
// TypeScript prevent such confusion
"no-div-regex": "off",
// Handled by TypeScript
"no-dupe-args": "off",
// Redefined as @ts/no-dupe-class-members
"no-dupe-class-members": "off",
// Handled by TypeScript
"no-dupe-keys": "off",
// Redefined as @ts/no-empty-function
"no-empty-function": "off",
// The eqeqeq rule make this rule obsolete
"no-eq-null": "off",
// The no-labels rule make this rule obsolete
"no-extra-label": "off",
// Handled by TypeScript
"no-func-assign": "off",
// Doesn't apply to modules
"no-implicit-globals": "off",
// Redefined as @ts/no-implied-eval
"no-implied-eval": "off",
// Handled by TypeScript
"no-import-assign": "off",
// Inline comments may improve readability in some cases
"no-inline-comments": "off",
// Not an issue in modules and strict mode
"no-inner-declarations": "off",
// Redefined as @ts/no-invalid-this
"no-invalid-this": "off",
// The no-labels rule make this rule obsolete
"no-label-var": "off",
// Not an issue in modules and strict mode
"no-lone-blocks": "off",
// Redefined as @ts/no-loop-func
"no-loop-func": "off",
// Redefined as @ts/no-magic-numbers
"no-magic-numbers": "off",
// Handled by TypeScript
"no-obj-calls": "off",
// Increment and decrement operators are good
"no-plusplus": "off",
// Redefined as @ts/no-redeclare
"no-redeclare": "off",
// The rules id-denylist and id-length are enough so far
"no-restricted-exports": "off",
// Not needed so far
"no-restricted-globals": "off",
// Redefined as @ts/no-restricted-imports
"no-restricted-imports": "off",
// Handled by TypeScript
"no-setter-return": "off",
// Redefined as @ts/no-shadow
"no-shadow": "off",
// Ternary can be useful in some cases
"no-ternary": "off",
// Handled by TypeScript
"no-this-before-super": "off",
// Redefined as @ts/only-throw-error
"no-throw-literal": "off",
// Handled by TypeScript
"no-undef": "off",
// Incompatible with @ts/init-declarations
"no-undef-init": "off",
// The no-shadow-restricted-names rule make this rule obsolete
"no-undefined": "off",
// Handled by TypeScript
"no-unreachable": "off",
// Handled by TypeScript
"no-unsafe-negation": "off",
// Redefined as @ts/no-unused-expressions
"no-unused-expressions": "off",
// The no-labels rule make this rule obsolete
"no-unused-labels": "off",
// Redefined as @ts/no-unused-vars
"no-unused-vars": "off",
// Redefined as @ts/no-use-before-define
"no-use-before-define": "off",
// Incompatible with @ts/init-declarations
"no-useless-assignment": "off",
// Redefined as @ts/no-useless-constructor
"no-useless-constructor": "off",
// Redefined as @ts/prefer-destructuring
"prefer-destructuring": "off",
// Math.pow() can improve readability
"prefer-exponentiation-operator": "off",
// Redefined as @ts/prefer-promise-reject-errors
"prefer-promise-reject-errors": "off",
// Redefined as @ts/require-await
"require-await": "off",
// Simple RegExp do not need the unicode flag
"require-unicode-regexp": "off",
// Grouping keys logically improve readability
"sort-keys": "off",
// The one-var rule make this rule obsolete
"sort-vars": "off",
// Handled by TypeScript
"use-isnan": "off",
// Handled by TypeScript
"valid-typeof": "off",
// The no-var rule make this rule obsolete
"vars-on-top": "off",
};

export { RULES as rules };
14 changes: 14 additions & 0 deletions .eslint/configuration/file-specific/config.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
import { rules } from "./rules.mjs";

const CONFIGURATIONS = [
{
name: "ts-consistent-type-exports",
files: [
"**/_index.mts",
],
ignores: [],
rules: rules,
}
];

export { CONFIGURATIONS as configurations };
10 changes: 10 additions & 0 deletions .eslint/configuration/file-specific/rules.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
/*
* List disabled rules to help with configuration inspection
* It's easier to see the new rules in the unused rules list
**/
const RULES = {
// Currently buggy for files purely exporting types.
"@ts/consistent-type-exports": "off",
};

export { RULES as rules };
27 changes: 27 additions & 0 deletions .eslint/configuration/global/default.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
import typescript_eslint from "typescript-eslint";
import stylistic from "@stylistic/eslint-plugin";

/* Default configuration with plugins */
const CONFIGURATION = {
name: "default",
languageOptions: {
ecmaVersion: "latest",
sourceType: "module",
globals: {},
parser: typescript_eslint.parser,
parserOptions: {
project: true,
},
},
linterOptions: {
noInlineConfig: false,
reportUnusedDisableDirectives: "warn",
},
plugins: {
"@ts": typescript_eslint.plugin,
"@style": stylistic,
},
settings: {},
};

export { CONFIGURATION as configuration };
19 changes: 19 additions & 0 deletions .eslint/configuration/global/ignores.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
/* Ignored files for all configurations */
const CONFIGURATION = {
ignores: [
"**/*.js",
"**/*.cjs",
"**/*.mjs",
"**/*.d.ts",
"**/*.d.cts",
"**/*.d.mts",
"build",
"reports",
"coverage",
"tmp",
".stryker-tmp",
"**/test.mts"
],
};

export { CONFIGURATION as configuration };
12 changes: 12 additions & 0 deletions .eslint/configuration/strict/config.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
import { rules } from "./rules.mjs";

const CONFIGURATION = {
name: "strict",
files: [
"**/*.mts",
],
ignores: [],
rules: rules,
};

export { CONFIGURATION as configuration };
Loading
Loading