├── .github └── workflows │ └── main.yml ├── .gitignore ├── .vscode └── settings.json ├── CONTRIBUTING.md ├── LICENSE ├── README.md ├── demo ├── demo.css ├── demo.js └── index.html ├── package.json ├── pnpm-lock.yaml ├── pnpm-workspace.yaml ├── src ├── bundle.ts ├── generator │ ├── README.md │ └── generate.ts ├── index.ts ├── optimizer │ ├── README.md │ ├── optimizations.ts │ ├── optimize.ts │ └── transforms │ │ ├── alternation-to-class.ts │ │ ├── expose-anchors.ts │ │ ├── extract-prefix-2.ts │ │ ├── extract-prefix.ts │ │ ├── extract-suffix.ts │ │ ├── merge-ranges.ts │ │ ├── optionalize.ts │ │ ├── prevent-redos.ts │ │ ├── remove-empty-groups.ts │ │ ├── remove-useless-flags.ts │ │ ├── simplify-callouts.ts │ │ ├── unnest-useless-classes.ts │ │ ├── unwrap-negation-wrappers.ts │ │ ├── unwrap-useless-classes.ts │ │ ├── unwrap-useless-groups.ts │ │ ├── use-shorthands.ts │ │ ├── use-unicode-aliases.ts │ │ └── use-unicode-props.ts ├── parser │ ├── README.md │ ├── node-utils.ts │ └── parse.ts ├── tokenizer │ ├── README.md │ └── tokenize.ts ├── traverser │ ├── README.md │ └── traverse.ts ├── unicode.ts └── utils.ts ├── test ├── generator │ ├── gen-named-callout.test.ts │ └── gen-quantifier.test.ts ├── optimizer │ ├── alternation-to-class.test.ts │ ├── expose-anchors.test.ts │ ├── extract-prefix-2.test.ts │ ├── extract-prefix.test.ts │ ├── extract-suffix.test.ts │ ├── merge-ranges.test.ts │ ├── optimizer.test.ts │ ├── optionalize.test.ts │ ├── prevent-redos.test.ts │ ├── remove-empty-groups.test.ts │ ├── remove-useless-flags.test.ts │ ├── simplify-callouts.test.ts │ ├── unnest-useless-classes.test.ts │ ├── unwrap-negation-wrappers.test.ts │ ├── unwrap-useless-classes.test.ts │ ├── unwrap-useless-groups.test.ts │ ├── use-shorthands.test.ts │ ├── use-unicode-aliases.test.ts │ └── use-unicode-props.test.ts ├── parser │ └── parse-quantifier.test.ts ├── root │ └── to-oniguruma-ast.test.ts ├── spec-utils.ts └── traverser │ └── path-methods.test.ts └── tsconfig.json /.github/workflows/main.yml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/.github/workflows/main.yml -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/.gitignore -------------------------------------------------------------------------------- /.vscode/settings.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/.vscode/settings.json -------------------------------------------------------------------------------- /CONTRIBUTING.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/CONTRIBUTING.md -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/LICENSE -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/README.md -------------------------------------------------------------------------------- /demo/demo.css: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/demo/demo.css -------------------------------------------------------------------------------- /demo/demo.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/demo/demo.js -------------------------------------------------------------------------------- /demo/index.html: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/demo/index.html -------------------------------------------------------------------------------- /package.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/package.json -------------------------------------------------------------------------------- /pnpm-lock.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/pnpm-lock.yaml -------------------------------------------------------------------------------- /pnpm-workspace.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/pnpm-workspace.yaml -------------------------------------------------------------------------------- /src/bundle.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/src/bundle.ts -------------------------------------------------------------------------------- /src/generator/README.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/src/generator/README.md -------------------------------------------------------------------------------- /src/generator/generate.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/src/generator/generate.ts -------------------------------------------------------------------------------- /src/index.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/src/index.ts -------------------------------------------------------------------------------- /src/optimizer/README.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/src/optimizer/README.md -------------------------------------------------------------------------------- /src/optimizer/optimizations.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/src/optimizer/optimizations.ts -------------------------------------------------------------------------------- /src/optimizer/optimize.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/src/optimizer/optimize.ts -------------------------------------------------------------------------------- /src/optimizer/transforms/alternation-to-class.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/src/optimizer/transforms/alternation-to-class.ts -------------------------------------------------------------------------------- /src/optimizer/transforms/expose-anchors.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/src/optimizer/transforms/expose-anchors.ts -------------------------------------------------------------------------------- /src/optimizer/transforms/extract-prefix-2.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/src/optimizer/transforms/extract-prefix-2.ts -------------------------------------------------------------------------------- /src/optimizer/transforms/extract-prefix.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/src/optimizer/transforms/extract-prefix.ts -------------------------------------------------------------------------------- /src/optimizer/transforms/extract-suffix.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/src/optimizer/transforms/extract-suffix.ts -------------------------------------------------------------------------------- /src/optimizer/transforms/merge-ranges.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/src/optimizer/transforms/merge-ranges.ts -------------------------------------------------------------------------------- /src/optimizer/transforms/optionalize.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/src/optimizer/transforms/optionalize.ts -------------------------------------------------------------------------------- /src/optimizer/transforms/prevent-redos.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/src/optimizer/transforms/prevent-redos.ts -------------------------------------------------------------------------------- /src/optimizer/transforms/remove-empty-groups.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/src/optimizer/transforms/remove-empty-groups.ts -------------------------------------------------------------------------------- /src/optimizer/transforms/remove-useless-flags.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/src/optimizer/transforms/remove-useless-flags.ts -------------------------------------------------------------------------------- /src/optimizer/transforms/simplify-callouts.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/src/optimizer/transforms/simplify-callouts.ts -------------------------------------------------------------------------------- /src/optimizer/transforms/unnest-useless-classes.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/src/optimizer/transforms/unnest-useless-classes.ts -------------------------------------------------------------------------------- /src/optimizer/transforms/unwrap-negation-wrappers.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/src/optimizer/transforms/unwrap-negation-wrappers.ts -------------------------------------------------------------------------------- /src/optimizer/transforms/unwrap-useless-classes.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/src/optimizer/transforms/unwrap-useless-classes.ts -------------------------------------------------------------------------------- /src/optimizer/transforms/unwrap-useless-groups.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/src/optimizer/transforms/unwrap-useless-groups.ts -------------------------------------------------------------------------------- /src/optimizer/transforms/use-shorthands.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/src/optimizer/transforms/use-shorthands.ts -------------------------------------------------------------------------------- /src/optimizer/transforms/use-unicode-aliases.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/src/optimizer/transforms/use-unicode-aliases.ts -------------------------------------------------------------------------------- /src/optimizer/transforms/use-unicode-props.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/src/optimizer/transforms/use-unicode-props.ts -------------------------------------------------------------------------------- /src/parser/README.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/src/parser/README.md -------------------------------------------------------------------------------- /src/parser/node-utils.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/src/parser/node-utils.ts -------------------------------------------------------------------------------- /src/parser/parse.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/src/parser/parse.ts -------------------------------------------------------------------------------- /src/tokenizer/README.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/src/tokenizer/README.md -------------------------------------------------------------------------------- /src/tokenizer/tokenize.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/src/tokenizer/tokenize.ts -------------------------------------------------------------------------------- /src/traverser/README.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/src/traverser/README.md -------------------------------------------------------------------------------- /src/traverser/traverse.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/src/traverser/traverse.ts -------------------------------------------------------------------------------- /src/unicode.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/src/unicode.ts -------------------------------------------------------------------------------- /src/utils.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/src/utils.ts -------------------------------------------------------------------------------- /test/generator/gen-named-callout.test.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/test/generator/gen-named-callout.test.ts -------------------------------------------------------------------------------- /test/generator/gen-quantifier.test.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/test/generator/gen-quantifier.test.ts -------------------------------------------------------------------------------- /test/optimizer/alternation-to-class.test.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/test/optimizer/alternation-to-class.test.ts -------------------------------------------------------------------------------- /test/optimizer/expose-anchors.test.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/test/optimizer/expose-anchors.test.ts -------------------------------------------------------------------------------- /test/optimizer/extract-prefix-2.test.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/test/optimizer/extract-prefix-2.test.ts -------------------------------------------------------------------------------- /test/optimizer/extract-prefix.test.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/test/optimizer/extract-prefix.test.ts -------------------------------------------------------------------------------- /test/optimizer/extract-suffix.test.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/test/optimizer/extract-suffix.test.ts -------------------------------------------------------------------------------- /test/optimizer/merge-ranges.test.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/test/optimizer/merge-ranges.test.ts -------------------------------------------------------------------------------- /test/optimizer/optimizer.test.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/test/optimizer/optimizer.test.ts -------------------------------------------------------------------------------- /test/optimizer/optionalize.test.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/test/optimizer/optionalize.test.ts -------------------------------------------------------------------------------- /test/optimizer/prevent-redos.test.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/test/optimizer/prevent-redos.test.ts -------------------------------------------------------------------------------- /test/optimizer/remove-empty-groups.test.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/test/optimizer/remove-empty-groups.test.ts -------------------------------------------------------------------------------- /test/optimizer/remove-useless-flags.test.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/test/optimizer/remove-useless-flags.test.ts -------------------------------------------------------------------------------- /test/optimizer/simplify-callouts.test.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/test/optimizer/simplify-callouts.test.ts -------------------------------------------------------------------------------- /test/optimizer/unnest-useless-classes.test.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/test/optimizer/unnest-useless-classes.test.ts -------------------------------------------------------------------------------- /test/optimizer/unwrap-negation-wrappers.test.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/test/optimizer/unwrap-negation-wrappers.test.ts -------------------------------------------------------------------------------- /test/optimizer/unwrap-useless-classes.test.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/test/optimizer/unwrap-useless-classes.test.ts -------------------------------------------------------------------------------- /test/optimizer/unwrap-useless-groups.test.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/test/optimizer/unwrap-useless-groups.test.ts -------------------------------------------------------------------------------- /test/optimizer/use-shorthands.test.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/test/optimizer/use-shorthands.test.ts -------------------------------------------------------------------------------- /test/optimizer/use-unicode-aliases.test.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/test/optimizer/use-unicode-aliases.test.ts -------------------------------------------------------------------------------- /test/optimizer/use-unicode-props.test.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/test/optimizer/use-unicode-props.test.ts -------------------------------------------------------------------------------- /test/parser/parse-quantifier.test.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/test/parser/parse-quantifier.test.ts -------------------------------------------------------------------------------- /test/root/to-oniguruma-ast.test.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/test/root/to-oniguruma-ast.test.ts -------------------------------------------------------------------------------- /test/spec-utils.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/test/spec-utils.ts -------------------------------------------------------------------------------- /test/traverser/path-methods.test.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/test/traverser/path-methods.test.ts -------------------------------------------------------------------------------- /tsconfig.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/slevithan/oniguruma-parser/HEAD/tsconfig.json --------------------------------------------------------------------------------