{"action":"created","issue":{"url":"https://api.github.com/repos/rust-lang/time/issues/110","labels_url":"https://api.github.com/repos/rust-lang/time/issues/110/labels{/name}","comments_url":"https://api.github.com/repos/rust-lang/time/issues/110/comments","events_url":"https://api.github.com/repos/rust-lang/time/issues/110/events","html_url":"https://github.com/rust-lang/time/pull/110","id":93163658,"number":110,"title":"Arithmetic overflow in SteadyTime subtraction on OS X / iOS","user":{"login":"bmastenbrook","id":1457527,"avatar_url":"https://avatars.githubusercontent.com/u/1457527?v=3","gravatar_id":"","url":"https://api.github.com/users/bmastenbrook","html_url":"https://github.com/bmastenbrook","followers_url":"https://api.github.com/users/bmastenbrook/followers","following_url":"https://api.github.com/users/bmastenbrook/following{/other_user}","gists_url":"https://api.github.com/users/bmastenbrook/gists{/gist_id}","starred_url":"https://api.github.com/users/bmastenbrook/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bmastenbrook/subscriptions","organizations_url":"https://api.github.com/users/bmastenbrook/orgs","repos_url":"https://api.github.com/users/bmastenbrook/repos","events_url":"https://api.github.com/users/bmastenbrook/events{/privacy}","received_events_url":"https://api.github.com/users/bmastenbrook/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":{"login":"huonw","id":1203825,"avatar_url":"https://avatars.githubusercontent.com/u/1203825?v=3","gravatar_id":"","url":"https://api.github.com/users/huonw","html_url":"https://github.com/huonw","followers_url":"https://api.github.com/users/huonw/followers","following_url":"https://api.github.com/users/huonw/following{/other_user}","gists_url":"https://api.github.com/users/huonw/gists{/gist_id}","starred_url":"https://api.github.com/users/huonw/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/huonw/subscriptions","organizations_url":"https://api.github.com/users/huonw/orgs","repos_url":"https://api.github.com/users/huonw/repos","events_url":"https://api.github.com/users/huonw/events{/privacy}","received_events_url":"https://api.github.com/users/huonw/received_events","type":"User","site_admin":false},"milestone":null,"comments":2,"created_at":"2015-07-06T01:03:33Z","updated_at":"2015-07-06T01:38:13Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/rust-lang/time/pulls/110","html_url":"https://github.com/rust-lang/time/pull/110","diff_url":"https://github.com/rust-lang/time/pull/110.diff","patch_url":"https://github.com/rust-lang/time/pull/110.patch"},"body":"Subtracting two SteadyTime values fails on OS X or iOS if the resulting Duration would be negative. Casting before the subtraction fixes the issue. I don't believe the cast itself can ever fail, as the value is based on a time elapsed since system boot and has a resolution of at most (least?) one nanosecond."},"comment":{"url":"https://api.github.com/repos/rust-lang/time/issues/comments/118689199","html_url":"https://github.com/rust-lang/time/pull/110#issuecomment-118689199","issue_url":"https://api.github.com/repos/rust-lang/time/issues/110","id":118689199,"user":{"login":"bmastenbrook","id":1457527,"avatar_url":"https://avatars.githubusercontent.com/u/1457527?v=3","gravatar_id":"","url":"https://api.github.com/users/bmastenbrook","html_url":"https://github.com/bmastenbrook","followers_url":"https://api.github.com/users/bmastenbrook/followers","following_url":"https://api.github.com/users/bmastenbrook/following{/other_user}","gists_url":"https://api.github.com/users/bmastenbrook/gists{/gist_id}","starred_url":"https://api.github.com/users/bmastenbrook/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bmastenbrook/subscriptions","organizations_url":"https://api.github.com/users/bmastenbrook/orgs","repos_url":"https://api.github.com/users/bmastenbrook/repos","events_url":"https://api.github.com/users/bmastenbrook/events{/privacy}","received_events_url":"https://api.github.com/users/bmastenbrook/received_events","type":"User","site_admin":false},"created_at":"2015-07-06T01:38:13Z","updated_at":"2015-07-06T01:38:13Z","body":"Sure thing."}}