typedef ex (*fcnp2)(const exprseq &e, int serial);
struct fcn_desc {
- fcn_desc() : p(NULL), num_params(0), is_ginac(false), serial(0) {}
+ fcn_desc() : p(nullptr), num_params(0), is_ginac(false), serial(0) {}
fcn_desc(fcnp func, int num) : p(func), num_params(num), is_ginac(false), serial(0) {}
fcn_desc(fcnp2 func, int num, int ser) : p((fcnp)func), num_params(num), is_ginac(true), serial(ser) {}
exp : T_NUMBER {$$ = $1;}
| T_SYMBOL {
- exmap::const_iterator i = assigned_symbol_table.find($1);
+ auto i = assigned_symbol_table.find($1);
if (i == assigned_symbol_table.end())
$$ = $1;
else
| T_QUOTE2 {$$ = exstack[1];}
| T_QUOTE3 {$$ = exstack[2];}
| T_SYMBOL '(' exprseq ')' {
- fcn_tab::const_iterator i = find_function($1, $3.nops());
+ auto i = find_function($1, $3.nops());
if (i->second.is_ginac) {
$$ = ((fcnp2)(i->second.p))(ex_to<exprseq>($3), i->second.serial);
} else {
{"transpose", f_transpose, 1},
{"unassign", f_unassign, 1},
{"unit", f_unit, 2},
- {NULL, f_dummy, 0} // End marker
+ {nullptr, f_dummy, 0} // End marker
};
struct fcn_help_init {
{"H", "harmonic polylogarithm"},
{"Order", "order term function (for truncated power series)"},
{"Derivative", "inert differential operator"},
- {NULL, NULL} // End marker
+ {nullptr, nullptr} // End marker
};
#include "ginsh_extensions.h"
if (strncmp(fcn_name, text, len) == 0)
return strdup(fcn_name);
}
- return NULL;
+ return nullptr;
}
#ifdef HAVE_LIBREADLINE
file_list = argv + 1;
if (num_files) {
yyin = fopen(*file_list, "r");
- if (yyin == NULL) {
+ if (yyin == nullptr) {
cerr << "Can't open " << *file_list << endl;
exit(1);
}