MCPcopy Create free account
hub / github.com/bytedance/bolt / next

Method next

bolt/common/memory/ByteStream.cpp:123–135  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

121}
122
123void ByteInputStream::next(bool throwIfPastEnd) {
124 BOLT_CHECK(current_ >= &ranges_[0]);
125 size_t position = current_ - &ranges_[0];
126 BOLT_CHECK_LT(position, ranges_.size());
127 if (position == ranges_.size() - 1) {
128 if (throwIfPastEnd) {
129 BOLT_FAIL("Reading past end of ByteInputStream");
130 }
131 return;
132 }
133 ++current_;
134 current_->position = 0;
135}
136
137uint8_t ByteInputStream::readByte() {
138 if (current_->position < current_->size) {

Callers 9

decodeFromByteSourceMethod · 0.45
markAsFreeFunction · 0.45
allocateFromFreeListMethod · 0.45
freeMethod · 0.45
storeStringFastMethod · 0.45
toStringMethod · 0.45
checkConsistencyMethod · 0.45
listSizeFunction · 0.45

Calls 1

sizeMethod · 0.45

Tested by

no test coverage detected