-
Notifications
You must be signed in to change notification settings - Fork 124
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
Fixes #147 #148
Fixes #147 #148
Conversation
…ere being handling improperly and would not continue to look for additional literals since it wasn't clear that a literal was found. Introduce a flag to indicate that a literal was found, so we know to keep looking for more literals regardless of whether literal has any length or not.
Not sure what that test failure is, it works for me locally:
|
I want to close this pull request, since I no longer think it should be applied. I've been investigating another issue I saw while resolving this issue. It turns out the _iterateIncomingBuffer() method has multiple issues. I am finishing up a complete rewrite which I believe will address #143 and #147. |
That test failure unrelated, it fails sporadically. I think the change looks good as a fix for zero-length literals, but it's great if you have a more readable rewrite that tackles #143 as well. Be aware that _iterateIncomingBuffer was rewritten in 56a951d to be more memory efficient, but the result was a bit cryptic. |
Well, I think my proposal should be similar in its memory efficiency, but hopefully quite a bit more understandable. It took me a while to figure out what _iterateIncomingBuffer() was doing...of course, it didn't help that this was the first time I had ever seen a generator function either. :-) Labor Day weekend here in the USA, so I probably won't create the new pull request until Tuesday or so, but it appears to be working and passing all tests. |
Fixed #147
Not sure if the proposed patch is the best way to do this or it has other ramifications, but it appears to work for me.