Mercurial > octave-nkf
comparison src/ov.cc @ 4219:23d06c9e1edd
[project @ 2002-12-06 21:29:17 by jwe]
author | jwe |
---|---|
date | Fri, 06 Dec 2002 21:29:19 +0000 |
parents | 5719210fff4c |
children | ccfdb55c8156 |
comparison
equal
deleted
inserted
replaced
4218:4a392a01e51a | 4219:23d06c9e1edd |
---|---|
566 } | 566 } |
567 } | 567 } |
568 | 568 |
569 octave_value_list | 569 octave_value_list |
570 octave_value::subsref (const std::string type, | 570 octave_value::subsref (const std::string type, |
571 const SLList<octave_value_list>& idx, int nargout) | 571 const std::list<octave_value_list>& idx, int nargout) |
572 { | 572 { |
573 if (is_constant ()) | 573 if (is_constant ()) |
574 return rep->subsref (type, idx); | 574 return rep->subsref (type, idx); |
575 else | 575 else |
576 return rep->subsref (type, idx, nargout); | 576 return rep->subsref (type, idx, nargout); |
577 } | 577 } |
578 | 578 |
579 octave_value | 579 octave_value |
580 octave_value::next_subsref (const std::string type, | 580 octave_value::next_subsref (const std::string type, |
581 const SLList<octave_value_list>& idx, | 581 const std::list<octave_value_list>& idx, |
582 int skip) | 582 int skip) |
583 { | 583 { |
584 assert (skip > 0); | 584 assert (skip > 0); |
585 | 585 |
586 if (idx.length () > skip) | 586 if (idx.size () > skip) |
587 { | 587 { |
588 SLList<octave_value_list> new_idx (idx); | 588 std::list<octave_value_list> new_idx (idx); |
589 for (int i = 0; i < skip; i++) | 589 for (int i = 0; i < skip; i++) |
590 new_idx.remove_front (); | 590 new_idx.erase (new_idx.begin ()); |
591 return subsref (type.substr (skip), new_idx); | 591 return subsref (type.substr (skip), new_idx); |
592 } | 592 } |
593 else | 593 else |
594 return *this; | 594 return *this; |
595 } | 595 } |
627 tn1.c_str (), on.c_str (), tn2.c_str ()); | 627 tn1.c_str (), on.c_str (), tn2.c_str ()); |
628 } | 628 } |
629 | 629 |
630 octave_value | 630 octave_value |
631 octave_value::subsasgn (const std::string type, | 631 octave_value::subsasgn (const std::string type, |
632 const SLList<octave_value_list>& idx, | 632 const std::list<octave_value_list>& idx, |
633 const octave_value& rhs) | 633 const octave_value& rhs) |
634 { | 634 { |
635 return rep->subsasgn (type, idx, rhs); | 635 return rep->subsasgn (type, idx, rhs); |
636 } | 636 } |
637 | 637 |
638 octave_value | 638 octave_value |
639 octave_value::assign (assign_op op, const std::string type, | 639 octave_value::assign (assign_op op, const std::string type, |
640 const SLList<octave_value_list>& idx, | 640 const std::list<octave_value_list>& idx, |
641 const octave_value& rhs) | 641 const octave_value& rhs) |
642 { | 642 { |
643 octave_value retval; | 643 octave_value retval; |
644 | 644 |
645 make_unique (); | 645 make_unique (); |
1078 tn2.c_str (), tn1.c_str ()); | 1078 tn2.c_str (), tn1.c_str ()); |
1079 } | 1079 } |
1080 | 1080 |
1081 octave_value | 1081 octave_value |
1082 octave_value::numeric_assign (const std::string type, | 1082 octave_value::numeric_assign (const std::string type, |
1083 const SLList<octave_value_list>& idx, | 1083 const std::list<octave_value_list>& idx, |
1084 const octave_value& rhs) | 1084 const octave_value& rhs) |
1085 { | 1085 { |
1086 octave_value retval; | 1086 octave_value retval; |
1087 | 1087 |
1088 int t_lhs = type_id (); | 1088 int t_lhs = type_id (); |
1431 abort (); | 1431 abort (); |
1432 } | 1432 } |
1433 | 1433 |
1434 octave_value | 1434 octave_value |
1435 octave_value::do_non_const_unary_op (unary_op op, const std::string type, | 1435 octave_value::do_non_const_unary_op (unary_op op, const std::string type, |
1436 const SLList<octave_value_list>& idx) | 1436 const std::list<octave_value_list>& idx) |
1437 { | 1437 { |
1438 octave_value retval; | 1438 octave_value retval; |
1439 | 1439 |
1440 if (idx.empty ()) | 1440 if (idx.empty ()) |
1441 { | 1441 { |