fixed: when incrementing space tables iterators in [for] statements we should invalidate indices for nested tables
This commit is contained in:
parent
44407c2a4b
commit
5e47313af8
|
@ -1447,6 +1447,7 @@ void Generator<StreamType, is_pikotools_stream, is_autoescape_stream>::CallSpace
|
||||||
{
|
{
|
||||||
// we are in [for...]statement, increment iterator and check the range
|
// we are in [for...]statement, increment iterator and check the range
|
||||||
space_wrapper.increment_iterator(model_wrapper_space_table_index, table->size());
|
space_wrapper.increment_iterator(model_wrapper_space_table_index, table->size());
|
||||||
|
space_wrapper.invalidate_iterators(model_wrapper_space_table_index + 1);
|
||||||
size_t iterator_value = space_wrapper.get_space_iterator_value(model_wrapper_space_table_index);
|
size_t iterator_value = space_wrapper.get_space_iterator_value(model_wrapper_space_table_index);
|
||||||
last_res = (iterator_value < table->size());
|
last_res = (iterator_value < table->size());
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue