{"action":"created","issue":{"url":"https://api.github.com/repos/tj/co/issues/235","labels_url":"https://api.github.com/repos/tj/co/issues/235/labels{/name}","comments_url":"https://api.github.com/repos/tj/co/issues/235/comments","events_url":"https://api.github.com/repos/tj/co/issues/235/events","html_url":"https://github.com/tj/co/pull/235","id":95299763,"number":235,"title":"Enable co function optimization by V8","user":{"login":"ruimarinho","id":288709,"avatar_url":"https://avatars.githubusercontent.com/u/288709?v=3","gravatar_id":"","url":"https://api.github.com/users/ruimarinho","html_url":"https://github.com/ruimarinho","followers_url":"https://api.github.com/users/ruimarinho/followers","following_url":"https://api.github.com/users/ruimarinho/following{/other_user}","gists_url":"https://api.github.com/users/ruimarinho/gists{/gist_id}","starred_url":"https://api.github.com/users/ruimarinho/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ruimarinho/subscriptions","organizations_url":"https://api.github.com/users/ruimarinho/orgs","repos_url":"https://api.github.com/users/ruimarinho/repos","events_url":"https://api.github.com/users/ruimarinho/events{/privacy}","received_events_url":"https://api.github.com/users/ruimarinho/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2015-07-15T22:00:44Z","updated_at":"2015-07-16T06:00:45Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/tj/co/pulls/235","html_url":"https://github.com/tj/co/pull/235","diff_url":"https://github.com/tj/co/pull/235.diff","patch_url":"https://github.com/tj/co/pull/235.patch"},"body":"Inlining slicing of arguments allows V8 to optimize the main `co` function. Also added a tiny test which was missing when `co` receives is called with no arguments.\r\n\r\n**Before**:\r\n\r\n```\r\n[compiling method 0x15a40d13ab61 <JS Function co (SharedFunctionInfo 0x2d5161561089)> using Crankshaft]\r\n[aborted optimizing 0x15a40d13ab61 <JS Function co (SharedFunctionInfo 0x2d5161561089)> because: Bad value context for arguments value]\r\n```\r\n\r\n**After**:\r\n\r\n```\r\n[compiling method 0x3a75df13acf9 <JS Function co (SharedFunctionInfo 0x3f32caa61089)> using Crankshaft]\r\n[optimizing 0x3a75df13acf9 <JS Function co (SharedFunctionInfo 0x3f32caa61089)> - took 0.096, 0.130, 0.100 ms]\r\n```\r\n\r\nThis is just a small optimisation but we have to start somewhere :)"},"comment":{"url":"https://api.github.com/repos/tj/co/issues/comments/121842431","html_url":"https://github.com/tj/co/pull/235#issuecomment-121842431","issue_url":"https://api.github.com/repos/tj/co/issues/235","id":121842431,"user":{"login":"bucaran","id":8317250,"avatar_url":"https://avatars.githubusercontent.com/u/8317250?v=3","gravatar_id":"","url":"https://api.github.com/users/bucaran","html_url":"https://github.com/bucaran","followers_url":"https://api.github.com/users/bucaran/followers","following_url":"https://api.github.com/users/bucaran/following{/other_user}","gists_url":"https://api.github.com/users/bucaran/gists{/gist_id}","starred_url":"https://api.github.com/users/bucaran/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bucaran/subscriptions","organizations_url":"https://api.github.com/users/bucaran/orgs","repos_url":"https://api.github.com/users/bucaran/repos","events_url":"https://api.github.com/users/bucaran/events{/privacy}","received_events_url":"https://api.github.com/users/bucaran/received_events","type":"User","site_admin":false},"created_at":"2015-07-16T06:00:45Z","updated_at":"2015-07-16T06:00:45Z","body":"@ruimarinho IMO this hurts readability more than it optimizes performance, but on the other hand, `co` is a low level library and if this could potentially benefit higher level libraries I think it's acceptable.\r\n\r\nHaving said that, how often do you think people will use this new feature, I mean, `co` had been around years before I [introduced that](https://github.com/tj/co/pull/232)."}}