Re: "temp" vs "my"

2018-10-05 Thread Jonathan Scott Duff
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 https://docs.p

Re: using run

2018-06-20 Thread Jonathan Scott Duff
If you don't specify the :out adverb, then the output of the program you are running will be sent to standard output. Immediately when the program executes. If you specify the :out adverb, output from the program will be available for capture via the $proc.out method. A similar thing applies for

Re: need s/ help

2018-05-01 Thread Jonathan Scott Duff
On Tue, May 1, 2018 at 8:37 AM, ToddAndMargo wrote: > Hi All, > > I am trying to change the last three letters of a string > > $ perl6 -e 'my $x="abcabcabc"; $x ~~ s/"a.*"$/xyz/; say $x;' > The double quotes around your text make it a string literal, so it will only match the literal string "a.*

Re: Does words have a delimiter?

2018-04-13 Thread Jonathan Scott Duff
Looking at that page myself, it doesn't appear that you can specify the separator for .words. So ... no. Though, that would make an interesting addition IMHO -Scott On Sat, Apr 14, 2018 at 12:27 AM, ToddAndMargo wrote: > Hi All, > > I am over on > https://docs.perl6.org/routine/words > an

Re: [perl #131781] :?smth should construct a truthy pair (say (:?foo))

2017-07-24 Thread Jonathan Scott Duff via RT
The OP said :?foo should work because :foo and :!foo work. I don't follow the logic. How are those things related? Why should :foo and :!foo imply :?foo? (In my head it makes as much sense as ":foo and :!foo implies :*foo", which is to say, none.) I don't see any benefit to adding a :?foo synt

Re: [perl #131781] :?smth should construct a truthy pair (say (:?foo))

2017-07-22 Thread Jonathan Scott Duff
The OP said :?foo should work because :foo and :!foo work. I don't follow the logic. How are those things related? Why should :foo and :!foo imply :?foo? (In my head it makes as much sense as ":foo and :!foo implies :*foo", which is to say, none.) I don't see any benefit to adding a :?foo synt

Re: learning perl6?

2016-01-04 Thread Jonathan Scott Duff
If, by "regular book", you mean "bound paper sheafs with ink on them", then the answer is currently "no". Is there something wrong with the documentation online? (besides there not being enough of it :) -Scott On Mon, Jan 4, 2016 at 9:55 PM, Yonghua Peng wrote: > Hello, > > Is there a regular

Re: grep changes?

2015-10-05 Thread Jonathan Scott Duff
The block does get the topic, but the regex isn't executing immediately. Another way to get what you want, rather than mentioning the topic explicitly, is to use the m// form of match. > grep { m/\.pl6/ }, (a.pl6) For sanity's sake, I would recommend writing your match-immediately regex like th

Re: Strict Rakudo version of this Perl5 one-liner

2015-09-01 Thread Jonathan Scott Duff
If you're not married to the "key : value" format, you could use this: scan +spam | perl6 -ne 'my %d; %d{.words[1]}++; END { .say for sort %d }' Here's another variation, but keeping your original format: scan +spam | perl6 -ne 'my %d; %d{.words[1]}++; END { say "$_.key() : $_.value()"

Re: [perl #118865] Parameter '' requires an instance, LTA error

2015-03-12 Thread Jonathan Scott Duff
IMHO, the message is actually slightly worse. Now it's talking about an invocant when there are no classes or methods involved! -Scott On Wed, Mar 11, 2015 at 1:26 PM, Christian Bartolomaeus via RT < bugs-comm...@bugs6.perl.org> wrote: > The error message has changed slightly and now states th

Announce: Rakudo Compiler Release #81 ("Linz")

2014-10-24 Thread Jonathan Scott Duff
ell as those people who worked on Parrot, the Perl 6 test suite, MoarVM and the specification. The following people contributed to this release: Elizabeth Mattijsen, Jonathan Worthington, Tobias Leich, Moritz Lenz, Jonathan Scott Duff, Christian Bartolomäus, Brad Gilbert, Solomon Foster, Lar

Re: s:g/T/U/ doesn't work ?

2012-10-24 Thread Jonathan Scott Duff
I imagine it's the same problem as this Perl 5 code: use Test::More; for ('GATGGAACTTGACTACGTAAATT') { s/T/U/g; is $_, 'GAUGGAACUUGACUACGUAAAUU', 'RNA'; } Since $_ is an alias for each element of the list and the only element in the list is a constant string and you can't modify constan

Announce: Rakudo Perl 6 compiler development release #57 ("Tokyo")

2012-10-18 Thread Jonathan Scott Duff
On behalf of the Rakudo development team, I'm thrilled to announce the October 2012 release of Rakudo Perl #57 "Tokyo". Rakudo is an implementation of Perl 6 on the Parrot Virtual Machine (see ). The tarball for this release is available from

[Announce] Rakudo 2012.06 "Strasbourg"

2012-06-21 Thread Jonathan Scott Duff
The following people contributed to this release: Contributors to Rakudo since the release on 2012-05-17: Moritz Lenz, Jonathan Worthington, Patrick R. Michaud, kboga, Jonathan Scott Duff, Tadeusz Sośnierz, Carl Masak, Geoffrey Broadwell, diakopter, Solomon Foster, JimmyZ, TimToady If you would like

Announce: Rakudo Perl 6 compiler development release #45 ("Houston")

2011-10-21 Thread Jonathan Scott Duff
ot, the Perl 6 test suite and the specification. The following people contributed to this release: Jonathan Worthington, Moritz Lenz, Will "Coke" Coleda, Tadeusz Sośnierz, Patrick R. Michaud, Jonathan Scott Duff, Carl Masak, Geoffrey Broadwell, mls, snarkyboojum, gfldex, TimToady, TiMBuS,

Re: Current vs future Perl 6 binary size

2011-04-21 Thread Jonathan Scott Duff
On Thu, Apr 21, 2011 at 6:33 PM, gvim wrote: > This is not a criticism of anything. I am not a core developer but need to > be aware of what to expect when Perl 6 settles down into a production-ready > state. The Perl 6 binary within the January release of Rakudo Star is 10Mb > on my Snow Leopard

Announce: Rakudo Perl 6 compiler development release #40 ("ZA")

2011-04-21 Thread Jonathan Scott Duff
e following people contributed to this release: Moritz Lenz, Tadeusz Sośnierz, Martin Berends, Andy Lester, Jonathan Scott Duff, flussence, Patrick Abi Salloum, Carl Masak, Jarrod If you would like to contribute, see <http://rakudo.org/how-to-help>, ask on the perl6-compi...@perl.org mailing list,

Announce: Rakudo Perl 6 compiler development release #34 ("Paris")

2010-10-22 Thread Jonathan Scott Duff
Jonathan Worthington, TimToady, TimTom, PhatEddy, Patrick Abi Salloum, and your humble release manager Jonathan Scott Duff. If you would like to contribute, see <http://rakudo.org/how-to-help>, ask on the perl6-compi...@perl.org mailing list, or ask on IRC #perl6 on freenode. The next release

Re: Performance: ... vs ..

2010-08-04 Thread Jonathan Scott Duff
On Tue, Aug 3, 2010 at 1:18 AM, Aaron Sherman wrote: > I know that Rakudo isn't well tuned for performance right now, but this is > still probably worth noting because it's such a specific difference between > two similar ways of doing one task. > > The recent thread about "..." and ".." had me d

Re: r31627 -[S32/Temporal] Changed to use a different way of specifying time zones, which is hopefully saner than my last proposal.

2010-07-12 Thread Jonathan Scott Duff
On Sun, Jul 11, 2010 at 12:56 PM, wrote: > Author: Kodi > Date: 2010-07-11 19:56:33 +0200 (Sun, 11 Jul 2010) > New Revision: 31627 > > Modified: > docs/Perl6/Spec/S32-setting-library/Temporal.pod > Log: > [S32/Temporal] Changed to use a different way of specifying time zones, > which is hopeful

Re: underscores vs hyphens (was Re: A new era for Temporal)

2010-04-11 Thread Jonathan Scott Duff
On Sat, Apr 10, 2010 at 5:14 AM, Mark J. Reed 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. As another data

Re: Custom errors on subsets?

2010-01-05 Thread Jonathan Scott Duff
erplate every time a constraint fails. Plus, the code is friendlier :) > I'd imagine that the functionality will fall out of the ability to have nice failures because surely something like the following works now: subset Filename of Str where { $_ ~~ :f or fail "No such file: '$_'" } Perhaps s/fail/die/, but that seems like a means to your desired end. -Scott -- Jonathan Scott Duff perlpi...@gmail.com

Rakudo Perl 6 development release #22 ("Thousand Oaks")

2009-10-22 Thread Jonathan Scott Duff
and codenames for 2009 is available in the "docs/release_guide.pod" file. In general, Rakudo development releases are scheduled to occur two days after each Parrot monthly release. Parrot releases the third Tuesday of each month. Have fun! -Scott -- Jonathan Scott Duff perlpi...@gmail.com

Re: [perl #68876] issues with 3.. and ..3 in regular expression...

2009-08-31 Thread Jonathan Scott Duff
leave it out. And to get any number as the end of the range use the Whatever *. -Scott -- Jonathan Scott Duff perlpi...@gmail.com

Re: Re-thinking file test operations

2009-07-10 Thread Jonathan Scott Duff
On Thu, Jul 9, 2009 at 7:50 PM, Aristotle Pagaltzis wrote: > * Moritz Lenz [2009-07-10 00:25]: > > stat($str, :e)# let multi dispatch handle it for us > > This gets my vote. Me too. -Scott -- Jonathan Scott Duff perlpi...@gmail.com

Re: [perl #66250] Trouble with white space in Rakudo grammars

2009-06-05 Thread Jonathan Scott Duff
the significant whitespace in your second example ate all of the spaces in your string leaving no spaces for ' b' to match. A similar thing happens with your third example; there is nothing for to match (though I haven't looked at the spec, so I'm not entirely sure what should match) -Scott -- Jonathan Scott Duff perlpi...@gmail.com

Re: New CPAN

2009-05-29 Thread Jonathan Scott Duff
the same program!). >> > > Why? > See http://perlcabal.org/syn/S11.html#Versioning -Scott -- Jonathan Scott Duff perlpi...@gmail.com

Re: Unexpected behaviour with @foo.elems

2009-05-27 Thread Jonathan Scott Duff
hing($k, $v) } > > I think the anti-pattern of "0...@foo.elems" (or its incorrect > form "0...@foo.elems") should probably disappear in favor of > the above forms instead. Or perhaps for 0...@foo.end -> $k { ... } @foo.keys may not be what the user wanted if @foo is a sparse array. -Scott -- Jonathan Scott Duff perlpi...@gmail.com

[perl #65224] class name as string unexpectedly "works"

2009-04-29 Thread Jonathan Scott Duff
# New Ticket Created by "Jonathan Scott Duff" # Please include the string: [perl #65224] # in the subject line of all future correspondence about this issue. # http://rt.perl.org/rt3/Ticket/Display.html?id=65224 > < PerlJam> rakudo: class Foo { }; my $x = "Foo";

Re: [perl #64062] split should return captured delimiters

2009-03-27 Thread Jonathan Scott Duff
he regex depending on how you look at things). Also, setting the limit parameter to 5 seems fairly useless in the example because there's only 5 things to split to begin with. Usually the limit comes in to play when your string contains more pieces that are potentially splittable on your delimiter than what you want. For instance, if the string were "abc::def::ghi::jkl", @split would contain ("abc",":","",":","def",":","",":","ghi::jkl") -Scott -- Jonathan Scott Duff d...@lighthouse.tamucc.edu

Re: Some setting candidates

2009-03-11 Thread Jonathan Scott Duff
://wiki.github.com/rakudo/rakudo/setting-candidates > > See also the file "docs/guide_to_setting.pod" in the Rakudo > repository. > > At present I'm still heavily favoring patches submitted via > RT over those submitted via the fork queue on github. > > Pm > -- Jonathan Scott Duff perlpi...@gmail.com

Re: Git workflow

2009-03-10 Thread Jonathan Scott Duff
at could each probably stand on their own (though there may be some dependency ordering). And there shouldn't be any spurious or throw-away commit messages like "Oops, forgot to twiddle the frobnitz in the previous commit" Just my humble opinion, -Scott -- Jonathan Scott Duff d...@lighthouse.tamucc.edu

Re: Programmatic REPL history/result access?

2009-02-04 Thread Jonathan Scott Duff
uage, or something that would better be provided > by a tool external to the language itself? Sounds usefulish for the perl 6 REPL. But not so much for "ordinary" programming. So, given that, I'd say an external tool (module) is the way to go. -Scott -- Jonathan Scott Duff d...@lighthouse.tamucc.edu

Re: Rakudo repository -- svn or git?

2009-01-27 Thread Jonathan Scott Duff
e. It seems to have the perl-nature of TMTOWTDI and the idea of "many histories" (as contrasted with svn's linear history), seems to be more the way the world really works. okay, I'll shut up now except to say this: I prefer git :-) -Scott -- Jonathan Scott Duff perlpi...@gmail.com

Re: design of the Prelude (was Re: Rakudo leaving the Parrot nest)

2009-01-16 Thread Jonathan Scott Duff
the language you're trying to bootstrap as much as possible with just a few primitives to get things started. -Scott -- Jonathan Scott Duff perlpi...@gmail.com

Re: [PATCH] Add .trim method

2009-01-12 Thread Jonathan Scott Duff
>) could all > $string.rtrim internally. > If I were going to have ltrim() and rtrim(), I'd implement them in terms of trim() rather than the other way around. -Scott -- Jonathan Scott Duff perlpi...@gmail.com

Re: [perl #62116] no interpolation into string of array element

2009-01-09 Thread Jonathan Scott Duff
renthesized method call, followed by any of 1 through 5 =back In other words, this is legal: "Val = $a.ord.fmt('%x')\n" and is equivalent to "Val = { $a.ord.fmt('%x') }\n" So, it would seem that my @x = 1, 2, 3; say "2nd is @x[1]"; # 2nd is 2 is perfectly valid perl 6. -Scott -- Jonathan Scott Duff perlpi...@gmail.com

Re: Regex - Accessing captured subrules could be problematic

2008-12-04 Thread Jonathan Scott Duff
t where whitespace has meaning (e.g. :sigspace is in effect), but you don't want the significant whitespace, you can turn that off temporarily (or again, use some other technique). HTH, -Scott -- Jonathan Scott Duff [EMAIL PROTECTED]

Re: Split with negative limits, and other weirdnesses

2008-09-24 Thread Jonathan Scott Duff
e zero and use a name like UInt that has other uses as well. Are > there pragmas that turn signature failures into undef return values? > > > Regards, TSa. > -- > > "The unavoidable price of reliability is simplicity" -- C.A.R. Hoare > "Simplicity does not precede complexity, but follows it." -- A.J. Perlis > 1 + 2 + 3 + 4 + ... = -1/12 -- Srinivasa Ramanujan > my two cents, -Scott -- Jonathan Scott Duff [EMAIL PROTECTED]

Re: method signature issues

2008-09-21 Thread Jonathan Scott Duff
cs. I >> didn't say they don't work together in some cases with our current >> implementation. (They probably shouldn't.) >> >> >> > They probably should. If they didn't, then how would multi-methods then be > possible? These dispatch first on t

PCT patch

2008-04-17 Thread Jonathan Scott Duff
d the patch though. -Scott -- Jonathan Scott Duff [EMAIL PROTECTED] diff --git a/compilers/pct/src/PCT/HLLCompiler.pir b/compilers/pct/src/PCT/HLLCompiler.pir index 13164ed..1a529a0 100644 --- a/compilers/pct/src/PCT/HLLCompiler.pir +++ b/compilers/pct/src/PCT/HLLCompiler.pir @@ -458,6 +458,14

Re: muse on Compact Structs, pack/unpack

2008-04-03 Thread Jonathan Scott Duff
on's Law > > But yes, it might be about time for hypertexting it. All but S03 have > never really undergone a major reorg, and most of them could use it. > Maybe it's time to set up Twiki on my home machine... > > Larry > -- Jonathan Scott Duff [EMAIL PROTECTED]

[perl #51838] [BUG] cygwin build fails

2008-03-18 Thread Jonathan Scott Duff
# New Ticket Created by "Jonathan Scott Duff" # Please include the string: [perl #51838] # in the subject line of all future correspondence about this issue. # http://rt.perl.org/rt3/Ticket/Display.html?id=51838 > --- osname= cygwin osvers= 1.5.24(0.15642) arch= cygwin-threa

Re: Perl6::Doc # Hail to the new pharao

2007-12-29 Thread Jonathan Scott Duff
You have my permission as well. -Scott On Dec 29, 2007 7:04 AM, herbert breunung <[EMAIL PROTECTED]> wrote: > thanks to chromatic, so i have ask Jonathan Scott Duff, Phil Crow and > wait for /Adrianos answer. > > what i yesterday also forgot to mention is that rumor says

Re: Concerns about "{...code...}"

2007-12-20 Thread Jonathan Scott Duff
On Thu, Dec 20, 2007 at 11:23:05AM -0600, Jonathan Scott Duff wrote: > Adriano answered #1 I think: $yaml = Q:!c"{ $key: 42 }"; Er, I just looked over the spec again and realized that Q does absolutely no interpolation, so it would be more like this: $yaml = Q:qq:!c"

Re: Concerns about "{...code...}"

2007-12-20 Thread Jonathan Scott Duff
d be persuaded to make them non-interpolative by default. (i.e., the adverb would be required to make them interpolate) -Scott -- Jonathan Scott Duff <[EMAIL PROTECTED]>

[PATCH] [NQP] Use || in places where order matters

2007-12-09 Thread Jonathan Scott Duff
I understand that | and || may not actually be differentiated in implementation yet, but they do different things according to the spec. I've attached a patch for NQP to change | to || in places where I think it matters. -Scott -- Jonathan Scott Duff [EMAIL PROTECTED] nqp.patch Descri

Re: parentheses and context (was Re: state and START)

2007-11-15 Thread Jonathan Scott Duff
o() looks like it's always in list context, but as far as START goes, I'd think the first two call foo() only once while the third calls it every time (just as you have it written). Now, someone tell me if I'm right or wrong and why :-) Nicholas Clark > -Scott -- Jonathan Scott Duff [EMAIL PROTECTED]

&, &&, and backtracking.

2007-09-06 Thread Jonathan Scott Duff
termine that the conjunctions can't match the same portion of the string) Or it's much simpler than that and both of the regexes above just fail because of the greediness of C<+> and there is no intra-conjunction backtracking. So ... anyone care to enlighten me on how this is supposed to work? Thanks, -Scott -- Jonathan Scott Duff [EMAIL PROTECTED]

Re: [svn:perl6-synopsis] r14421 - doc/trunk/design/syn

2007-06-16 Thread Jonathan Scott Duff
Also, I don't think that documentation is being treated as second-class at all. It's being treated as first-class but different. To form a poor analogy, imagine threads woven together to make a tapestry. The blue threads are just as important as the red threads, but they each may have different purposes in the overall design. my two cents, -Scott -- Jonathan Scott Duff <[EMAIL PROTECTED]>

Re: Is Perl 6 too late?

2007-05-14 Thread Jonathan Scott Duff
g must be an array". Perl 6 has changed the meaning behind the notation ever so slightly, but the utility is still there. -Scott -- Jonathan Scott Duff [EMAIL PROTECTED]

Re: Working on punie + rindolf (the implementation) Reloaded

2007-04-11 Thread Jonathan Scott Duff
uot; rankled me a little bit. Perl 6 is definitely NOT different in spirit. In fact, Perl 6 is all about the spirit of Perl but changing some of the details that have held it back. All of the spirity things of Perl 5 are still present in Perl 6: TMTOWTDI, easy things easy, hard things possible, etc. -Scott -- Jonathan Scott Duff [EMAIL PROTECTED]

Re: Perl 6 Microgrants. Now accepting proposals.

2007-03-23 Thread Jonathan Scott Duff
// DO NOT EDIT THIS FILE - it is machine generated -*- c++ -*- So, perhaps it's not the .h files we should be parsing, but whatever source files were used to generate them. Though, of course, some C++-to-Perl6 tool would be a good thing too. :-) -Scott -- Jonathan Scott Duff [EMAIL PROTECTED]

Re: Negative array subscripts

2007-02-14 Thread Jonathan Scott Duff
On 2/6/07, Smylers <[EMAIL PROTECTED] > wrote: Jonathan Scott Duff writes: > ... I can see the need for a pragma to help out the Pascal or Fortran > programmers start all of their arrays at something other than 0. Those sort of crutches in programming languages (let's help f

Re: Negative array subscripts

2007-02-07 Thread Jonathan Scott Duff
e Pascal or Fortran programmers start all of their arrays at something other than 0. And I can see the need for a modifier so that an individual array can start at an index other that 0. just registering my tuppence, -Scott -- Jonathan Scott Duff [EMAIL PROTECTED]

Re: Fwd: Numeric Semantics

2007-01-23 Thread Jonathan Scott Duff
that tends to muddy the waters a bit when it comes to your brain helping you find the bug. (at least it does for me) -Scott -- Jonathan Scott Duff [EMAIL PROTECTED]

Fwd: Numeric Semantics

2007-01-23 Thread Jonathan Scott Duff
I accidently sent this just to Darren ... -Scott -- Forwarded message -- From: Jonathan Scott Duff <[EMAIL PROTECTED]> Date: Jan 22, 2007 6:23 PM Subject: Re: Numeric Semantics To: Darren Duncan <[EMAIL PROTECTED]> On 1/22/07, Darren Duncan <[EMAIL PROTECTE

Re: Numeric Semantics

2007-01-23 Thread Jonathan Scott Duff
athematical behavior from Perl. Perhaps it's that you've been using computers too long and have become used to the limitations of digital media. -Scott -- Jonathan Scott Duff [EMAIL PROTECTED]

Re: beginner's question

2006-10-30 Thread Jonathan Scott Duff
nguage is still being designed, you probably want to know about Perl5 resources. A good place to start would be http://learn.perl.org/. Also, you might want to try on IRC. There's #perl on the freenode network and #perlhelp on efnet. hope this helps, -Scott -- Jonathan Scott Duff <[EMAIL PROTECTED]>

Re: Automatic coercion and context

2006-09-30 Thread Jonathan Scott Duff
into a Foo. I'm of the opinion that if you need a routine to handle multiple "types" then you should define it such that it is sufficiently general enough to do so without the benefit of added behind the scenes magic. -Scott -- Jonathan Scott Duff <[EMAIL PROTECTED]>

Re: FYI compiling PIR function calls

2006-09-27 Thread Jonathan Scott Duff
obj.$bar() # a method variable The same could be used for ordinary subroutines: .local string mysub mysub = "foo" $mysub()# calls the foo subroutine -Scott -- Jonathan Scott Duff <[EMAIL PROTECTED]>

Re: renaming "grep" to "where"

2006-09-19 Thread Jonathan Scott Duff
e, no more aliases. They only create confusion. Sure, but "all's fair if you predeclare". Aliases imposed on us all may cause confusion, but presumably, if an individual has asked for an alias, they are willing to risk the potential confusion. For me personally, I can live with "filter" as an alias for "grep". But that's just me. -Scott -- Jonathan Scott Duff <[EMAIL PROTECTED]>

dashed identifiers (was Re: -X file test operators)

2006-09-15 Thread Jonathan Scott Duff
g-name than $some_long_name if only to not touch the shift key :-) -Scott -- Jonathan Scott Duff <[EMAIL PROTECTED]>

Re: -X file test operators

2006-09-15 Thread Jonathan Scott Duff
ter all :) Or maybe -e and friends are just macros and there are no postfix forms. -Scott -- Jonathan Scott Duff <[EMAIL PROTECTED]>

Re: META vs meta

2006-09-12 Thread Jonathan Scott Duff
> > 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 has a cultural claim on ALLCAPS thingys. So, yes, it does help. -Scott -- Jonathan Scott Duff <[EMAIL PROTECTED]>

Re: Implicit current-index variable, scoped inside for-loops

2006-08-29 Thread Jonathan Scott Duff
scope lasts beyond the bounds of the block in which it's executing so that things like for @array { ... last if ...; } say "Stopped processing at $=.index"; work. But, again, we have other ways of making this work that don't involve introducing some implicit thing. -Scott (PerlJam) -- Jonathan Scott Duff <[EMAIL PROTECTED]>

Re: Stubborn coworkers

2006-08-29 Thread Jonathan Scott Duff
gs better. Et cetera. Does she also have some problem with perl5? It sounds like she's just trying to apply the "perl is line noise" argument but only for perl6. IMHO, the same counter arguments apply. -Scott -- Jonathan Scott Duff [EMAIL PROTECTED]

Re: clarify: does "Dog is Mammal" load Mammal for you?

2006-08-21 Thread Jonathan Scott Duff
? This seems like something we shouldn't encourage as it tends toward tight coupling of implementations where it should be tight coupling of abstractions. I don't know ... someone argue my brain into a new position :-) -Scott -- Jonathan Scott Duff [EMAIL PROTECTED]

Re: End the Hollerith Tyranny? (linelength.t)

2006-08-21 Thread Jonathan Scott Duff
an create tools to deal with it (uuencode anyone?). Also by not keeping to 80 columns, we can weed out the modern tools that still have such limitations and encourage the authors to fix them. And if *that* turns out to be too big of an endeavour, we can always go back to 80 columns, but I'm guessing whatever problems there are will be small and localized. just my humble opinion, -Scott -- Jonathan Scott Duff [EMAIL PROTECTED]

Re: NEXT and the general loop statement

2006-08-17 Thread Jonathan Scott Duff
ne whether to call NEXT or LAST. > (Sorry for the double post.) Depends on when it fires I guess. Your example might be equivalent to this perl5ish: while (1) { $num = rand; print $num; last if $num < 0.9; print ","; # NEXT } print "\n"; # LAST -Scott -- Jonathan Scott Duff [EMAIL PROTECTED]

Re: Curious corner cases concerning closure cloning

2006-08-14 Thread Jonathan Scott Duff
le, it keeps it's value between invocations, so the output would be: 42 43 # again, blank on purpose 1 > for 1,2 -> $x { > END { say $x } > } For this one I'd guess that a solitary "2" is output. The END block closed over the $x and the last value that $x obtained was 2. my humble guesses, -Scott -- Jonathan Scott Duff [EMAIL PROTECTED]

Re: Module/Class Authoritys

2006-08-10 Thread Jonathan Scott Duff
t do we do with the combinatorial explosion of this? use Foo-(1.2 .. 3.3)-(X|Y|Z); Suddenly it seems like a really good idea to only have one authority. -Scott -- Jonathan Scott Duff [EMAIL PROTECTED]

Re: [svn:perl6-synopsis] r10804 - doc/trunk/design/syn

2006-08-10 Thread Jonathan Scott Duff
7;re being required or not because the "trick" is built-in to the language :) -Scott -- Jonathan Scott Duff [EMAIL PROTECTED]

Re: S04 - forbidden coding-style

2006-07-21 Thread Jonathan Scott Duff
py; eat :if $hungry; go_postal :when $aggravation > 10; .sleep :until .rested; *Everybody* wants the colon! ;-) -Scott -- Jonathan Scott Duff [EMAIL PROTECTED]

Re: ===, =:=, ~~, eq and == revisited (blame ajs!)

2006-07-12 Thread Jonathan Scott Duff
s that true? By the rules of hyper-operation, it turns into this: [1,2] ~~ sub { return 1 } 3 ~~ sub { return 1 } which is true if these return true values: sub { return 1 }->([1,2]) sub { return 1 }->(3) Which they do. So, smart-match fails as a "deep equality" operator precisely because it's so smart. -Scott -- Jonathan Scott Duff [EMAIL PROTECTED]

Re: [ANNOUNCE] Pugs 6.2.12 and v6.pm released! (reformatted)

2006-07-10 Thread Jonathan Scott Duff
t has an indirect dependency on > Devel::Caller which fails to work using that compiler combination (i.e., > fails all tests after a build using its makefile and Visual Studio 2003 as > the C compiler). Bummer. You could check out the Vanilla/Strawberry Perl effort at http://win32.p

Re: Pm's YAPC::NA talk online

2006-06-28 Thread Jonathan Scott Duff
you are generating may be large (like say, between a very complex and rich language like Perl6 and a much simpler language like PIR ;). TGE lets you factor out the complexity of your source language in incremental steps (as small or as large steps as you want). > Good luck for today's presentation :) Yeah, good luck Pm :) -Scott -- Jonathan Scott Duff [EMAIL PROTECTED]

Re: Why does p6 always quote non-terminals?

2006-06-27 Thread Jonathan Scott Duff
ffect of parameterized rules, you should really be using a closure anyway? So, I guess that answers your question ... If not, I'm sure someone else will come along and give something more definitive :-) -Scott -- Jonathan Scott Duff [EMAIL PROTECTED]

Re: Can foo("123") dispatch to foo(Int) (was: Mutil Method Questions)

2006-06-23 Thread Jonathan Scott Duff
ument type appears in the "does list" of the Signature, then it's a match and all is well. Otherwise it's an error. Since "Num does Int", a call such as C succeeds. At least that's my vague interpretation of this aspect of perl6 at this moment. :-) -Scott -- Jonathan Scott Duff [EMAIL PROTECTED]

Re: Mutil Method Questions

2006-06-23 Thread Jonathan Scott Duff
On Fri, Jun 23, 2006 at 06:55:28PM +0300, Markus Laire wrote: > On 6/23/06, Jonathan Scott Duff <[EMAIL PROTECTED]> wrote: > >An alternate interpretation would be that the last one is actually a > >compile- > >time error because none of the sigs match (Int,Int) and f

Re: Mutil Method Questions

2006-06-23 Thread Jonathan Scott Duff
x27;d need to be explicit: talk(~123,3); But I'm not sure which way perl6 actually leans. Though it seems to me that automatic type conversion by the compiler is a way to get yourself in trouble. Not that perl shouldn't let the programmer get himself in trouble, but this seems like one of those things that should require asking to turn on rather than asking to turn off. my two cents, -Scott -- Jonathan Scott Duff [EMAIL PROTECTED]

Re: lvalue functions and lvalue parameters

2006-06-20 Thread Jonathan Scott Duff
nstant = 0; > my Int $b is constant = 0; > (cond(True, $a,$b))++; We have a "constant" declarator now, so that would be constant Int $a = 0; constant Int $b = 0; (cond(True, $a,$b))++; and that should fail at compile time because the compiler knows that $a and $b are constant and can't be rw. -Scott -- Jonathan Scott Duff [EMAIL PROTECTED]

Re: Concurrency: hypothetical variables and atomic blocks

2006-06-01 Thread Jonathan Scott Duff
if there's a way to order > >the locks in virtual time such that they still make sense. Then you > >just pretend that things happened in that order. > > Forgive this ignorant soul; but what is "STM"? Software Transaction Memory -Scott -- Jonathan Scott Duff [EMAIL PROTECTED]

Re: Simple Print/Say Question

2006-05-24 Thread Jonathan Scott Duff
t). If you're going to type @results, maybe it needs to be: my @results is Array of Array of int; or maybe my Array of int @results; Or something like that :-) -Scott -- Jonathan Scott Duff [EMAIL PROTECTED]

Re: Newbe: How do I configure @*INC ?

2006-05-23 Thread Jonathan Scott Duff
win32) separated list of directories to search. -Scott -- Jonathan Scott Duff [EMAIL PROTECTED]

Re: Windows Binaries for Pugs

2006-05-19 Thread Jonathan Scott Duff
he way to go. Binaries are definitely worth it to give people something to play with (especially on difficult platforms like Windows). It doesn't have to be the latest and greatest, it just has to implement a large-enough feature set. -Scott -- Jonathan Scott Duff [EMAIL PROTECTED]

Re: A rule by any other name...

2006-05-11 Thread Jonathan Scott Duff
On Thu, May 11, 2006 at 12:19:21PM -0700, Allison Randal wrote: > Jonathan Scott Duff wrote: > >On Wed, May 10, 2006 at 05:58:57PM -0700, Allison Randal wrote: > >>rule: > >>- Has :ratchet and :skip turned on by default > >> > >>- May only b

Re: A rule by any other name...

2006-05-11 Thread Jonathan Scott Duff
t "may only" really meant "must") And if we're keeping the correspondence between classes+methods and grammars+rules, then surely grammars are composable entities just like classes. Seeking clarification, -Scott -- Jonathan Scott Duff [EMAIL PROTECTED]

