X-Git-Url: https://ginac.de/ginac.git/static/gitweb.css/ginac.git?a=blobdiff_plain;f=ginac%2Fpseries.h;h=26c27306250a03a03177764962efc32734349cfc;hb=06e1c4cc6967333ae1597d5e08dd1865ba64c1b2;hp=bd2db158baad17a1aabc73319b4ce312aba4fb27;hpb=0cf43f3096cbcfc7472ff9c8927c6eb74f2eeb8c;p=ginac.git diff --git a/ginac/pseries.h b/ginac/pseries.h index bd2db158..26c27306 100644 --- a/ginac/pseries.h +++ b/ginac/pseries.h @@ -3,7 +3,7 @@ * Interface to class for extended truncated power series. */ /* - * GiNaC Copyright (C) 1999-2001 Johannes Gutenberg University Mainz, Germany + * GiNaC Copyright (C) 1999-2003 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 @@ -101,17 +101,8 @@ protected: ex point; }; -/** Return a reference to the pseries object embedded in an expression. - * The result is undefined if the expression does not contain a pseries - * object at its top level. - * - * @param e expression - * @return reference to pseries object - * @see is_a<> */ -inline const pseries &ex_to_pseries(const ex &e) -{ - return static_cast(*e.bp); -} + +// utility functions /** Specialization of is_exactly_a(obj) for pseries objects. */ template<> inline bool is_exactly_a(const basic & obj) @@ -129,7 +120,7 @@ template<> inline bool is_exactly_a(const basic & obj) * @see pseries::convert_to_poly */ inline ex series_to_poly(const ex &e) { - return (static_cast(*e.bp).convert_to_poly(true)); + return (ex_to(e).convert_to_poly(true)); } inline bool is_terminating(const pseries & s)