Skip to content
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

help wanted: audit/improve CS-matching function #20

Open
nylki opened this issue Jun 28, 2018 · 0 comments
Open

help wanted: audit/improve CS-matching function #20

nylki opened this issue Jun 28, 2018 · 0 comments

Comments

@nylki
Copy link
Owner

nylki commented Jun 28, 2018

Although the library performs properly in all cases I tested previously, I am not 100% sure wether the matching algorithm for context sensitive productions @ https://github.com/nylki/lindenmayer/blob/master/lindenmayer.js#L314 works as expected and as defined in "The Algorithmic Beauty of Plants".

If you have experience with (context-sensitive) pattern matching, and branching syntax, I'd very much appreciate if you could take a look at the match() function and see if it performs as expected or even improve performance. I positive that the algorithm could be improved upon.

I am especially unsure whether the algorithm performs properly in complex branching situation. Simple regex does not work here unfortunately, because of branching situations.

There are several tests that can be run via npm test that should pass, but new, more comprehensive tests would probably be a good idea too. It is also not excluded that some tests might be flawed, taking a look there might be a good idea too.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant