small refactorings

This commit is contained in:
2021-12-19 16:31:54 +01:00
parent 2a138d0c81
commit 498d1f17aa
7 changed files with 41 additions and 39 deletions

View File

@@ -19,8 +19,8 @@ MlValue uSQL::ivaluize(const usql::Table *table) {
for (auto row : table->m_rows) {
columns.clear();
for (int i = 0; i < table->columns_count(); i++) {
auto & c = row[i];
auto type = table->m_col_defs[i].type;
const auto & c = row[i];
const auto type = table->m_col_defs[i].type;
if (c.isNull()) {
columns.push_back(MlValue::nil());
} else if (type == ColumnType::integer_type || type == ColumnType::date_type) {