
1 Dec
2009
1 Dec
'09
9:39 p.m.
On Tue, Dec 1, 2009 at 11:21 AM, David Menendez
On Tue, Dec 1, 2009 at 1:00 PM, rodrigo.bonifacio
wrote: Dear all, I wrote the following types:
class Transformation t where (<+>) :: t -> SPLModel -> InstanceModel -> InstanceModel
data Configuration = forall t . Transformation t => Configuration (FeatureExpression, [t]) type ConfigurationKnowledge = [Configuration]
I would suggest doing away with the class in a case like this. data Transformation = Transformation { (<+>) :: SPLModel -> InstanceModel -> InstanceModel } data Configuration = Configuration FeatureExpression [Transformation] I suspect that it was OO heritage that led you to want a class here? Forget that! :-) Luke