You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The first initialization and/or running of a parser instance may be very slow.
This only happens on the first initialization or parsing due to a very ineffective algorithm
used to compute the lookahead functions.
This only happens with some grammars:
Temporary Workaround for 99% of use cases:
Pass a smaller than the default (5) maxLookahead in the parser's constructor:
function CssParser(input) {
chevrotain.Parser.call(this, input, cssTokens, {
maxLookahead : 3 // by default this is 5
});
...
The text was updated successfully, but these errors were encountered:
…of DFS.
This avoids performance issues with the initialization of some parsers
As alot of unnesscary work was done which was determined by the configured maxLookahead
instead of the actual lookahead required for the specific grammar.
Thanks to @levin81 for algorithmic assistance.
Fixes#243
…of DFS.
This avoids performance issues with the initialization of some parsers
As alot of unnesscary work was done which was determined by the configured maxLookahead
instead of the actual lookahead required for the specific grammar.
Thanks to @levin81 for algorithmic assistance.
Fixes#243
…of DFS.
This avoids performance issues with the initialization of some parsers
As alot of unnesscary work was done which was determined by the configured maxLookahead
instead of the actual lookahead required for the specific grammar.
Thanks to @levin81 for algorithmic assistance.
Fixes#243
The Problem:
The first initialization and/or running of a parser instance may be very slow.
This only happens on the first initialization or parsing due to a very ineffective algorithm
used to compute the lookahead functions.
This only happens with some grammars:
Temporary Workaround for 99% of use cases:
Pass a smaller than the default (5) maxLookahead in the parser's constructor:
The text was updated successfully, but these errors were encountered: