Template compilation errors with ex23.C
Kofi Deh
kdeh at coe.neu.edu
Sun Jun 29 17:00:01 EDT 2003
Hello y'all,
I get errors about template specialization after instantiation in
GARealGenome.C when compiling example 23. The full text is below. Please
let me know if you have the solution. Compiler is g++ 3.3.
Thanks,
Kofi
g++ ex23.C -lga
In file included ex23.C:16:
/usr/local/include/ga/GARealGenome.C:85: error: specialization of T
GAAlleleSet<T>::allele() const [with T = float] after instantiation
/usr/local/include/ga/GARealGenome.C:85: error: prototype for `T
GAAlleleSet<T>::allele() const [with T = float]' does not match any in
class
`GAAlleleSet<float>'
/usr/local/include/ga/GAAllele.C:231: error: candidates are: T
GAAlleleSet<T>::allele(unsigned int) const [with T = float]
/usr/local/include/ga/GAAllele.C:211: error: T
GAAlleleSet<T>::allele() const [with T = float]
/usr/local/include/ga/GARealGenome.C:85: error: `T
GAAlleleSet<T>::allele()
const [with T = float]' and `T GAAlleleSet<T>::allele() const [with T =
float]' cannot be overloaded
/usr/local/include/ga/GARealGenome.C:117: error: specialization of T
GAAlleleSet<T>::allele(unsigned int) const [with T = float] after
instantiation
/usr/local/include/ga/GARealGenome.C:117: error: prototype for `T
GAAlleleSet<T>::allele(unsigned int) const [with T = float]' does not
match
any in class `GAAlleleSet<float>'
/usr/local/include/ga/GAAllele.C:231: error: candidates are: T
GAAlleleSet<T>::allele(unsigned int) const [with T = float]
/usr/local/include/ga/GAAllele.C:211: error: T
GAAlleleSet<T>::allele() const [with T = float]
/usr/local/include/ga/GARealGenome.C:117: error: `T
GAAlleleSet<T>::allele(unsigned int) const [with T = float]' and `T
GAAlleleSet<T>::allele(unsigned int) const [with T = float]' cannot be
overloaded
He knows not how to know who knows not also how to unknow.
-- Sir Richard Burton
More information about the galib
mailing list