Preprocessor: added new SymbolTable::orig_endo_nbr() method
parent
19338906ba
commit
ed84e27319
|
@ -210,7 +210,7 @@ SymbolTable::writeOutput(ostream &output) const throw (NotYetFrozenException)
|
||||||
<< "M_.param_nbr = " << param_nbr() << ";" << endl;
|
<< "M_.param_nbr = " << param_nbr() << ";" << endl;
|
||||||
|
|
||||||
// Write the auxiliary variable table
|
// Write the auxiliary variable table
|
||||||
output << "M_.orig_endo_nbr = " << endo_nbr() - aux_vars.size() << ";" << endl;
|
output << "M_.orig_endo_nbr = " << orig_endo_nbr() << ";" << endl;
|
||||||
if (aux_vars.size() == 0)
|
if (aux_vars.size() == 0)
|
||||||
output << "M_.aux_vars = [];" << endl;
|
output << "M_.aux_vars = [];" << endl;
|
||||||
else
|
else
|
||||||
|
|
|
@ -236,6 +236,8 @@ public:
|
||||||
inline int param_nbr() const throw (NotYetFrozenException);
|
inline int param_nbr() const throw (NotYetFrozenException);
|
||||||
//! Returns the greatest symbol ID (the smallest is zero)
|
//! Returns the greatest symbol ID (the smallest is zero)
|
||||||
inline int maxID();
|
inline int maxID();
|
||||||
|
//! Get number of user-declared endogenous variables (without the auxiliary variables)
|
||||||
|
inline int orig_endo_nbr() const throw (NotYetFrozenException);
|
||||||
//! Write output of this class
|
//! Write output of this class
|
||||||
void writeOutput(ostream &output) const throw (NotYetFrozenException);
|
void writeOutput(ostream &output) const throw (NotYetFrozenException);
|
||||||
//! Mark a symbol as predetermined variable
|
//! Mark a symbol as predetermined variable
|
||||||
|
@ -364,4 +366,10 @@ SymbolTable::maxID()
|
||||||
return (size-1);
|
return (size-1);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
inline int
|
||||||
|
SymbolTable::orig_endo_nbr() const throw (NotYetFrozenException)
|
||||||
|
{
|
||||||
|
return (endo_nbr() - aux_vars.size());
|
||||||
|
}
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
Loading…
Reference in New Issue