comparison src/ov-struct.cc @ 5582:6bf56668b01a

[project @ 2005-12-15 01:08:20 by jwe]
author jwe
date Thu, 15 Dec 2005 01:10:05 +0000
parents 781c9e7dbb73
children 61d6cebd243b
comparison
equal deleted inserted replaced
5581:79ecf64976ce 5582:6bf56668b01a
496 %!test x=struct([]); 496 %!test x=struct([]);
497 %!assert(size(x),[0,0]); 497 %!assert(size(x),[0,0]);
498 %!assert(isstruct(x)); 498 %!assert(isstruct(x));
499 %!assert(isempty(fieldnames(x))); 499 %!assert(isempty(fieldnames(x)));
500 %!fail("struct('a',{1,2},'b',{1,2,3})","dimensions of parameter 2 do not match those of parameter 4") 500 %!fail("struct('a',{1,2},'b',{1,2,3})","dimensions of parameter 2 do not match those of parameter 4")
501 %!fail("struct(1,2,3,4)","struct expects alternating 'field',value pairs"); 501 %!fail("struct(1,2,3,4)","struct expects alternating \"field\", VALUE pairs");
502 %!fail("struct('1',2,'3')","struct expects alternating 'field',value pairs"); 502 %!fail("struct('1',2,'3')","struct expects alternating \"field\", VALUE pairs");
503 */ 503 */
504 504
505 DEFUN (struct, args, , 505 DEFUN (struct, args, ,
506 "-*- texinfo -*-\n\ 506 "-*- texinfo -*-\n\
507 @deftypefn {Built-in Function} {} struct (\"field\", @var{value}, \"field\", @var{value}, @dots{})\n\ 507 @deftypefn {Built-in Function} {} struct (\"field\", @var{value}, \"field\", @var{value}, @dots{})\n\