]> www.ginac.de Git - ginac.git/blobdiff - ginac/basic.cpp
Make ample use of the contextual keyword 'override'.
[ginac.git] / ginac / basic.cpp
index 59cd08f3b230fd045056c8cdefa003b797999cca..01d369716f30870d2bf8e0eeab2441278647e97c 100644 (file)
@@ -421,7 +421,7 @@ ex basic::eval(int level) const
 struct evalf_map_function : public map_function {
        int level;
        evalf_map_function(int l) : level(l) {}
-       ex operator()(const ex & e) { return evalf(e, level); }
+       ex operator()(const ex & e) override { return evalf(e, level); }
 };
 
 /** Evaluate object numerically. */
@@ -443,7 +443,7 @@ ex basic::evalf(int level) const
 
 /** Function object to be applied by basic::evalm(). */
 struct evalm_map_function : public map_function {
-       ex operator()(const ex & e) { return evalm(e); }
+       ex operator()(const ex & e) override { return evalm(e); }
 } map_evalm;
 
 /** Evaluate sums, products and integer powers of matrices. */
@@ -457,7 +457,7 @@ ex basic::evalm() const
 
 /** Function object to be applied by basic::eval_integ(). */
 struct eval_integ_map_function : public map_function {
-       ex operator()(const ex & e) { return eval_integ(e); }
+       ex operator()(const ex & e) override { return eval_integ(e); }
 } map_eval_integ;
 
 /** Evaluate integrals, if result is known. */
@@ -703,7 +703,7 @@ ex basic::eval_ncmul(const exvector & v) const
 struct derivative_map_function : public map_function {
        const symbol &s;
        derivative_map_function(const symbol &sym) : s(sym) {}
-       ex operator()(const ex & e) { return diff(e, s); }
+       ex operator()(const ex & e) override { return diff(e, s); }
 };
 
 /** Default implementation of ex::diff(). It maps the operation on the
@@ -797,7 +797,7 @@ unsigned basic::calchash() const
 struct expand_map_function : public map_function {
        unsigned options;
        expand_map_function(unsigned o) : options(o) {}
-       ex operator()(const ex & e) { return e.expand(options); }
+       ex operator()(const ex & e) override { return e.expand(options); }
 };
 
 /** Expand expression, i.e. multiply it out and return the result as a new