Set indexes directly rather than incrementing step by step

This commit is contained in:
Raphael Coeffic
2021-11-10 11:07:01 +01:00
parent d59bbd1020
commit c048b187b4
2 changed files with 13 additions and 11 deletions
@@ -73,6 +73,7 @@ class YamlTreeWalker
void incAttr() { stack[stack_level].attr_idx++; }
void incElmts() { stack[stack_level].elmts++; }
void setElmts(uint16_t idx) { stack[stack_level].elmts = idx; }
inline bool isIdxInvalid() {
return stack[stack_level].flags & FLAG_STATE_IDX_INVALID;