On 9/25/05, Yuval Kogman [EMAIL PROTECTED] wrote:
In order to enforce that level of compile-time type safely, you should
need to declare my Dog $dog, or stick a pragma up top:
That's the point of my question - why? What do I lose by
inferrencing?
Nothing that I see. I recant my arguments
On Sun, Sep 25, 2005 at 08:29:07PM +0300, Yuval Kogman wrote:
: Is there any situation where a compile time error is not a good
: thing to have?
Sure, when it slows down your compiler so much that it's useless for
running code that doesn't have the error, especially if it's a rare
error that is
On Mon, Sep 26, 2005 at 17:36:04 -0700, Larry Wall wrote:
Sure, when it slows down your compiler so much that it's useless for
running code that doesn't have the error, especially if it's a rare
error that is likely to be caught some other way anyway. Where to
balance this should be the
On 9/25/05, Yuval Kogman [EMAIL PROTECTED] wrote:
Hmm... Making up these subjects is fun =)
Very interesting. :)
Under strict type inferrencing, i'd expect this to be a compile time
error:
my $dog = Dog.new;
if ($condition) {
my Cat $c = $dog;
}
On 9/25/05, Ashley Winters [EMAIL PROTECTED] wrote:
On 9/25/05, Yuval Kogman [EMAIL PROTECTED] wrote:
Under strict type inferrencing, i'd expect this to be a compile time
error:
I quoted but didn't read close enough. You DID say strict type
inferencing. Never mind. :)
Ashley Winters
On Sun, Sep 25, 2005 at 11:24:05 -0700, Ashley Winters wrote:
I can't accept that. While you can infer that $dog will be a Dog at
that line of code, it isn't being enforced, which means no
compile-time error. $dog is allowed to store any kind of data, and you
only know what methods exist in