{"action":"opened","issue":{"url":"https://api.github.com/repos/trishume/syntect/issues/25","repository_url":"https://api.github.com/repos/trishume/syntect","labels_url":"https://api.github.com/repos/trishume/syntect/issues/25/labels{/name}","comments_url":"https://api.github.com/repos/trishume/syntect/issues/25/comments","events_url":"https://api.github.com/repos/trishume/syntect/issues/25/events","html_url":"https://github.com/trishume/syntect/issues/25","id":194189636,"number":25,"title":"Infinite Loop on C files","user":{"login":"trishume","id":887610,"avatar_url":"https://avatars.githubusercontent.com/u/887610?v=3","gravatar_id":"","url":"https://api.github.com/users/trishume","html_url":"https://github.com/trishume","followers_url":"https://api.github.com/users/trishume/followers","following_url":"https://api.github.com/users/trishume/following{/other_user}","gists_url":"https://api.github.com/users/trishume/gists{/gist_id}","starred_url":"https://api.github.com/users/trishume/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/trishume/subscriptions","organizations_url":"https://api.github.com/users/trishume/orgs","repos_url":"https://api.github.com/users/trishume/repos","events_url":"https://api.github.com/users/trishume/events{/privacy}","received_events_url":"https://api.github.com/users/trishume/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":{"login":"trishume","id":887610,"avatar_url":"https://avatars.githubusercontent.com/u/887610?v=3","gravatar_id":"","url":"https://api.github.com/users/trishume","html_url":"https://github.com/trishume","followers_url":"https://api.github.com/users/trishume/followers","following_url":"https://api.github.com/users/trishume/following{/other_user}","gists_url":"https://api.github.com/users/trishume/gists{/gist_id}","starred_url":"https://api.github.com/users/trishume/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/trishume/subscriptions","organizations_url":"https://api.github.com/users/trishume/orgs","repos_url":"https://api.github.com/users/trishume/repos","events_url":"https://api.github.com/users/trishume/events{/privacy}","received_events_url":"https://api.github.com/users/trishume/received_events","type":"User","site_admin":false},"assignees":[{"login":"trishume","id":887610,"avatar_url":"https://avatars.githubusercontent.com/u/887610?v=3","gravatar_id":"","url":"https://api.github.com/users/trishume","html_url":"https://github.com/trishume","followers_url":"https://api.github.com/users/trishume/followers","following_url":"https://api.github.com/users/trishume/following{/other_user}","gists_url":"https://api.github.com/users/trishume/gists{/gist_id}","starred_url":"https://api.github.com/users/trishume/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/trishume/subscriptions","organizations_url":"https://api.github.com/users/trishume/orgs","repos_url":"https://api.github.com/users/trishume/repos","events_url":"https://api.github.com/users/trishume/events{/privacy}","received_events_url":"https://api.github.com/users/trishume/received_events","type":"User","site_admin":false}],"milestone":null,"comments":0,"created_at":"2016-12-07T22:25:09Z","updated_at":"2016-12-07T22:25:09Z","closed_at":null,"body":"There's an infinite loop bug on some C files due to a broken pattern in the default Sublime C syntax that can cause an infinite loop. Despite the pattern being borked syntect should handle this gracefully like Sublime Text obviously does.\r\n\r\n## Example \r\n\r\ntext: `struct{estruct`\r\n\r\nFirst it matches\r\n```yaml\r\n- match: '(?={{before_tag}})'\r\n   push: data-structures\r\n```\r\nat position 8 and then matches\r\n```yaml\r\n- match: '(?=\\S)'\r\n      pop: true\r\n```\r\nat the same position, and then repeats.\r\n\r\n## Possible solution\r\n\r\nNo single pattern should be able to trigger more than once at the same location. Maybe keep track of which patterns have triggered and ignore any further matches, resetting the store upon advancing. The trick is maintaining performance."}}
{"actor":{"display_login":"trishume"}}