FIX[parser]: Check the order (row, column) in range before transforming

Fixes #155
This commit is contained in:
Nicolás Hatcher
2024-11-30 14:26:54 +01:00
committed by Nicolás Hatcher Andrés
parent 3270d587ac
commit 4b806c357a
4 changed files with 103 additions and 14 deletions

View File

@@ -53,6 +53,7 @@ mod test_extend;
mod test_fn_type;
mod test_frozen_rows_and_columns;
mod test_get_cell_content;
mod test_issue_155;
mod test_percentage;
mod test_set_functions_error_handling;
mod test_today;

View File

@@ -0,0 +1,14 @@
#![allow(clippy::unwrap_used)]
use crate::test::util::new_empty_model;
#[test]
fn issue_155() {
let mut model = new_empty_model();
model._set("A1", "1");
model._set("A2", "2");
model._set("B2", "=A$1:A2");
model.evaluate();
assert_eq!(model._get_formula("B2"), "=A$1:A2".to_string());
}