Re: Scans

2006-05-09 Thread Jonathan Scott Duff
didn't specify. My vote would be that list([+] 1) == (1) just like [+] 1 == 1 -Scott -- Jonathan Scott Duff [EMAIL PROTECTED]

Re: S5 - Question about repetition qualifier

2006-04-25 Thread Jonathan Scott Duff
7;s no easy way to say "match 1, 7, 12, or 19" with this particular syntax. How often does that come up in practice though? I don't think I've ever wanted something like that. If we allow "Junction of Int" that also gets us "Set of Int" as Junctions are just funny Sets. Why not "Array of Int" too? -Scott -- Jonathan Scott Duff [EMAIL PROTECTED]

Re: S05: Interpolated hashes?

2006-04-24 Thread Jonathan Scott Duff
he first place. Why would you need to match the key again? Maybe your subrule needs to know what came before the key in order to perform some action: req() if m:c/ / # require des() if m:c/ / # desire I assume that is somehow magically anchored to the spot where the key actually matched. -Scott -- Jonathan Scott Duff [EMAIL PROTECTED]

Re: [svn:perl6-synopsis] r8899 - doc/trunk/design/syn

2006-04-21 Thread Jonathan Scott Duff
On Fri, Apr 21, 2006 at 11:06:20AM -0700, Larry Wall wrote: > On Fri, Apr 21, 2006 at 12:45:13PM -0500, Jonathan Scott Duff wrote: > : According to S05, "a /.../ matches immediately in a value context > : (void, Boolean, string, or numeric)" and since > : > :

