| 469 | } |
| 470 | |
| 471 | void ByteVector::appendField(uint64_t value,unsigned lengthBits) |
| 472 | { |
| 473 | setField(growBits(lengthBits),value,lengthBits); |
| 474 | /*** old |
| 475 | int endpos = mBitInd + lengthBits; // 1 past the 0-based index of the last bit. |
| 476 | int nbytes = (endpos-1) / 8; // number of new bytes needed. |
| 477 | if (mBitInd == 0) nbytes++; // if at 0, the next byte has not been alloced yet. |
| 478 | setField2(grow(nbytes),mBitInd,value,lengthBits); |
| 479 | mBitInd = endpos % 8; |
| 480 | ***/ |
| 481 | } |
| 482 | |
| 483 | // Read a bit field starting at specified byte and bit, each numbered from 0. |
| 484 | // Bit numbering is from high to low, like this: |
no outgoing calls
no test coverage detected