MCPcopy Create free account
hub / github.com/TruthHun/BookStack / send_bits

Function send_bits

static/word2md/mammoth.browser.js:22548–22558  ·  view source on GitHub ↗
(s, value, length)

Source from the content-addressed store, hash-verified

22546 * IN assertion: length <= 16 and value fits in length bits.
22547 */
22548function send_bits(s, value, length) {
22549 if (s.bi_valid > (Buf_size - length)) {
22550 s.bi_buf |= (value << s.bi_valid) & 0xffff;
22551 put_short(s, s.bi_buf);
22552 s.bi_buf = value >> (Buf_size - s.bi_valid);
22553 s.bi_valid += length - Buf_size;
22554 } else {
22555 s.bi_buf |= (value << s.bi_valid) & 0xffff;
22556 s.bi_valid += length;
22557 }
22558}
22559
22560
22561function send_code(s, c, tree) {

Callers 7

send_codeFunction · 0.70
compress_blockFunction · 0.70
send_treeFunction · 0.70
send_all_treesFunction · 0.70
_tr_stored_blockFunction · 0.70
_tr_alignFunction · 0.70
_tr_flush_blockFunction · 0.70

Calls 1

put_shortFunction · 0.70

Tested by

no test coverage detected