00001 /* 00002 00003 Copyright (C) 1999-2012 John W. Eaton 00004 00005 This file is part of Octave. 00006 00007 Octave is free software; you can redistribute it and/or modify it 00008 under the terms of the GNU General Public License as published by the 00009 Free Software Foundation; either version 3 of the License, or (at your 00010 option) any later version. 00011 00012 Octave is distributed in the hope that it will be useful, but WITHOUT 00013 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 00014 FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 00015 for more details. 00016 00017 You should have received a copy of the GNU General Public License 00018 along with Octave; see the file COPYING. If not, see 00019 <http://www.gnu.org/licenses/>. 00020 00021 */ 00022 00023 #if !defined (octave_tree_cell_h) 00024 #define octave_tree_cell_h 1 00025 00026 #include <iosfwd> 00027 00028 class octave_value; 00029 class octave_value_list; 00030 class tree_argument_list; 00031 00032 class tree_walker; 00033 00034 #include "pt-mat.h" 00035 #include "symtab.h" 00036 00037 // General cells. 00038 00039 class 00040 tree_cell : public tree_matrix 00041 { 00042 public: 00043 00044 tree_cell (tree_argument_list *row = 0, int l = -1, int c = -1) 00045 : tree_matrix (row, l, c) { } 00046 00047 ~tree_cell (void) { } 00048 00049 bool rvalue_ok (void) const { return true; } 00050 00051 octave_value rvalue1 (int nargout = 1); 00052 00053 octave_value_list rvalue (int); 00054 00055 tree_expression *dup (symbol_table::scope_id scope, 00056 symbol_table::context_id context) const; 00057 00058 void accept (tree_walker& tw); 00059 00060 private: 00061 00062 // No copying! 00063 00064 tree_cell (const tree_cell&); 00065 00066 tree_cell& operator = (const tree_cell&); 00067 }; 00068 00069 #endif