Re: Type::Class::Haskell does Role

2005-07-17 Thread Luke Palmer
On 7/17/05, Yuval Kogman [EMAIL PROTECTED] wrote: I have another view. The Num role and the Str role both consume the Eq role. When your class tries to both be a Num and a Str, == conflicts. I have two scenarios: class Moose does Num does Str { ... } # Moose was

The Use and Abuse of Liskov (was: Type::Class::Haskell does Role)

2005-07-17 Thread Damian Conway
You keep using that word. I do not think it means what you think it means -- Inigo Montoya Luke Palmer wrote: Recently I discussed MMD with chromatic, and he mentioned two things that were very important, in my opinion: * The Liskov substitution

Database Transactions and STM [was: Re: STM semantics, the Transactional role]

2005-07-17 Thread Sam Vilain
Yuval Kogman wrote: everyone gets to choose, and another thing I have in mind is the Transactional role... DBI::Handle does Transactional; To the STM rollbacker and type checker thingy this means that any IO performed by DBI::Handle invoked code is OK - it can be reversed using the

Do I need has $.foo; for accessor-only virtual attributes?

2005-07-17 Thread Sam Vilain
Say I make an accessor method for an attribute that doesn't really 'exist'. For instance, a good example of this is the month_0 vs month properties on a date object; I want to make both look equivalent as real properties, but without the users of the class knowing which one is the real one.