freepooma-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [pooma-dev] Domain traits


From: Julian Cummings
Subject: Re: [pooma-dev] Domain traits
Date: Wed, 11 Apr 2001 14:25:10 -0700

James Crotinger wrote:

> I guess that's one of the main things I hate about DomainTraits - why all the
> duplication? To me, the right way to have done this would have been for the
> default traits template to get all of its traits from the actual class (not
> the other way around, as it is now, which creates some very strange circular
> and cross dependencies), and then there would only be specializations for not
> Pooma/src/Domain classes, things like int.

The trouble is that when you "get the traits" from somewhere else,
you are in fact duplicating them.  If you write something like


template <class Dom>

struct DomainTraits {

  static const int dimensions = Dom::dimensions;

  // ...

};

then you are once again duplicating all the traits data.
Given that we cannot easily make DomainTraits go away
without a major redesign, I chose to sweep all the Domain
class traits into one place: DomainTraits.  At least that
way, the duplication issue is solved and there is one standard
way to access the traits.

> Anyway, my 2 cents is to leave the traits in the class.
>         Jim

OK, but can I commit these changes anyway??  ;-)
Seriously, I'd like to finish this and move on to other
stuff.  Unless there are technical reasons why this
would prevent new Pooma code development, break
existing code, cause a painful burning sensation, etc.,
I'd like to check in my changes later today.

Thanks, Julian C.


--
Dr. Julian C. Cummings                       E-mail: address@hidden
California Institute of Technology           Phone:  626-395-2543
1200 E. California Blvd., Mail Code 158-79   Fax:    626-584-5917
Pasadena, CA 91125



reply via email to

[Prev in Thread] Current Thread [Next in Thread]