Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

@ksherlock
Copy link

if strchr(bp, '\n') didn't find anything the first time, it won't find anything the second time, either.
Change to'\0' to find the end-of-line. It's still a syntax error (the grammar requires a '\n') but it won't cause an alloc error.

This is only an issue if there's no end-of-line while lexing a rule's cost code (so not a problem with any of lcc's files).

if strchr(bp, '\n') didn't find anything the first time, it won't find anything the second time, either.
Change to '\0' to find the end-of-line. It's still a syntax error (the grammar requires a '\n') but it won't cause an alloc error.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant