]> www.ginac.de Git - ginac.git/blobdiff - ginac/symbol.h
Add support for Texinfo-5.0.
[ginac.git] / ginac / symbol.h
index 3537776b7fa7c13b3e0860a0fc14cba70a666f42..519980f857dcededb579715ee1dbd9ff96ce3dac 100644 (file)
@@ -3,7 +3,7 @@
  *  Interface to GiNaC's symbolic objects. */
 
 /*
- *  GiNaC Copyright (C) 1999-2008 Johannes Gutenberg University Mainz, Germany
+ *  GiNaC Copyright (C) 1999-2011 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
  *  Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301  USA
  */
 
-#ifndef __GINAC_SYMBOL_H__
-#define __GINAC_SYMBOL_H__
+#ifndef GINAC_SYMBOL_H
+#define GINAC_SYMBOL_H
 
-#include <string>
-#include <typeinfo>
 #include "basic.h"
 #include "ex.h"
 #include "ptr.h"
 #include "archive.h"
 
+#include <string>
+#include <typeinfo>
+
 namespace GiNaC {
 
 /** Basic CAS symbol.  It has a name because it must know how to output itself.
@@ -68,7 +69,8 @@ protected:
        // non-virtual functions in this class
 public:
        void set_name(const std::string & n) { name = n; }
-       std::string get_name() const { return name; }
+       void set_TeX_name(const std::string & n) { TeX_name = n; }
+       std::string get_name() const;
        virtual unsigned get_domain() const { return domain::complex; }
 protected:
        void do_print(const print_context & c, unsigned level) const;
@@ -80,7 +82,7 @@ protected:
 
 protected:
        unsigned serial;                 ///< unique serial number for comparison
-       std::string name;                ///< printname of this symbol
+       mutable std::string name;        ///< printname of this symbol
        std::string TeX_name;            ///< LaTeX name of this symbol
 private:
        static unsigned next_serial;
@@ -107,7 +109,7 @@ public:
 GINAC_DECLARE_UNARCHIVER(realsymbol);
 
 
-/** Specialization of symbol to real domain */
+/** Specialization of symbol to real positive domain */
 class possymbol : public realsymbol
 {
 public:
@@ -123,4 +125,4 @@ GINAC_DECLARE_UNARCHIVER(possymbol);
 
 } // namespace GiNaC
 
-#endif // ndef __GINAC_SYMBOL_H__
+#endif // ndef GINAC_SYMBOL_H