X-Git-Url: https://www.ginac.de/ginac.git//ginac.git?a=blobdiff_plain;ds=sidebyside;f=ginac%2Fclass_info.h;h=c9b8d9d2d2924ea55408d27f358b3128ca39b6c1;hb=c3a7dda76e171bbd1e1418b3dab56df49920f721;hp=df0992f15824b9dd631cf6d1141ee160c7af1c45;hpb=6a5d85aac330ef87ebdd46ae1c3f4c1e1b7bed3f;p=ginac.git diff --git a/ginac/class_info.h b/ginac/class_info.h index df0992f1..c9b8d9d2 100644 --- a/ginac/class_info.h +++ b/ginac/class_info.h @@ -3,7 +3,7 @@ * Helper templates to provide per-class information for class hierarchies. */ /* - * GiNaC Copyright (C) 1999-2007 Johannes Gutenberg University Mainz, Germany + * GiNaC Copyright (C) 1999-2020 Johannes Gutenberg University Mainz, Germany * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -20,17 +20,17 @@ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA */ -#ifndef __GINAC_CLASS_INFO_H__ -#define __GINAC_CLASS_INFO_H__ +#ifndef GINAC_CLASS_INFO_H +#define GINAC_CLASS_INFO_H #include // for size_t #include -#include -#include -#include -#include #include +#include +#include #include +#include +#include namespace GiNaC { @@ -40,13 +40,13 @@ namespace GiNaC { template class class_info { public: - class_info(const OPT & o) : options(o), next(first), parent(NULL) + class_info(const OPT & o) : options(o), next(first), parent(nullptr) { first = this; parents_identified = false; } - /** Get pointer to class_info of parent class (or NULL). */ + /** Get pointer to class_info of parent class (or nullptr). */ class_info *get_parent() const { identify_parents(); @@ -155,7 +155,7 @@ void class_info::dump_hierarchy(bool verbose) tree.push_back(tree_node(p)); // Identify children for all nodes and find the root - tree_node *root = NULL; + tree_node *root = nullptr; for (typename std::vector::iterator i = tree.begin(); i != tree.end(); ++i) { class_info *p = i->info->get_parent(); if (p) { @@ -190,9 +190,9 @@ void class_info::identify_parents() } } -template class_info *class_info::first = NULL; +template class_info *class_info::first = nullptr; template bool class_info::parents_identified = false; } // namespace GiNaC -#endif // ndef __GINAC_CLASS_INFO_H__ +#endif // ndef GINAC_CLASS_INFO_H