Mention is made of a typed undef in A12:
A12
which doesn't quite work, because $spot is undefined. What probably happens
is that the my cheats and puts a version of undef in there that knows it
should dispatch to the Dog class if you call .self:new() on it. Anyway,
we'll make it work one way or
Austin Hastings skribis 2004-04-23 13:33 (-0400):
I should then be able to call class methods of Dog via $spot without further
initialization:
print defined($spot); # FALSE
$rover = $spot.new;
@breeds = $spot.list_breeds;
But shouldn't you then just use my Class $spot = Dog then? Or
Juerd writes:
Austin Hastings skribis 2004-04-23 13:33 (-0400):
I should then be able to call class methods of Dog via $spot without further
initialization:
print defined($spot); # FALSE
$rover = $spot.new;
@breeds = $spot.list_breeds;
But shouldn't you then just use my Class
[EMAIL PROTECTED] (Austin Hastings) writes:
A12
which doesn't quite work, because $spot is undefined. What probably happens
is that the my cheats and puts a version of undef in there that knows it
should dispatch to the Dog class if you call .self:new() on it. Anyway,
we'll make it work one
Interestingly, the opaque shortcut used to be
$class.bless(undef, *%_);
But I made it 0 instead merely because it's shorter. That does, however,
free up undef as a way of asking for an explicitly undefined but
blessed value.
: There are potentially two flavors of undef:
:
: undef
:
:
-Original Message-
From: Juerd [mailto:[EMAIL PROTECTED]
Austin Hastings skribis 2004-04-23 13:33 (-0400):
I should then be able to call class methods of Dog via $spot
without further initialization:
print defined($spot); # FALSE
$rover = $spot.new;
@breeds =
-Original Message-
From: Larry Wall [mailto:[EMAIL PROTECTED]
Interestingly, the opaque shortcut used to be
$class.bless(undef, *%_);
But I made it 0 instead merely because it's shorter. That does, however,
free up undef as a way of asking for an explicitly undefined but
On Fri, Apr 23, 2004 at 02:50:42PM -0400, Austin Hastings wrote:
: Sure, but You haven't provided a value yet. doesn't seem very ...
: exceptional.
The important thing will be You didn't provide a value at line 42, though
you didn't actually try to use it till line 582.
: Sure -- the class of
-Original Message-
From: Larry Wall [mailto:[EMAIL PROTECTED]
On Fri, Apr 23, 2004 at 02:50:42PM -0400, Austin Hastings wrote:
: Sure, but You haven't provided a value yet. doesn't seem very ...
: exceptional.
The important thing will be You didn't provide a value at line 42,
On Fri, Apr 23, 2004 at 03:18:22PM -0400, Austin Hastings wrote:
: -Original Message-
: From: Larry Wall [mailto:[EMAIL PROTECTED]
:
: On Fri, Apr 23, 2004 at 02:50:42PM -0400, Austin Hastings wrote:
: : Sure, but You haven't provided a value yet. doesn't seem very ...
: :
Larry Wall [EMAIL PROTECTED] wrote in message
news:[EMAIL PROTECTED]
On Fri, Apr 23, 2004 at 02:50:42PM -0400, Austin Hastings wrote:
: Sure, but You haven't provided a value yet. doesn't seem very ...
: exceptional.
The important thing will be You didn't provide a value at line 42, though
On Fri, 2004-04-23 at 15:46, Dave Whipp wrote:
Just wondering, are we going to have semantics similar to the old NaN Vs
Signaling-Nan in IEEE floating point? An IEE NaN has an N-bit field where
the source of the NaN can place a value representing the reason for the NaN.
It can also set a flag
On Fri, Apr 23, 2004 at 12:46:07PM -0700, Dave Whipp wrote:
: I'm not sure how much of this is relevant to Cundef, but it might be nice
: to have the ability to have an undef that says if used, then trap (using
: the current use fail mode -- if that still exists)
I suppose one could give a typed
13 matches
Mail list logo