{"action":"created","issue":{"url":"https://api.github.com/repos/nim-lang/Nim/issues/3143","labels_url":"https://api.github.com/repos/nim-lang/Nim/issues/3143/labels{/name}","comments_url":"https://api.github.com/repos/nim-lang/Nim/issues/3143/comments","events_url":"https://api.github.com/repos/nim-lang/Nim/issues/3143/events","html_url":"https://github.com/nim-lang/Nim/pull/3143","id":96921268,"number":3143,"title":"Improve performance of readLine by using fgets","user":{"login":"def-","id":2335377,"avatar_url":"https://avatars.githubusercontent.com/u/2335377?v=3","gravatar_id":"","url":"https://api.github.com/users/def-","html_url":"https://github.com/def-","followers_url":"https://api.github.com/users/def-/followers","following_url":"https://api.github.com/users/def-/following{/other_user}","gists_url":"https://api.github.com/users/def-/gists{/gist_id}","starred_url":"https://api.github.com/users/def-/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/def-/subscriptions","organizations_url":"https://api.github.com/users/def-/orgs","repos_url":"https://api.github.com/users/def-/repos","events_url":"https://api.github.com/users/def-/events{/privacy}","received_events_url":"https://api.github.com/users/def-/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":8,"created_at":"2015-07-23T22:50:54Z","updated_at":"2015-07-24T22:02:46Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/nim-lang/Nim/pulls/3143","html_url":"https://github.com/nim-lang/Nim/pull/3143","diff_url":"https://github.com/nim-lang/Nim/pull/3143.diff","patch_url":"https://github.com/nim-lang/Nim/pull/3143.patch"},"body":"Solves #3084. I ran the tests by @scriptum on my machine:\r\n```\r\n        Time [s]\r\nC          0.078\r\nNim New    0.084\r\nPy2        0.128\r\nPy3        0.271\r\nNim Old    0.418\r\n```\r\nProblems:\r\n- This drops compatibility with pure CR line endings of old Mac systems.\r\n- When the lines contain '\\0' chars, this currently doesn't work properly. Not sure how to fix this, since `fgets` doesn't report the number of bytes read."},"comment":{"url":"https://api.github.com/repos/nim-lang/Nim/issues/comments/124740525","html_url":"https://github.com/nim-lang/Nim/pull/3143#issuecomment-124740525","issue_url":"https://api.github.com/repos/nim-lang/Nim/issues/3143","id":124740525,"user":{"login":"kirbyfan64","id":1690697,"avatar_url":"https://avatars.githubusercontent.com/u/1690697?v=3","gravatar_id":"","url":"https://api.github.com/users/kirbyfan64","html_url":"https://github.com/kirbyfan64","followers_url":"https://api.github.com/users/kirbyfan64/followers","following_url":"https://api.github.com/users/kirbyfan64/following{/other_user}","gists_url":"https://api.github.com/users/kirbyfan64/gists{/gist_id}","starred_url":"https://api.github.com/users/kirbyfan64/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kirbyfan64/subscriptions","organizations_url":"https://api.github.com/users/kirbyfan64/orgs","repos_url":"https://api.github.com/users/kirbyfan64/repos","events_url":"https://api.github.com/users/kirbyfan64/events{/privacy}","received_events_url":"https://api.github.com/users/kirbyfan64/received_events","type":"User","site_admin":false},"created_at":"2015-07-24T22:02:46Z","updated_at":"2015-07-24T22:02:46Z","body":"(stupid Nexus 5 keyboard) Python handles NULLs with fgets."}}