{"action":"created","issue":{"url":"https://api.github.com/repos/mozilla/sweet.js/issues/434","labels_url":"https://api.github.com/repos/mozilla/sweet.js/issues/434/labels{/name}","comments_url":"https://api.github.com/repos/mozilla/sweet.js/issues/434/comments","events_url":"https://api.github.com/repos/mozilla/sweet.js/issues/434/events","html_url":"https://github.com/mozilla/sweet.js/issues/434","id":52088241,"number":434,"title":"Using `/` and `'` in macro matching patterns","user":{"login":"iffsid","id":1027018,"avatar_url":"https://avatars.githubusercontent.com/u/1027018?v=3","gravatar_id":"","url":"https://api.github.com/users/iffsid","html_url":"https://github.com/iffsid","followers_url":"https://api.github.com/users/iffsid/followers","following_url":"https://api.github.com/users/iffsid/following{/other_user}","gists_url":"https://api.github.com/users/iffsid/gists{/gist_id}","starred_url":"https://api.github.com/users/iffsid/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/iffsid/subscriptions","organizations_url":"https://api.github.com/users/iffsid/orgs","repos_url":"https://api.github.com/users/iffsid/repos","events_url":"https://api.github.com/users/iffsid/events{/privacy}","received_events_url":"https://api.github.com/users/iffsid/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":3,"created_at":"2014-12-16T09:08:10Z","updated_at":"2015-01-08T17:50:32Z","closed_at":null,"body":"Would it be possible to enable the use of `/` and `'` as part of macro pattern matches?\r\nI understand that through #290, it ought to be possible to use any symbol within `literal groups`, but they throw up errors when used for these characters/symbols. A workaround for `/` at least, as referenced in #283, appears to be looking at the previous token -- although I'm not sure how that would apply within the pattern-matching part of a macro.\r\n\r\nFor `/`, trying\r\n~~~\r\nmacro scdiv {\r\n  case {_ ($[/] $e ...)} => { return #{ ($e (/) ...) } }\r\n}\r\n\r\nscdiv (/ 3 4)\r\n~~~\r\ngives me\r\n~~~\r\n/home/.../sweet.js/lib/parser.js:1898\r\n        throw error;\r\n              ^\r\nError: Line 21: Invalid regular expression\r\n[... ) } )  ...]\r\n[...snip...]\r\n~~~\r\nand for `'`, trying\r\n~~~\r\nmacro scquot {\r\n  case {_ $[']($e ...)} => { return #{[ $e (,) ... ]} }\r\n}\r\n\r\nscquot '(1 2 foo bar)\r\n~~~\r\ngives me\r\n~~~\r\n/home/.../sweet.js/lib/parser.js:1898\r\n        throw error;\r\n              ^\r\nError: Line 27: Unexpected token ILLEGAL\r\n[... ) } )  ...]\r\n[...snip...]\r\n~~~"},"comment":{"url":"https://api.github.com/repos/mozilla/sweet.js/issues/comments/69218774","html_url":"https://github.com/mozilla/sweet.js/issues/434#issuecomment-69218774","issue_url":"https://api.github.com/repos/mozilla/sweet.js/issues/434","id":69218774,"user":{"login":"iffsid","id":1027018,"avatar_url":"https://avatars.githubusercontent.com/u/1027018?v=3","gravatar_id":"","url":"https://api.github.com/users/iffsid","html_url":"https://github.com/iffsid","followers_url":"https://api.github.com/users/iffsid/followers","following_url":"https://api.github.com/users/iffsid/following{/other_user}","gists_url":"https://api.github.com/users/iffsid/gists{/gist_id}","starred_url":"https://api.github.com/users/iffsid/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/iffsid/subscriptions","organizations_url":"https://api.github.com/users/iffsid/orgs","repos_url":"https://api.github.com/users/iffsid/repos","events_url":"https://api.github.com/users/iffsid/events{/privacy}","received_events_url":"https://api.github.com/users/iffsid/received_events","type":"User","site_admin":false},"created_at":"2015-01-08T17:50:32Z","updated_at":"2015-01-08T17:50:32Z","body":"Any ideas on what would be proper, acceptable ways to solve these issues?\r\nI spent some time trying to hack out a solution to the second issue, but no dice."}}