{"action":"created","issue":{"url":"https://api.github.com/repos/redox-os/relibc/issues/66","repository_url":"https://api.github.com/repos/redox-os/relibc","labels_url":"https://api.github.com/repos/redox-os/relibc/issues/66/labels{/name}","comments_url":"https://api.github.com/repos/redox-os/relibc/issues/66/comments","events_url":"https://api.github.com/repos/redox-os/relibc/issues/66/events","html_url":"https://github.com/redox-os/relibc/pull/66","id":304149869,"number":66,"title":"Add implementation for a64l","user":{"login":"w0xel","id":12088060,"avatar_url":"https://avatars2.githubusercontent.com/u/12088060?v=4","gravatar_id":"","url":"https://api.github.com/users/w0xel","html_url":"https://github.com/w0xel","followers_url":"https://api.github.com/users/w0xel/followers","following_url":"https://api.github.com/users/w0xel/following{/other_user}","gists_url":"https://api.github.com/users/w0xel/gists{/gist_id}","starred_url":"https://api.github.com/users/w0xel/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/w0xel/subscriptions","organizations_url":"https://api.github.com/users/w0xel/orgs","repos_url":"https://api.github.com/users/w0xel/repos","events_url":"https://api.github.com/users/w0xel/events{/privacy}","received_events_url":"https://api.github.com/users/w0xel/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2018-03-11T11:16:36Z","updated_at":"2018-03-11T11:36:46Z","closed_at":null,"author_association":"NONE","pull_request":{"url":"https://api.github.com/repos/redox-os/relibc/pulls/66","html_url":"https://github.com/redox-os/relibc/pull/66","diff_url":"https://github.com/redox-os/relibc/pull/66.diff","patch_url":"https://github.com/redox-os/relibc/pull/66.patch"},"body":"Trying to get warm with the project. Interested in comments to:\r\n\r\n- line 27: I check for NULL, according to docs NULL results in undefined behavior. Should checks like these be made or ignored?\r\n- line 32: very C-style dereferencing of the array pointer. I did not see any reason to convert to a slice or even string, would be unsafe with deleted c-array anyways...\r\n\r\nWhen the PR gets accepted I will implement l64a (and hopefully many more functions :) )"},"comment":{"url":"https://api.github.com/repos/redox-os/relibc/issues/comments/372108481","html_url":"https://github.com/redox-os/relibc/pull/66#issuecomment-372108481","issue_url":"https://api.github.com/repos/redox-os/relibc/issues/66","id":372108481,"user":{"login":"Tommoa","id":3256078,"avatar_url":"https://avatars2.githubusercontent.com/u/3256078?v=4","gravatar_id":"","url":"https://api.github.com/users/Tommoa","html_url":"https://github.com/Tommoa","followers_url":"https://api.github.com/users/Tommoa/followers","following_url":"https://api.github.com/users/Tommoa/following{/other_user}","gists_url":"https://api.github.com/users/Tommoa/gists{/gist_id}","starred_url":"https://api.github.com/users/Tommoa/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Tommoa/subscriptions","organizations_url":"https://api.github.com/users/Tommoa/orgs","repos_url":"https://api.github.com/users/Tommoa/repos","events_url":"https://api.github.com/users/Tommoa/events{/privacy}","received_events_url":"https://api.github.com/users/Tommoa/received_events","type":"User","site_admin":false},"created_at":"2018-03-11T11:36:46Z","updated_at":"2018-03-11T11:36:46Z","author_association":"CONTRIBUTOR","body":"Hi there, welcome!\r\n\r\nA few things:\r\n\r\n- This is doing to be a C library, so null checks will be necessary. Rust pointers have an inbuild `.is_null()` method that you can use instead of having to convert to an integer type for checking.\r\n- Line 32 should be something along the lines of `let c = *s.offset(x);`\r\n- Line 31: I'd suggest doing something along the lines of `let len = strlen(s); let len = if len > 6 { 7 } else { len };` and then `for x in 0..len { ... }`. I think that'd improve readability"}}
{"actor":{"display_login":"Tommoa"}}