On Dec 29, 2010, at 9:32 AM, Hans Dieter Pearcey wrote:
On Wed, 29 Dec 2010 01:24:47 -0800 (PST), Ovid <publiustemp-catal...@yahoo.com
> wrote:
https://github.com/Ovid/Role-Basic
http://search.cpan.org/dist/Role-Basic/
This means that if a class consuming a role has a method with the
same name
the role provides, the class silently wins. This has been a somewhat
contentious issue in the Moose community and the "silent" behaviour
has won.
You're making this sound like a much bigger deal than it was. Most
of the
discussion wasn't about whether or not it should happen silently; it
was about
how, since it *should* happen silently, we could let people detect
these method
overrides if they wanted to (e.g. when refactoring a large class
hierarchy).
Everything else seems reasonable. I agree with the safety-related
design
choices you've made, in particular 'composition safety', 'no instance
application', and 'no method modifiers' (even though I find this
last one very
useful in Moose).
Yeah, pretty much what Dieter said, especially the part about making
the "silent" issue too big of a deal. I think you are
mischaracterizing it, it was discussed heavily and I don't think
anyone really said "no you can't do/have that", but only "no you can't
do/have that in core by default". A lot of this also came down to
backwards compat (Moose was already a couple years old and running
many prod systems when you first started using it) and the fact that
there was no clear majority opinion (meaning, both sides were
essentially correct in their own ways). In those cases, as has
happened many times before, it must become a MooseX:: module and we do
all we can to help make that MooseX:: module possible in the core Moose.
Additionally, to Dr. Black's comment ... Smalltalk development is
pretty much unique in the world of programming languages (with the
possible exception of Self and some versions of Forth), always having
such close access to the code and pretty much no division between the
runtime environment and the development environment. So in a world
like that, sure they can make it really easy for the trait composition
to not be silent, but the warnings to not be intrusive. But outside of
that type of image based environment and in a real-world situation
where people's error.log files are constrained by available disk
space, I don't think it is that simple.
- Stevan