-
-
Notifications
You must be signed in to change notification settings - Fork 669
Speedup tokenizer & parser #2161
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Closed
Closed
Changes from all commits
Commits
Show all changes
134 commits
Select commit
Hold shift + click to select a range
60f14a8
init
MaxGraey bd5ef03
advance pos for readInteger
MaxGraey 3072664
fix
MaxGraey fcb4200
comments
MaxGraey 26ab535
better
MaxGraey 72a6203
Guarantee skip upper cased tokens as keywords
MaxGraey 4c4c4c9
add keyword length limit
MaxGraey 6159cd8
better
MaxGraey 35fb736
revert
MaxGraey 182eb41
improve token skip
MaxGraey 1b91de3
add isKeyword helper
MaxGraey 1c22bc5
refactor
MaxGraey 207b7d9
add skipKeyword
MaxGraey 7c1fa02
clean
MaxGraey 133892b
allow "of" as identifier
MaxGraey 7cfb3a3
fix
MaxGraey b12bb19
better
MaxGraey 6721afc
use const enums
MaxGraey 43be895
improve ts emit
MaxGraey c8ed972
fix
MaxGraey 4dcbce4
Merge branch 'main' into speedup-tokenizer
MaxGraey 0729ee3
refactor
MaxGraey 52e5b56
Merge branch 'main' into speedup-tokenizer
MaxGraey ad65d6a
add MIN_KEYWORD_LENGTH
MaxGraey 4dbebdb
more
MaxGraey dc19d6e
simplify tokenFromKeyword
MaxGraey 2e1d68a
disable preserveConstEnums
MaxGraey 37610b2
refactor compilerOptions
MaxGraey 42e674d
improve line break for single comments
MaxGraey 2637ffc
add TODO
MaxGraey 79480c4
refactor
MaxGraey 1d2f631
add comment
MaxGraey aef8da8
add TODO
MaxGraey 5d861b6
handle ||= and &&=
MaxGraey 27b2259
refactor
MaxGraey 39937b2
typo
MaxGraey 9d77b36
better
MaxGraey dae3462
refactor
MaxGraey 4a4b8f4
add ?? and ??= for tokenizer
MaxGraey 2554518
Merge branch 'main' into speedup-tokenizer
MaxGraey 3ee3dac
Merge branch 'main' into speedup-tokenizer
MaxGraey c1a267c
refactor range
MaxGraey 3f34f97
Merge branch 'main' into speedup-tokenizer
MaxGraey 3ca80dd
Merge branch 'main' into speedup-tokenizer
MaxGraey d9e08a7
better probeKeywordToken
MaxGraey d12d5ff
faster isIllegalVariableIdentifier
MaxGraey ab3b858
better readHexInteger
MaxGraey bc4ec02
better
MaxGraey e4986e3
better octal
MaxGraey b57e5c6
optimize read hex, octal and binary by skipping seq zeros
MaxGraey 5d960a9
refactor
MaxGraey 9d5d0ff
more
MaxGraey 3df8ce8
add fast pathes for readDecimalFloat
MaxGraey 92dd92a
simplify readDecimalFloatPartial
MaxGraey d693f7b
refactor
MaxGraey 1f80377
more
MaxGraey f7d3a90
better
MaxGraey ee8dba9
add await operator for operatorTokenToString
MaxGraey 82ae5c8
refactor
MaxGraey e2e86ca
refactor readInteger
MaxGraey 4399ab7
refactor
MaxGraey 0cba78a
better
MaxGraey 1e9ea69
refactor
MaxGraey 51e9197
again
MaxGraey 87557ee
ENDOFFILE => EOF
MaxGraey f326524
simplify parseExpression
MaxGraey 43b41b0
add comment for parse new operator
MaxGraey e38fe0d
more
MaxGraey f4179f3
add regexp case for parser's skipStatement
MaxGraey 33617ce
more
MaxGraey 7db95f8
add ||=, &&=, ??= and ?? for determinePrecedence
MaxGraey 34c8f9e
refactor determinePrecedence
MaxGraey 8d1e2c8
refactor
MaxGraey 343c161
refactor
MaxGraey 651cf1f
Merge branch 'main' into speedup-tokenizer
MaxGraey 5b97b00
refactor
MaxGraey 396dd23
better
MaxGraey d0921a0
add tests
MaxGraey 264d7d2
simplify isIllegalVariableIdentifier
MaxGraey 23632a6
comment
MaxGraey 6f3cb12
simplify
MaxGraey 79c2a86
better
MaxGraey efcadb6
simplify
MaxGraey 8d8251e
refactor
MaxGraey 437ce5a
refactor configs
MaxGraey 1c5f75d
Merge branch 'main' into speedup-tokenizer
MaxGraey 163ec99
refactor peek
MaxGraey 6d43043
opt readIdentifier
MaxGraey 590181f
simplify comment
MaxGraey d95b5d5
more
MaxGraey 3840256
use index intead charAt
MaxGraey cd6a125
Merge branch 'main' into speedup-tokenizer
MaxGraey bb7ec82
revert some changes in test after resolve conflicts
MaxGraey ced5015
refactor
MaxGraey c61f41b
remove preserveCostEnum
MaxGraey eec4d88
add lookup token table
MaxGraey 3d0daa9
use this table for speedup & simplify tokenization
MaxGraey bf8c66d
refactor
MaxGraey 233a013
rearrange
MaxGraey 60a3d36
Merge branch 'main' into speedup-tokenizer
MaxGraey af33cd5
simplify
MaxGraey a13414a
more
MaxGraey e06fa9e
refactor
MaxGraey 057840e
simplify
MaxGraey 02250c9
refactor
MaxGraey cb32321
fix
MaxGraey 33bcf1f
simplify integerOrFloatToken
MaxGraey 6bee4dc
refactor
MaxGraey 273dc43
refactor. Simplify names
MaxGraey 114ac1e
refactor
MaxGraey 25991a8
refactor skipLineComment
MaxGraey e1de806
refactor skipBlockComment
MaxGraey 1e52754
let -> var
MaxGraey f3f309e
refactor scanKeyword
MaxGraey 2a18ccc
refactor scanKeyword
MaxGraey 23d6ad8
simplify
MaxGraey 9fab45e
fix
MaxGraey d25c23b
refactor
MaxGraey 2443123
remove assert in scanKeyword
MaxGraey 745e615
refactor
MaxGraey 02b02f3
more
MaxGraey 1260341
more
MaxGraey abc9d12
refactor
MaxGraey 009e7c0
refactor
MaxGraey 8b5c101
better
MaxGraey c86dd79
fix
MaxGraey 56cd089
better
MaxGraey de390ac
refactor
MaxGraey ec0e9b8
add COMMENT_OR_OPERATOR pseudo token
MaxGraey f6cb7e3
move Range to diagnostics
MaxGraey f7a74f0
refactor comment
MaxGraey e9603bb
unchecked
MaxGraey f131f29
refactoring
MaxGraey ab507d5
MAYBE_KEYWORD -> IDENTIFIER_OR_KEYWORD
MaxGraey File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.