From: Christian Bauer Date: Tue, 18 Nov 2003 20:11:39 +0000 (+0000) Subject: added a do-nothing function option "dummy()" to simplify the creation of X-Git-Tag: release_1-2-0~66 X-Git-Url: https://www.ginac.de/ginac.git//ginac.git?p=ginac.git;a=commitdiff_plain;h=bc099eed88037df7288073ec29ccb894c799abd7 added a do-nothing function option "dummy()" to simplify the creation of functions without any eval(), evalf() etc. options --- diff --git a/ginac/function.pl b/ginac/function.pl index 1f944f1a..5558f4ee 100755 --- a/ginac/function.pl +++ b/ginac/function.pl @@ -257,6 +257,8 @@ public: function_options(std::string const & n, std::string const & tn=std::string()); ~function_options(); void initialize(); + + function_options & dummy() { return *this; } function_options & set_name(std::string const & n, std::string const & tn=std::string()); function_options & latex_name(std::string const & tn); // the following lines have been generated for max. ${maxargs} parameters @@ -482,7 +484,7 @@ function_options::function_options() function_options::function_options(std::string const & n, std::string const & tn) { initialize(); - set_name(n,tn); + set_name(n, tn); } function_options::~function_options() @@ -492,7 +494,7 @@ function_options::~function_options() void function_options::initialize() { - set_name("unnamed_function","\\\\mbox{unnamed}"); + set_name("unnamed_function", "\\\\mbox{unnamed}"); nparams = 0; eval_f = evalf_f = derivative_f = series_f = 0; evalf_params_first = true;