GNOME Bugzilla – Bug 613273
Argument type 'r' and single-cell names
Last modified: 2011-02-16 14:45:31 UTC
Functions that take 'r' type arguments will fail if given an argument that is a name defined to be a single cell. OFFSET is such a function. We have special code for the case where the single cell is given directly as an argument so that works ok. 1250 if (arg_type == 'A' || arg_type == 'r') { 1251 if (GNM_EXPR_GET_OPER (expr) == GNM_EXPR_OP_CELLREF) { >>>SPECIAL CASE 1252 GnmCellRef r; 1253 gnm_cellref_make_abs (&r, &expr->cellref.ref, ei->pos); 1254 args[i] = value_new_cellrange_unsafe (&r, &r); 1255 } else { 1256 tmp = args[i] = gnm_expr_eval (expr, ei->pos, 1257 GNM_EXPR_EVAL_PERMIT_NON_SCALAR); >>>SINGLE CELL WILL PRODUCE A (DEREFERENCED) VALUE 1258 if (tmp->type == VALUE_CELLRANGE) { 1259 gnm_cellref_make_abs (&tmp->v_ra
Created attachment 156601 [details] [review] Tentative patch This patch ought to solve the problem. However, I don't feel like messing with the evaluation system in the stable series.
Created attachment 158893 [details] [review] Updated patch Patch updated due to conflicts with unrelated changes.
The patch seems to work fine for me.
This problem has been fixed in our software repository. The fix will go into the next software release. Thank you for your bug report.