]> www.ginac.de Git - ginac.git/commit
calchash(): use type_info::name() instead of tinfo().
authorAlexei Sheplyakov <varg@theor.jinr.ru>
Wed, 15 Oct 2008 11:32:11 +0000 (15:32 +0400)
committerAlexei Sheplyakov <varg@theor.jinr.ru>
Sun, 19 Oct 2008 17:29:11 +0000 (21:29 +0400)
commitb573b0146341709649f373e0fc5c0d440877ebaf
tree349db11687b7a7b970720d00c519b9e663151513
parente858ebe524f9beac33d492b9a4e614666819c3ab
calchash(): use type_info::name() instead of tinfo().

Custom RTTI considered harmful, part 4.

The hash value of the object of different types should be different whenever
possible. Hence calcash() needs a unique per type number. Previously we used
tinfo_key for this. typeinfo::name() (a *pointer* to implementation dependent
string) is also unique for each class, so it's just as good as tinfo() is.
ginac/basic.cpp
ginac/constant.cpp
ginac/expairseq.cpp
ginac/function.pl
ginac/idx.cpp
ginac/relational.cpp
ginac/symbol.cpp
ginac/symmetry.cpp
ginac/wildcard.cpp