{"action":"created","issue":{"url":"https://api.github.com/repos/rust-lang/rfcs/issues/2500","repository_url":"https://api.github.com/repos/rust-lang/rfcs","labels_url":"https://api.github.com/repos/rust-lang/rfcs/issues/2500/labels{/name}","comments_url":"https://api.github.com/repos/rust-lang/rfcs/issues/2500/comments","events_url":"https://api.github.com/repos/rust-lang/rfcs/issues/2500/events","html_url":"https://github.com/rust-lang/rfcs/pull/2500","id":341265220,"node_id":"MDExOlB1bGxSZXF1ZXN0MjAxNDY3NjUz","number":2500,"title":"RFC: Pattern API","user":{"login":"kennytm","id":103023,"node_id":"MDQ6VXNlcjEwMzAyMw==","avatar_url":"https://avatars1.githubusercontent.com/u/103023?v=4","gravatar_id":"","url":"https://api.github.com/users/kennytm","html_url":"https://github.com/kennytm","followers_url":"https://api.github.com/users/kennytm/followers","following_url":"https://api.github.com/users/kennytm/following{/other_user}","gists_url":"https://api.github.com/users/kennytm/gists{/gist_id}","starred_url":"https://api.github.com/users/kennytm/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kennytm/subscriptions","organizations_url":"https://api.github.com/users/kennytm/orgs","repos_url":"https://api.github.com/users/kennytm/repos","events_url":"https://api.github.com/users/kennytm/events{/privacy}","received_events_url":"https://api.github.com/users/kennytm/received_events","type":"User","site_admin":false},"labels":[{"id":211667901,"node_id":"MDU6TGFiZWwyMTE2Njc5MDE=","url":"https://api.github.com/repos/rust-lang/rfcs/labels/T-libs","name":"T-libs","color":"bfd4f2","default":false}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":6,"created_at":"2018-07-14T20:23:50Z","updated_at":"2018-07-19T20:44:37Z","closed_at":null,"author_association":"MEMBER","pull_request":{"url":"https://api.github.com/repos/rust-lang/rfcs/pulls/2500","html_url":"https://github.com/rust-lang/rfcs/pull/2500","diff_url":"https://github.com/rust-lang/rfcs/pull/2500.diff","patch_url":"https://github.com/rust-lang/rfcs/pull/2500.patch"},"body":"* [Rendered](https://github.com/kennytm/rfcs/blob/pattern-3/text/0000-pattern-3.md)\r\n* [Pre-RFC](https://internals.rust-lang.org/t/pre-rfc-pattern-api-v3-0/7900)\r\n* Prototype:\r\n    * Source: https://github.com/kennytm/pattern-3\r\n    * Docs: https://docs.rs/pattern-3/"},"comment":{"url":"https://api.github.com/repos/rust-lang/rfcs/issues/comments/406408490","html_url":"https://github.com/rust-lang/rfcs/pull/2500#issuecomment-406408490","issue_url":"https://api.github.com/repos/rust-lang/rfcs/issues/2500","id":406408490,"node_id":"MDEyOklzc3VlQ29tbWVudDQwNjQwODQ5MA==","user":{"login":"shepmaster","id":174509,"node_id":"MDQ6VXNlcjE3NDUwOQ==","avatar_url":"https://avatars0.githubusercontent.com/u/174509?v=4","gravatar_id":"","url":"https://api.github.com/users/shepmaster","html_url":"https://github.com/shepmaster","followers_url":"https://api.github.com/users/shepmaster/followers","following_url":"https://api.github.com/users/shepmaster/following{/other_user}","gists_url":"https://api.github.com/users/shepmaster/gists{/gist_id}","starred_url":"https://api.github.com/users/shepmaster/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/shepmaster/subscriptions","organizations_url":"https://api.github.com/users/shepmaster/orgs","repos_url":"https://api.github.com/users/shepmaster/repos","events_url":"https://api.github.com/users/shepmaster/events{/privacy}","received_events_url":"https://api.github.com/users/shepmaster/received_events","type":"User","site_admin":false},"created_at":"2018-07-19T20:44:37Z","updated_at":"2018-07-19T20:44:37Z","author_association":"MEMBER","body":"### Experience report — implementing `Pattern` for searching `&[u8]`\r\n\r\nSee [my branch](https://github.com/shepmaster/jetscii/tree/pattern-3) ([permalink](https://github.com/shepmaster/jetscii/tree/f032c11914e157338d2e43a47dfb44c965857104)).\r\n\r\n#### Background\r\n\r\n[Previous comment](https://github.com/rust-lang/rfcs/pull/2500#issuecomment-406337209)\r\n\r\n#### Thoughts\r\n\r\n- I'm very happy that `Span::as_bytes` exists. I expected there to be a more general `map` though.\r\n- For my *particular* case, the `&[u8]` implementation is simpler because that's my core algorithm. My `&str` `Pattern` can actually delegate to the `&[u8]` one.\r\n\r\n#### Looking forward\r\n\r\nI've needed to write custom consumers of a `Pattern` before as well; I hope that to be the next comment."}}
{"actor":{"display_login":"shepmaster"}}