Re: [svn:perl6-synopsis] r8899 - doc/trunk/design/syn

2006-04-21 Thread Jonathan Scott Duff
tern /; is very much the same as state $x; $x = $x || /pattern/; I'd say that's a "boolean context" and thus matches against $_ instead of assigning the Regex object to $x. -Scott -- Jonathan Scott Duff [EMAIL PROTECTED]

Re: synopses

2006-04-08 Thread Jonathan Scott Duff
On Sat, Apr 08, 2006 at 03:22:15PM -0400, Sean Sieger wrote: > Is there public access to the synopses at svn or cvs? If you're just looking for read-only access, see http://svn.perl.org/perl6/doc/trunk -Scott -- Jonathan Scott Duff [EMAIL PROTECTED]

Re: [svn:perl6-synopsis] r8569 - doc/trunk/design/syn

2006-04-06 Thread Jonathan Scott Duff
and hoping we notice when things change? Sending the log + diff gives an easy way to brain-filter the messages too. I can look at the log and decide if I really care about the minute changes to twigils enough to read through all of the places where it makes a difference. -Scott -- Jonathan Scott Duff [EMAIL PROTECTED]

Re: Perl 6 on Solaris 10 anyone ?

2006-03-29 Thread Jonathan Scott Duff
Perl6 do I need Pugs ? I understood I would > need only the new Parrot VM ? Isn't that right ? Eventually. When there's a perl6 compiler that's based on parrot. Right now, the only usable implementation of perl6 that we have is pugs. -Scott -- Jonathan Scott Duff [EMAIL PROTECTED]

