{"action":"opened","issue":{"url":"https://api.github.com/repos/dsc/bitstring.js/issues/5","repository_url":"https://api.github.com/repos/dsc/bitstring.js","labels_url":"https://api.github.com/repos/dsc/bitstring.js/issues/5/labels{/name}","comments_url":"https://api.github.com/repos/dsc/bitstring.js/issues/5/comments","events_url":"https://api.github.com/repos/dsc/bitstring.js/issues/5/events","html_url":"https://github.com/dsc/bitstring.js/issues/5","id":319267788,"number":5,"title":"Can't read long bit length","user":{"login":"nickboucher","id":8355894,"avatar_url":"https://avatars1.githubusercontent.com/u/8355894?v=4","gravatar_id":"","url":"https://api.github.com/users/nickboucher","html_url":"https://github.com/nickboucher","followers_url":"https://api.github.com/users/nickboucher/followers","following_url":"https://api.github.com/users/nickboucher/following{/other_user}","gists_url":"https://api.github.com/users/nickboucher/gists{/gist_id}","starred_url":"https://api.github.com/users/nickboucher/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nickboucher/subscriptions","organizations_url":"https://api.github.com/users/nickboucher/orgs","repos_url":"https://api.github.com/users/nickboucher/repos","events_url":"https://api.github.com/users/nickboucher/events{/privacy}","received_events_url":"https://api.github.com/users/nickboucher/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2018-05-01T17:36:44Z","updated_at":"2018-05-01T17:36:44Z","closed_at":null,"author_association":"NONE","body":"Just as in Issue #4, JS 32-bit limitations for bitwise operations prevent reading bit lengths greater than 31 bits because of the following section of `.readbits()`:\r\n```js\r\n    while (size < n) {\r\n      byte = this._nextbyte();\r\n      if (byte == null) {\r\n        break;\r\n      }\r\n      size += 8;\r\n      // This is the problematic line, since the bitshift value accumulates within the `while` loop\r\n      bits = bits << 8 | byte;\r\n    }\r\n```"}}
{"actor":{"display_login":"nickboucher"}}