comparison libinterp/parse-tree/pt-idx.cc @ 16661:8291109ac3fd

require that dynamic field names have only one row * pt-idx.cc (tree_index_expression::get_struct_index): Require field name to have one row.
author John W. Eaton <jwe@octave.org>
date Tue, 14 May 2013 05:24:19 -0400
parents cf84ea2ba2d3
children f0edd6c752e9
comparison
equal deleted inserted replaced
16660:cbb1bb7a5c3d 16661:8291109ac3fd
215 { 215 {
216 octave_value t = df->rvalue1 (); 216 octave_value t = df->rvalue1 ();
217 217
218 if (! error_state) 218 if (! error_state)
219 { 219 {
220 if (t.is_string ()) 220 if (t.is_string () && t.rows () == 1)
221 fn = t.string_value (); 221 fn = t.string_value ();
222 else 222 else
223 error ("dynamic structure field names must be character strings"); 223 error ("dynamic structure field names must be character strings");
224 } 224 }
225 } 225 }