[GiNaC-list] Problem using a user-defined class on Mac OS X.
David Fang
fang at csl.cornell.edu
Wed Apr 4 01:42:46 CEST 2007
> On Tue, Apr 03, 2007 at 11:27:54AM +0200, Chris.Dams at mi.infn.it wrote:
>
> > > I seem to be having a problem [...] the static member
> > > class_info<registered_class_options>::first is (besides inside the GiNaC
> > > dynamic library) also created within my executable.
> >
> > I now solved this by creating a file class_info.cpp (given below).
>
> Interesting. There are
>
> template <class OPT> class_info<OPT> *class_info<OPT>::first = NULL;
> template <class OPT> bool class_info<OPT>::parents_identified = false;
>
> in class_info.h. So I wonder why explicit specialization makes any
> difference...
>
> > Shall I add this file to the CVS?
>
> I think we should understand how it works first.
Hi,
I may be jumping in a bit late, and without having looked through the
source, but are we looking at a violation of the basic one-definition-rule
(ODR)? whereby a specialization is providing a definition that is
otherwise expected from a primary template? (For the record, which version
are we looking at, so I may check it out?)
Fang
David Fang
Computer Systems Laboratory
Electrical & Computer Engineering
Cornell University
http://www.csl.cornell.edu/~fang/
-- (2400 baud? Netscape 3.0?? lynx??? No problem!)
More information about the GiNaC-list
mailing list