Thanks for the suggestions. I ran a couple of tests:
my $data_list = 1..1001;
say $data_list;
produces
1..1000
real0m0.357s
user0m0.435s
sys 0m0.048s
my $data_list = 1..1001;
put $data_list;
produces the list of integers from 1 to 1001 (obviously a single string).
real
put is meant for machines, while say is meant for humans.
this is implemented by having say call the .gist method and put calling
the .Str method.
Try using say and put on a list of a thousand elements or more and
you'll see what I mean.
HTH
- Timo
On 21/10/2018 18:29, Parrot Raiser wrote:
>
What you want is OUTER ...
my $v = "original";
> {
> my $v = OUTER::<$v>;
> say $v;
> $v = "new one";
> say $v;
> }
> say $v;
It's how you access the outer scope from an inner scope.
-Scott
On Wed, Oct 3, 2018 at 1:10 AM yary wrote:
> Reading and playing with
Note that OUTER::<$v> only goes up one level.
So to go up two levels OUTER::OUTER::<$v>
There is also OUTERS::<$v> which will go up as many levels as it needs
to find the variable
{
my $a = 1;
my $b = 2;
{
my $a = 3;
{
say
Thanks! Knew I'd seen the concept of OUTER but couldn't remember the
keyword.
-y
On Wed, Oct 3, 2018 at 5:51 AM, Timo Paulssen wrote:
> you can refer to the outer $v as OUTER::('$v'), that ought to help :)
> On 03/10/2018 08:10, yary wrote:
>
> Reading and playing with
you can refer to the outer $v as OUTER::('$v'), that ought to help :)
On 03/10/2018 08:10, yary wrote:
> Reading and playing with https://docs.perl6.org/routine/temp
>
> There's an example showing how temp is "dynamic" - that any jump
> outside a block restores the value. All well and good.
>
>
yary wrote:
+1 on this
On Mon, Oct 25, 2010 at 4:56 PM, Jon Lang datawea...@gmail.com wrote:
As for the bit about sets vs. lists: personally, I'd prefer that there
not be quite as much difference between them as there currently is.
That is, I'd rather sets be usable wherever lists are called
That sounds like a subclass of Bag to me.
But I don't think that thinking about who is subclassing whom is is how to
think about this in Perl 6. All of these types are capable of doing the
Iterable role, and that is what methods that could operate on a List, Array,
Bag, or Set, should be
Sorry:
I meant capable *in theory*. It's not in the spec right now for Sets or Bags.
On Oct 25, 2010, at 08:41 PM, Mason Kramer wrote:
That sounds like a subclass of Bag to me.
But I don't think that thinking about who is subclassing whom is is how to
think about this in Perl 6. All of
Mason Kramer wrote:
But I don't think that thinking about who is subclassing whom is is how to
think about this in Perl 6. All of these types are capable of doing the
Iterable role, and that is what methods that could operate on a List, Array,
Bag, or Set, should be calling for.
This.
yary wrote:
I think of a list conceptually as a subclass of a set- a list is a
set, with indexing and ordering added. Implementation-wise I presume
they are quite different, since a set falls nicely into the keys of a
hash in therms of what you'd typically want to do with it.
If a list is a
Darren Duncan wrote:
If a list is a set, does that mean that a list only contains/returns each
element once when iterated? If a list can have duplicates, then a list
isn't a set, I would think. -- Darren Duncan
Thus Mason's point about Bags. Really, I think that Mason's right in
that we
Damian Conway wrote:
Personally, I'd prefer to see the English conventions carried over to
the use of general use of hyphen and underscore in identifiers in
the core (and everywhere else).
By that, I mean that, in English, the hyphen is notionally a
higher precedence word-separator than the
Am I the only one who sees a hyphen and thinks binary minus? Just
because the parser can disambiguate this use of it doesn't mean the
reader's brain can do so as easily.
(I assume we're talking about the same character, 0x2D, and not something
from further afield in the Unicode tables,
Peter Scott wrote:
Am I the only one who sees a hyphen and thinks binary minus? Just
because the parser can disambiguate this use of it doesn't mean the
reader's brain can do so as easily.
It's all a matter of practice.
Since variables begin with sigils, and you should put whitespace
Darren Duncan wrote:
See http://perlcabal.org/syn/S02.html#Names for your answers.
Thanks for the link but nowhere in it does it state tha Perl 6 names are
case sensitive. The best the do is this, which implies it is but
doesn't state it.
Other all-caps names are semi-reserved. We may add
On Mon, Apr 12, 2010 at 1:22 PM, Shawn H Corey shawnhco...@gmail.com wrote:
Darren Duncan wrote:
See http://perlcabal.org/syn/S02.html#Names for your answers.
Thanks for the link but nowhere in it does it state tha Perl 6 names are
case sensitive. The best the do is this, which implies it
On Sun, Apr 11, 2010 at 03:47:18PM -0700, Darren Duncan wrote:
: Damian Conway wrote:
: The relevant suggestion regarding hyphens vs underscores is:
:
: ...to allow both characters, but have them mean the same thing.
:
: That is, any isolated internal underscore can be replaced with an
:
On Mon, Apr 12, 2010 at 2:23 PM, Larry Wall la...@wall.org wrote:
On Sun, Apr 11, 2010 at 03:47:18PM -0700, Darren Duncan wrote:
:
: I see that making underscores
: and hyphens to be equivalent is akin to having case-insensitive
: identifiers, where Perl,PERL,perl mean the same thing.
On Mon, 2010-04-12 at 11:23 -0700, Larry Wall wrote:
The standard parser will likely be pointing out spelling errors and
conjecturing emendations for near misses. Whole-program analysis can
even do this for any method names that look wrongish. The difference
between Acme-X and Acme_X is no
From: Mark J. Reed [mailto:markjr...@gmail.com]
[...]
Perl borrows vocabulary almost exclusively from English, but it is
not English, and its conventions are not those of English. (And the
conventions around hyphens that people are citing are quite specifically
those of standard written
On Sun, Apr 11, 2010 at 4:47 AM, Damian Conway dam...@conway.org wrote:
And is it really so hard to teach: use underscore by default and reserve
hyphens for between a noun and its adjective? Perhaps it *is*, but
then that's a very sad reflection on our profession.
If anything, it's a sad
On Sat, Apr 10, 2010 at 5:14 AM, Mark J. Reed markjr...@gmail.com wrote:
I'd much rather see a single consistent style throughout the setting
than backwards compatibility with p5 naming conventions.
If Temporal is the first setting module to use multiword identifiers,
I vote for hyphens.
Well, if we're not going to try to implement linguistically based
hyphenation/underscoriation rules (and I'd still argue that hyphenating
adjectives to nouns and underscoring everything else isn't exactly
rocket science), then I'd suggest we reconsider a radically different
proposal that was made
On Sat, 2010-04-10 at 17:20 -0700, yary wrote:
Adjectives and nouns aren't English-only. So Damian's proposal is
multi-culti. One could argue that Perl's identifiers, keywords, etc
are based on English so that it is more difficult for a non-English
speaker to discern why underscore is used in
On Sun, Apr 11, 2010 at 10:54 AM, Damian Conway dam...@conway.org wrote:
Hyphen/underscore equivalence would allow those (apparently elite few) who
can correctly use a hyphen to correctly use the hyphen
That's about the only advantage of this scheme that I can think of.
The disadvantages, which
Egad, no to the equivalence. We'd be back in
case-insensitive-language land, only without the benefit of even that
dubious tradition.
And at least for me, the beef with mixing hyphens and underscores is
not that the great unwashed masses can't handle it, but that there
will inevitably be cases
I can't help but agree with Damian. I don't see much of a point in
making a distinction between - and _.
More specifically, if a user were to define a function (say,
i-hate-camel-case()), it would not be good to let them be the same.
Readability would suffer when examining someone's code and
Egad, no to the equivalence. We'd be back in
case-insensitive-language land, only without the benefit of even that
dubious tradition.
And at least for me, the beef with mixing hyphens and underscores is
not that the great unwashed masses can't handle it, but that there
will inevitably be cases
Damian Conway wrote:
Well, if we're not going to try to implement linguistically based
hyphenation/underscoriation rules (and I'd still argue that hyphenating
adjectives to nouns and underscoring everything else isn't exactly
rocket science), then I'd suggest we reconsider a radically different
Damian Conway wrote:
The relevant suggestion regarding hyphens vs underscores is:
...to allow both characters, but have them mean the same thing.
That is, any isolated internal underscore can be replaced with an
isolated internal hyphen (and vice versa), without changing the meaning
of the
Em Dom, 2010-04-11 às 07:54 -0700, Damian Conway escreveu:
The relevant suggestion regarding hyphens vs underscores is:
...to allow both characters, but have them mean the same thing.
er... this smells like :: and ' in Perl 5... Which, while I find
Acme::Don't amusing, cannot be stated as
On Sat, 10 Apr 2010, Mark J. Reed wrote:
I'd much rather see a single consistent style throughout the setting
than backwards compatibility with p5 naming conventions.
Ditto!
If Perl 6 style is hyphens, use hyphens everywhere. That transition from
P5 DateTime to P6 will then be a simple
${A-1} = 3.14159;
$A = $A-1;
$A = $A -1;
$A-=2;
$A = 123E-2;
$A = Pi();
$B = sin ($A-1);
$B = sin (${A}-1);
$B = sin($A -1);
-2**2 = -4 except when it comes out +4 as in MS Excel.
_2**2 = +4 in some other languages that use _ as a unary minus operator.
Will editors be bothered when I try to
Doug McNutt wrote:
${A-1} = 3.14159;
$A = $A-1;
$A = $A -1;
$A-=2;
$A = 123E-2;
$A = Pi();
$B = sin ($A-1);
$B = sin (${A}-1);
$B = sin($A -1);
-2**2 = -4 except when it comes out +4 as in MS Excel.
_2**2 = +4 in some other languages that use _ as a unary minus operator.
Will editors be
John ():
Forgive me if this is a question the reveals how poorly I've been
following Perl 6 development, but what's the deal with some methods
using hyphen-separated words (e.g., day-of-week) while others use
normal Perl method names (e.g., set_second)?
I'd just like to point out that the
I'd much rather see a single consistent style throughout the setting
than backwards compatibility with p5 naming conventions.
If Temporal is the first setting module to use multiword identifiers,
I vote for hyphens. They're easier on the fingers and the eyes;
underscores have always felt like an
On Sat, Apr 10, 2010 at 6:14 AM, Mark J. Reed markjr...@gmail.com wrote:
I'd much rather see a single consistent style throughout
Yeah, that's was my main point/question. I wanted to know if it was
it some intentional convention (e.g., all methods that change the
object state use hyphens, and
Mark (), John ():
I'd much rather see a single consistent style throughout
Yeah, that's was my main point/question. I wanted to know if it was
it some intentional convention (e.g., all methods that change the
object state use hyphens, and all others use underscores) or if it
was just
Personally, I'd prefer to see the English conventions carried over to
the use of general use of hyphen and underscore in identifiers in
the core (and everywhere else).
By that, I mean that, in English, the hyphen is notionally a
higher precedence word-separator than the space
(or than its
On Sat, Apr 10, 2010 at 5:25 PM, Damian Conway dam...@conway.org wrote:
Personally, I'd prefer to see the English conventions carried over to
the use of general use of hyphen and underscore in identifiers in
the core (and everywhere else).
That's certainly an example of how hyphens might gain
In English, hyphens normally indicate an extra level of reification, where
e.g. what is normally a phrase is used in a context that requires a single
word: The miller gave us the run of the mill. vs. It was a
run-of-the-mill event.
As such, examples like day?of?week are somewhat infelicitous, as
John Siracusa commented:
That's certainly an example of how hyphens might gain meaning in Perl
6 names, but I don't think I can endorse it as a convention. People
can't even use hyphens correctly in written English. I have very
little faith that programmers will do any better in code
But
On Sat, Apr 10, 2010 at 7:17 PM, Damian Conway dam...@conway.org wrote:
And is it really so hard to teach: use underscore by default and reserve
hyphens for between a noun and its adjective? Perhaps it *is*, but
then that's a very sad reflection on our profession.
I'm not sure if the
On Sat, Apr 10, 2010 at 4:53 PM, John Siracusa sirac...@gmail.com wrote:
I'm not sure if the intersection of people who speak English and
people who program is better or worse than average when it comes to
grammar, but I do know (from editing my share of writing) that the
average is very bad
Em Sáb, 2010-04-10 às 19:53 -0400, John Siracusa escreveu:
I'm having trouble imaging any convention that involves mixing word
separators being successful.
But the convention Damian is proposing is simply use underscores.
Basically camelCase and with_underscores are conventions on how to
On Sat, Apr 10, 2010 at 8:23 PM, Daniel Ruoso dan...@ruoso.com wrote:
Em Sáb, 2010-04-10 às 19:53 -0400, John Siracusa escreveu:
I'm having trouble imaging any convention that involves mixing word
separators being successful.
But the convention Damian is proposing is simply use underscores.
Agreed. Perl borrows vocabulary almost exclusively from English, but it is
not English, and its conventions are not those of English. (And the
conventions around hyphens that people are citing are quite specifically
those of standard written English; other writing systems, even those using
the
On 2009-Dec-3, at 8:42 pm, Jon Lang wrote:
but _can_ change existing behavior, but doesn't have to. So
with becomes the safe version of run-time composition,
guaranteeing that whatever you mix in won't disturb existing
behavior, and but becomes the unsafe version that you can fall
back
Lots of things will have default stringifications, say, that may not
always merit the contrary force of but. Maybe but should be
needed only when a method has already been mixed in anonymously.
Oops, that would wreck the canonical example of 0 but true. Since
the Bool(Int) method already
On Thu, Dec 3, 2009 at 6:38 PM, David Green david.gr...@telus.net wrote:
I'm wondering whether we can make use of the contrary sense implied by the
word but, and have it apply specifically to cases where something is being
overridden. In cases where there isn't something to override we could
David Green wrote:
I'm wondering whether we can make use of the contrary sense implied by
the word but, and have it apply specifically to cases where
something is being overridden. In cases where there isn't something
to override we could use a different word, such as with.
I must admit to
On Sun, 22 Feb 2009, Chris Dolan wrote:
Smack me down if this has already been discussed to death, please...
S16 (and now S28) say that $*DEFOUT, $*DEFIN and $*DEFERR are what most
programs should use instead of $*OUT, $*IN and $*ERR. That seems
anti-huffman to me, and I'll bet many
On 10 Aug., 00:58, [EMAIL PROTECTED] (Patrick R. Michaud) wrote:
On Fri, Aug 08, 2008 at 07:32:52AM +0200, Carl Mäsak wrote:
Jonathan ():
That this means the { $_ = uc $_; } above would end up composing a Hash
object (unless the semicolon is meant to throw a spanner in the
On Fri, Aug 08, 2008 at 07:32:52AM +0200, Carl Mäsak wrote:
Jonathan ():
That this means the { $_ = uc $_; } above would end up composing a Hash
object (unless the semicolon is meant to throw a spanner in the
hash-composer works?) It says you can use sub to disambiguate, but
%ret = map
Jonathan ():
That this means the { $_ = uc $_; } above would end up composing a Hash
object (unless the semicolon is meant to throw a spanner in the
hash-composer works?) It says you can use sub to disambiguate, but
%ret = map sub { $_ = uc $_; }, split , $text;
Doesn't work since $_ isn't
Seg, 2008-06-09 às 17:51 -0700, Larry Wall escreveu:
On Sat, Jun 07, 2008 at 09:49:03PM +0100, Daniel Ruoso wrote:
: 2) Assume the capture-translation and define that
: $foo.HOW.can($foo,'bar') keeps the $how as the invocant and must receive
: the referring object as first argument.
I prefer
On Sat, Jun 07, 2008 at 09:49:03PM +0100, Daniel Ruoso wrote:
: 2) Assume the capture-translation and define that
: $foo.HOW.can($foo,'bar') keeps the $how as the invocant and must receive
: the referring object as first argument.
I prefer this approach, I think.
Larry
Paul Fenwick pjf at perltraining.com.au writes:
for ($foo) {
when ($_ 500) { ++$_ }
when ($_ 1000) { --$_ }
default { say Just right $_ }
}
Ahh... that's exactly what I was looking for. Thanks.
Makes you wonder why the 'given' keyword was added, when
In a message dated Fri, 25 Apr 2008, Moritz Lenz writes:
Paul Fenwick pjf at perltraining.com.au writes:
for ($foo) {
when ($_ 500) { ++$_ }
when ($_ 1000) { --$_ }
default { say Just right $_ }
}
Ahh... that's exactly what I was looking for. Thanks.
AIUI, this is the difference:
given (@foo) {
# this code runs exactly once, topic is @foo
}
vs
for (@foo) {
# this code runs once per item in @foo, topic
# is @foo[0], then @foo[1], etc.
}
So eseentially,
given (@foo)
means the same as Perl5
for ([EMAIL PROTECTED])
Moritz Lenz moritz-at-casella.verplant.org |Perl 6| wrote:
Paul Fenwick pjf at perltraining.com.au writes:
for ($foo) {
when ($_ 500) { ++$_ }
when ($_ 1000) { --$_ }
default { say Just right $_ }
}
Ahh... that's exactly what I was looking for.
Trey Harris trey-at-lopsa.org |Perl 6| wrote:
In 5.10, given seems to copy its argument, whereas for aliases it. (I
haven't looked at the code; maybe it's COW-ing it.) If you add a
Csay Value is now $foo; to the end of the below program, and then
change Cfor to Cgiven and run the program
On Fri, Apr 25, 2008 at 10:39 AM, John M. Dlugosz
[EMAIL PROTECTED] wrote:
Are you saying that Perl 5.10 has given/when ?
Yes. Perl 5.10 has several Perl 6 features back-ported into it,
available via the use feature pragma: say (enables the say()
built-in), state (enables state vars), switch
HaloO,
John M. Dlugosz wrote:
for @foo {...}
is actually short for:
for @foo - $_ {...}
Ups, I missed that one. Do we also have the fill-me idiom
for @foo - $_ {...}
And again the question if this is the same as
for @foo - $_ is ref {...}
Regards, TSa.
--
The
Mark J. Reed wrote:
So eseentially,
given (@foo)
means the same as Perl5
for ([EMAIL PROTECTED])
Just wondering: should given @foo {...} alias to $_, or @_?
Dave Whipp writes:
Mark J. Reed wrote:
So eseentially,
given (@foo)
means the same as Perl5
for ([EMAIL PROTECTED])
Just wondering: should given @foo {...} alias to $_, or @_?
I'd expect it to alias to C$_, on the grounds that everything always
aliases to C$_.
What's the
Smylers wrote:
Dave Whipp writes:
So eseentially,
given (@foo)
means the same as Perl5
for ([EMAIL PROTECTED])
Just wondering: should given @foo {...} alias to $_, or @_?
I'd expect it to alias to C$_, on the grounds that everything always
aliases to C$_.
What's the argument for
The topic should always be $_ unless explicitly requested differently
via the arrow.
Now in the case of for, it might be nice if @_ bound to the entire
collection being iterated over (if any)...
TSa Thomas.Sandlass-at-barco.com |Perl 6| wrote:
HaloO,
John M. Dlugosz wrote:
for @foo {...}
is actually short for:
for @foo - $_ {...}
Ups, I missed that one. Do we also have the fill-me idiom
for @foo - $_ {...}
No. There is no concept of output parameters.
And again
Dave Whipp dave-at-whipp.name |Perl 6| wrote:
Mark J. Reed wrote:
So eseentially,
given (@foo)
means the same as Perl5
for ([EMAIL PROTECTED])
Just wondering: should given @foo {...} alias to $_, or @_?
$_. It will contain the whole list as one item, like what Perl 5 does
with
On Fri, Apr 25, 2008 at 01:19:27PM -0500, John M. Dlugosz wrote:
given @foo {
when .length 5 { say That's a long list }
when .length == Inf { say That's a very long list }
when .WHAT ~~ Range { say That's an iterator }
}
Erm, .length is dead, and .WHAT just smells
Mark J. Reed wrote:
The topic should always be $_ unless explicitly requested differently
via the arrow.
Now in the case of for, it might be nice if @_ bound to the entire
collection being iterated over (if any)...
As a perl5-ism:
sub foo { say @_; }
...
given (@bar) {
when ... { foo }
On Fri, Apr 25, 2008 at 01:05:37PM -0700, Dave Whipp wrote:
As a perl5-ism:
sub foo { say @_; }
...
given (@bar) {
when ... { foo }
}
Does perl6 still have some implicit mechanism to say call sub using
current arglist?
Yes, you can do it implicitly with one of callsame, callwith,
To loop back to my earlier question:
In Perl 5.10:
use strict;
use warnings;
use feature qw(switch say);
my $foo = 10;
for ($foo) {
when ($foo 50) { $_++ }
}
say for: $foo;
$foo = 10;
given ($foo) {
when ($foo 50) { $_++ }
}
say
Dave Whipp dave-at-whipp.name |Perl 6| wrote:
Does perl6 still have some implicit mechanism to say call sub using
current arglist?
(No, I'm not arguing to support any of this: just asking the questions)
Yes. You can use 'callsame' and it knows the current argument list.
You can get at
Larry Wall larry-at-wall.org |Perl 6| wrote:
However, foo doesn't mean what it means in Perl 5. It's just the
function as a noun rather than a verb.
Larry
A gerund.
On 6/3/07, Jonathan Lang [EMAIL PROTECTED] wrote:
Chas Owens wrote:
Jonathan Lang wrote:
Is there any reason why we can't simply define '$a x $n' as being
shorthand for 'cat($a xx $n)'? In what way does the former differ
from the latter, other than the use of a Whatever in place of $n?
Chas Owens wrote:
Jonathan Lang wrote:
Chas Owens wrote:
Jonathan Lang wrote:
Is there any reason why we can't simply define '$a x $n' as being
shorthand for 'cat($a xx $n)'? In what way does the former differ
from the latter, other than the use of a Whatever in place of $n?
$a
On 6/3/07, Jonathan Lang [EMAIL PROTECTED] wrote:
Chas Owens wrote:
Jonathan Lang wrote:
Chas Owens wrote:
Jonathan Lang wrote:
Is there any reason why we can't simply define '$a x $n' as being
shorthand for 'cat($a xx $n)'? In what way does the former differ
from the latter,
Chas Owens wrote:
I am almost certain that the following code is in list context.
pugs my @a = '-' x 5, 'foo', '-' x 5;
pugs @a
(-, foo, -)
pugs my @b = cat('-' xx 5), 'foo', cat('-' xx 5)
(-, -, -, -, -, foo, -, -, -, -, -)
However, it does seem that Pug's version of cat does not
Is item context what we're calling scalar these days, or something else?
On 6/3/07, Jonathan Lang [EMAIL PROTECTED] wrote:
Chas Owens wrote:
I am almost certain that the following code is in list context.
pugs my @a = '-' x 5, 'foo', '-' x 5;
pugs @a
(-, foo, -)
pugs my @b =
Mark J. Reed wrote:
Is item context what we're calling scalar these days, or something else?
According to S03, it does indeed appear that item context is the
current terminology for what perl 5 called scalar context:
The item contextualizer
item foo()
The new name for Perl 5's scalar
On 6/3/07, Jonathan Lang [EMAIL PROTECTED] wrote:
snip
From what you're saying, I get the impression that you think that '-'
x 5 ought to produce a single string of five dashes regardless of
whether the context is item or list. Correct? (Note: I'm not asking
about what the spec says, since
Chas Owens wrote:
The current Perl 5 behavior is
[EMAIL PROTECTED]:~$ perl -le 'my @a = (- x 5, foo, - x 5); print @a'
- foo -
[EMAIL PROTECTED]:~$ perl -le 'my @a = ((-) x 5, foo, (-) x 5); print
@a'
- - - - - foo - - - - -
I am against anything other than that for x or xx without a
On 6/2/07, Jonathan Lang [EMAIL PROTECTED] wrote:
Is there any reason why we can't simply define '$a x $n' as being
shorthand for 'cat($a xx $n)'? In what way does the former differ
from the latter, other than the use of a Whatever in place of $n?
--
Jonathan Dataweaver Lang
$a x $n is
Chas Owens wrote:
Jonathan Lang wrote:
Is there any reason why we can't simply define '$a x $n' as being
shorthand for 'cat($a xx $n)'? In what way does the former differ
from the latter, other than the use of a Whatever in place of $n?
$a x $n is equivalent to join '', $a xx $n, but that
Aaron Sherman wrote:
It seems to me that there are three core attributes, each of which has
two states:
Mutability: true, false
Laziness: true, false
Ordered: true, false
I think there's a 4th: exclusivity: whether or not duplicate elements
are permitted/exposed (i.e. the
Aaron Sherman wrote:
Carried over form IRC to placeholder the conversation as I saw it:
We define the following in S06 as immutable types:
ListLazy Perl list (composed of Seq and Range parts)
Seq Completely evaluated (hence immutable) sequence
Range
David Brunton wrote:
Aaron Sherman wrote: replies snipped /
IMHO, the golden rule of programming languages should be: if you
need a namespace, create one.
Is there any reason these meta methods could not be part of some
default function package like Math::Basic and Math::Trig? The
package
Jonathan Scott Duff wrote:
On Wed, Sep 13, 2006 at 10:20:31AM +1200, Sam Vilain wrote:
Larry Wall wrote:
.META is more correct at the moment.
Does making it all upper caps really help? It's still a pollution of the
method space, any way that you look at it...
Yeah but perl has already
Aaron Sherman wrote:
replies snipped /
Is the goal to avoid namespace pollution? If so, shouldn't there be a
truly metaish way of getting at the internal namespace so that someone
doesn't accidentally render an object unusable by defining the wrong
method name (which you can prevent with an
Larry Wall wrote:
: There is currently a mismatch between S12 and Pugs. The former specifies
$obj.META, the latter has implemented $obj.meta.
.META is more correct at the moment.
Does making it all upper caps really help? It's still a pollution of the
method space, any way that you look
On Wed, Sep 13, 2006 at 10:20:31AM +1200, Sam Vilain wrote:
Larry Wall wrote:
: There is currently a mismatch between S12 and Pugs. The former specifies
$obj.META, the latter has implemented $obj.meta.
.META is more correct at the moment.
Does making it all upper caps really
On Mon, Sep 11, 2006 at 08:59:51AM -0700, David Brunton wrote:
: Hi all,
:
: There is currently a mismatch between S12 and Pugs. The former specifies
$obj.META, the latter has implemented $obj.meta.
.META is more correct at the moment.
: Is there any reason I shouldn't change the tests from
On 9/11/06, Larry Wall wrote:
Only that I'm thinking of renaming all the meta-ish methods to use
interrogative pronouns:
.META- .HOW
.SKID- .WHO
.PKG - .WHAT
.VAR - .WHERE
.WHO and .WHAT strike me as better being swapped. Maybe...
or some such. Not sure
On Mon, Sep 11, 2006 at 10:59:20AM -0600, David Green wrote:
: In that case, .WHO definitely makes more sense for the name.
I don't see it. Who I am is my identity. What I am is a Person or some such.
Larry
On Mon, Sep 11, 2006 at 09:18:19AM -0700, Larry Wall wrote:
: .PKG - .WHAT
I should have said
.ref- .WHAT
there, since it was the intention to rename .ref that brought all this
on in the first place. (And what you actually get from .WHAT is the
prototype object
On Sat, Jul 08, 2006 at 07:42:06AM -0700, Jonathan Lang wrote:
: Is there anything that you can do with a sub (first parameter being
: some sort of object) that you cannot do with a method? Frex, given:
:
: multi method my_method($invocant:);
:
: would
:
: topical_call := my_method.assuming
On 5/23/06, Sam Vilain [EMAIL PROTECTED] wrote:
Right, but we should really ship with at least a set of Meta Object
Protocol Roles, that covers the core requirements that we will need for
expressing the core types in terms of themselves;
- classes and roles
- attributes and methods
- subsets
1 - 100 of 332 matches
Mail list logo