Cedro
Data Fields
Byte_array Struct Reference

Data Fields

size_t len
 
size_t capacity
 
Byte_mut_p start
 

Detailed Description

Add 8 bytes after end of buffer to avoid bounds checking while scanning for tokens. No literal token is longer. The constant PADDING_Byte_ARRAY = 8 defines how many items are physically available after those valid elements.
This can be used to avoid special cases near the end when searching for fixed-length sequences in the array, although you have to set them to 0 or other appropriate value.

Field Documentation

◆ capacity

size_t Byte_array::capacity

Maximum length before reallocation is needed.

◆ len

size_t Byte_array::len

Current length, the number of valid elements.

◆ start

Byte_mut_p Byte_array::start

The items stored in this array.


The documentation for this struct was generated from the following file: