util/WritableBuffer: add method skip_front()

This commit is contained in:
Max Kellermann
2016-08-16 08:46:30 +02:00
parent 07e58ae64f
commit 87e0459fcc

View File

@@ -217,6 +217,15 @@ struct WritableBuffer {
pop_front(); pop_front();
return result; return result;
} }
void skip_front(size_type n) {
#ifndef NDEBUG
assert(size >= n);
#endif
data += n;
size -= n;
}
}; };
#endif #endif