more flexibility in initializing table loop iterators

This commit is contained in:
Vern Paxson 2024-07-07 14:15:56 -07:00
parent 2fe3888c75
commit d0aad7b826

View file

@ -24,6 +24,12 @@ public:
// dynamic ones being done with SetLoopVars(). // dynamic ones being done with SetLoopVars().
TableIterInfo(const std::vector<TypePtr>* _loop_var_types, const std::vector<bool>* _lvt_is_managed, TableIterInfo(const std::vector<TypePtr>* _loop_var_types, const std::vector<bool>* _lvt_is_managed,
TypePtr _value_var_type) { TypePtr _value_var_type) {
SetIterInfo(_loop_var_types, _lvt_is_managed, std::move(_value_var_type));
}
// Sets the fixed fields.
void SetIterInfo(const std::vector<TypePtr>* _loop_var_types, const std::vector<bool>* _lvt_is_managed,
TypePtr _value_var_type) {
loop_var_types = _loop_var_types; loop_var_types = _loop_var_types;
lvt_is_managed = _lvt_is_managed; lvt_is_managed = _lvt_is_managed;
value_var_type = std::move(_value_var_type); value_var_type = std::move(_value_var_type);