{"action":"created","issue":{"url":"https://api.github.com/repos/dabeaz/sly/issues/21","repository_url":"https://api.github.com/repos/dabeaz/sly","labels_url":"https://api.github.com/repos/dabeaz/sly/issues/21/labels{/name}","comments_url":"https://api.github.com/repos/dabeaz/sly/issues/21/comments","events_url":"https://api.github.com/repos/dabeaz/sly/issues/21/events","html_url":"https://github.com/dabeaz/sly/issues/21","id":386814850,"node_id":"MDU6SXNzdWUzODY4MTQ4NTA=","number":21,"title":"How do I link Parsing Rules?","user":{"login":"SaxonRah","id":1730424,"node_id":"MDQ6VXNlcjE3MzA0MjQ=","avatar_url":"https://avatars3.githubusercontent.com/u/1730424?v=4","gravatar_id":"","url":"https://api.github.com/users/SaxonRah","html_url":"https://github.com/SaxonRah","followers_url":"https://api.github.com/users/SaxonRah/followers","following_url":"https://api.github.com/users/SaxonRah/following{/other_user}","gists_url":"https://api.github.com/users/SaxonRah/gists{/gist_id}","starred_url":"https://api.github.com/users/SaxonRah/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/SaxonRah/subscriptions","organizations_url":"https://api.github.com/users/SaxonRah/orgs","repos_url":"https://api.github.com/users/SaxonRah/repos","events_url":"https://api.github.com/users/SaxonRah/events{/privacy}","received_events_url":"https://api.github.com/users/SaxonRah/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":1,"created_at":"2018-12-03T13:21:10Z","updated_at":"2018-12-03T13:47:07Z","closed_at":"2018-12-03T13:47:07Z","author_association":"NONE","body":"In ply, We would use a doc string like so\r\n`'''program : program statement\r\n               | statement'''`\r\nthen later something like\r\n`'''statement : INTEGER command NEWLINE'''`\r\nTo link parsing rules to a token for use later.\r\n\r\nHow would you do something similar in sly?\r\nAll the examples I have seen are something like\r\n`@_('program statement',\r\n   'statement')`\r\n\r\nSo, how do I link the rules ('program statement', 'statement') to a token (program)?\r\nOr rather define those rules as that token?\r\n\r\nIs the function name the token that defines those rules in the decorator?\r\nSo I'd then use the function name in the decorators?\r\n\r\nLike so ?\r\n`@_('program statement', 'statement')`\r\n`def program(p):\r\n`\r\n`@_('INTEGER command NEWLINE')`\r\n`def statement(p):\r\n  `\r\n(I might not be using correct terminology)\r\n"},"comment":{"url":"https://api.github.com/repos/dabeaz/sly/issues/comments/443715195","html_url":"https://github.com/dabeaz/sly/issues/21#issuecomment-443715195","issue_url":"https://api.github.com/repos/dabeaz/sly/issues/21","id":443715195,"node_id":"MDEyOklzc3VlQ29tbWVudDQ0MzcxNTE5NQ==","user":{"login":"SaxonRah","id":1730424,"node_id":"MDQ6VXNlcjE3MzA0MjQ=","avatar_url":"https://avatars3.githubusercontent.com/u/1730424?v=4","gravatar_id":"","url":"https://api.github.com/users/SaxonRah","html_url":"https://github.com/SaxonRah","followers_url":"https://api.github.com/users/SaxonRah/followers","following_url":"https://api.github.com/users/SaxonRah/following{/other_user}","gists_url":"https://api.github.com/users/SaxonRah/gists{/gist_id}","starred_url":"https://api.github.com/users/SaxonRah/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/SaxonRah/subscriptions","organizations_url":"https://api.github.com/users/SaxonRah/orgs","repos_url":"https://api.github.com/users/SaxonRah/repos","events_url":"https://api.github.com/users/SaxonRah/events{/privacy}","received_events_url":"https://api.github.com/users/SaxonRah/received_events","type":"User","site_admin":false},"created_at":"2018-12-03T13:47:07Z","updated_at":"2018-12-03T13:47:07Z","author_association":"NONE","body":"Ah, very nice, Thank you so much for the timely response and help, I really appreciate it. \r\n\r\nAlso, thanks for ply and sly!"}}
{"actor":{"display_login":"SaxonRah"}}