Re: 'temp $x;' with no assignment

2006-03-27 Thread Jonathan Scott Duff
On Mon, Mar 27, 2006 at 10:46:02PM +0200, Yuval Kogman wrote: > On Mon, Mar 27, 2006 at 14:35:52 -0600, Jonathan Scott Duff wrote: > > I think that if C is the new C, then immediately after the > > C line, $x should hold whatever flavor of undef is appropriate. > > > >

Re: 'temp $x;' with no assignment

2006-03-27 Thread Jonathan Scott Duff
$x is 5 again > > and otherwise pretty much DWIMs, except from a historical > perspective. Is there some reason we're huffmannizing my $x = 5; { temp $x = $MY::x + 1;# or whatever the proper syntax is # $x is 6 } $x = 5; ?? Can you elaborate an example that wou

Re: The definition of 'say'

2006-02-08 Thread Jonathan Scott Duff
mit that Damian's brain doesn't work like everyone > else's brain. Just as another data point, I too have been thinking of "say" as "print + newline". -Scott -- Jonathan Scott Duff [EMAIL PROTECTED]

Re: Is S05 correct?

2006-02-06 Thread Jonathan Scott Duff
pmichaud says, it doesn't differ substantially from what you've already seen. -Scott -- Jonathan Scott Duff [EMAIL PROTECTED]

  1   2   3   4   5   6   >