Re: Class attribute introspection

2013-10-28 Thread Richard Hainsworth
This and the response from Elizabeth raise in my mind the following question: To what extent are papers/specifications from other parts of the computer science world implicitly a part of the Perl6 specification? I found references to 'getters and setters' in the synopsis on objects, but without

Re: Class attribute introspection

2013-10-28 Thread Carl Mäsak
The MOP is an API to the object-oriented system. With it, you can query classes and their attributes and methods about their properties. It can also be used to create whole new classes (or other types) programatically. Languages that have a MOP have a great advantage because, even though the objec

Re: Class attribute introspection

2013-10-28 Thread Elizabeth Mattijsen
Maybe http://en.wikipedia.org/wiki/Metaobject is a good start for reading up on what a MOP (Meta-Object Protocol) is. Liz === On 28 Oct 2013, at 14:17, Richard Hainsworth wrote: > Moritz, > > You are the everflowing font of knowledge. Thanks. > > However, I read the synopsis on ob

Re: Class attribute introspection

2013-10-28 Thread Patrick R. Michaud
On Mon, Oct 28, 2013 at 05:17:37PM +0400, Richard Hainsworth wrote: > Pardon the ignorance, but what is "the MOP". I sometimes get floored > by the jargon. Whatever answer we get should go into S99. https://github.com/perl6/specs/blob/master/S99-glossary.pod Pm

Re: Class attribute introspection

2013-10-28 Thread Richard Hainsworth
Moritz, You are the everflowing font of knowledge. Thanks. However, I read the synopsis on objects and did not find the .get_value method. Pardon the ignorance, but what is "the MOP". I sometimes get floored by the jargon. I read about the indirection for methods, but how does that relate

Re: Class attribute introspection

2013-10-28 Thread Moritz Lenz
Hi Richard, On 10/28/2013 08:07 AM, Richard Hainsworth wrote: Perhaps I am using class incorrectly, but I set up a class, then change some of the parameters in an instance of the class. Next I would like to discover what the current state of the instance is. There is a way to introspect throug

Re: Defining Perl 6 for the masses

2013-10-01 Thread Richard Hainsworth
There are two issues here. a) Using language in a consistent manner in Perl6 space - the word 'specification' is used in Perl6 space both in the way it has become acceptable in computer language design circles, but also in a new and more nuanced way in Perl6. - Perl6 is being developed using La

Re: Defining Perl 6 for the masses

2013-10-01 Thread Parrot Raiser
Minor corrections: > may smply be my personal limitations). s/smply/simply/ > dumb "noob" questions. By my fairly harsh definition. > with the sage of IBM's attempt to develop One Language To Rule Them All, s/sage/saga/

Re: [perl6/specs] 126dd3: Mark ".exists" and ".delete" as deprecated, use ":...

2013-10-01 Thread yary
I suspect there are copy-paste errors on the "delete" sections of the new text: ... the +normal way to test for existence is to apply the C<:delete> adverb to a +subscripting operation. The ":delete" adverb tests for existence? -y On Mon, Sep 30, 2013 at 6:09 AM, GitHub wrote: > Branch: refs

Re: Introduction to Synopses

2013-09-30 Thread Richard Hainsworth
On 09/30/2013 02:16 AM, Patrick R. Michaud wrote: On Mon, Sep 30, 2013 at 02:03:43AM +0800, Richard Hainsworth wrote: Not wising to disagree with PM, but "|docs/feather/syn_index.html" states on line 1:| "The Synopsis documents are to be taken as the formal specification for Perl 6 implementatio

Re: Introduction to Synopses

2013-09-29 Thread Patrick R. Michaud
On Mon, Sep 30, 2013 at 02:03:43AM +0800, Richard Hainsworth wrote: > Not wising to disagree with PM, but "|docs/feather/syn_index.html" > states on line 1:| > "The Synopsis documents are to be taken as the formal specification > for Perl 6 implementations" What follows is just my opinion, there's

Re: Introduction to Synopses

2013-09-29 Thread Richard Hainsworth
Not wising to disagree with PM, but "|docs/feather/syn_index.html" states on line 1:| "The Synopsis documents are to be taken as the formal specification for Perl 6 implementations" I have seen elsewhere, can't remember where, that the parser written by Larry is also considered a part of the s

Re: Introduction to Synopses

2013-09-29 Thread Patrick R. Michaud
On Sun, Sep 29, 2013 at 01:28:48PM +0800, Richard Hainsworth wrote: > However, the Synopses are now primary specification and the > Apocalypses have only historical significance. Also there are more > Synopses than Apocalypses. One correction: The test suite ("roast") is the primary specification

Re: Introduction to Synopses

2013-09-29 Thread Moritz Lenz
Hi Richard, On 09/29/2013 07:28 AM, Richard Hainsworth wrote: > Some suggestions about documentation. > > Originally the Synopses were implementation oriented sumaries of the > previous description base Apocalypses. That meant that the Synopses were > derivative and secondary to the Apocalypses

Julia: was Re: Commensurability as Key

2013-08-23 Thread Todd C. Olson
It is interesting to look at what Julia has done to get numerical performance from a dynamic language http://julialang.org/ and julia's visibility in to the internal representation http://blog.leahhanson.us/julia-introspects.html Regards, Todd Olson

Re: Commensurability as Key

2013-08-23 Thread Steve Pitchford
an individual basis you may have 6 apples. In > some cases you may represent that as 6 instances. In another context, you > may represent a collection of apples in their tray form - which may have a > notional weight with a tolerance. Now, if one were writing a checkout > system, it may b

Re: Commensurability as Key

2013-08-23 Thread Jonathan Lang
ay > represent a collection of apples in their tray form - which may have a > notional weight with a tolerance. Now, if one were writing a checkout system, > it may be sufficient for one to have a "fruit" class, of which "apples" and > "oranges" are ins

Re: Commensurability as Key

2013-08-23 Thread Steve Pitchford
nstances. In another context, you >> may represent a collection of apples in their tray form - which may have a >> notional weight with a tolerance. Now, if one were writing a checkout >> system, it may be sufficient for one to have a "fruit" class, of which >> &qu

Re: Commensurability as Key

2013-08-23 Thread Paweł Murias
er context, you > may represent a collection of apples in their tray form - which may have a > notional weight with a tolerance. Now, if one were writing a checkout > system, it may be sufficient for one to have a "fruit" class, of which > "apples" and "oranges&q

Re: Commensurability as Key

2013-08-23 Thread Steve Pitchford
I think James Bowery's comments are intended to address a real need for programming languages to work with units of measurement. It might even prevent aircraft accidents which have really happened because fuel was delivered in Canadian gallons, or kilograms, when the pilots request was for American

Re: Commensurability as Key

2013-08-21 Thread Doug McNutt
At 20:27 -0700 8/20/13, Jonathan Lang wrote: Off list accidentally I think. >Could you try to put commensurability into layman's terms? Preferably with a >focus on some of its less obvious advantages. > >On Aug 20, 2013, at 8:19 PM, Doug McNutt wrote: > >> At 11:41 -0400 8/20/13, yary wrote: >

Re: Commensurability as Key

2013-08-21 Thread James Bowery
The terms "function" and "relation" as used in programming languages have meanings carved out of the pure concepts by the, sometimes, judicious application of Ockham's Chainsaw Massacre in order to "get things done". I am speaking of the pure concepts. Procedures are sequences of statements. Sta

Re: Commensurability as Key

2013-08-21 Thread Brandon Allbery
On Tue, Aug 20, 2013 at 11:19 PM, Doug McNutt wrote: > I confess. I'm here because I hoped perl 6 would do vector operations > after reading an early small book. I don't think anyone has said that it won't/can't. Perl 6 indeed returns a scalar... but that scalar may be a container of some kind,

Re: Commensurability as Key

2013-08-20 Thread Moritz Lenz
Hello, some clarifications below On 08/21/2013 05:19 AM, Doug McNutt wrote: >> * a "function" is a subroutine returning a scalar ( see below) fwiw we don't make that distinction in the specification; we just talk about subroutines. We can return nothing, a scalar or a non-scalar. >>, a "pr

Re: Commensurability as Key

2013-08-20 Thread Doug McNutt
At 11:41 -0400 8/20/13, yary wrote: >I'll bite... this concept of "commensurablity" is not one I grasp from >your email. > >"functions are (sugarably) degenerate (many to 1) relations and >procedures are (sugarably) degenerate (state-transition) functions." >Perl & many other languages don't have a

Re: Commensurability as Key

2013-08-20 Thread yary
I'll bite... this concept of "commensurablity" is not one I grasp from your email. "functions are (sugarably) degenerate (many to 1) relations and procedures are (sugarably) degenerate (state-transition) functions." Perl & many other languages don't have a strong distinction between functions & pr

Re: Commensurability as Key

2013-08-19 Thread James Bowery
Maybe Perl 7. On Mon, Aug 19, 2013 at 2:30 PM, Parrot Raiser <1parr...@gmail.com> wrote: > Let's get the basics nailed down and working so that we can learn > them, before wandering any further into theoretical CS. > > On 8/18/13, James Bowery wrote: > > Of the two key conceptual gaps in curren

Re: Commensurability as Key

2013-08-19 Thread Parrot Raiser
Let's get the basics nailed down and working so that we can learn them, before wandering any further into theoretical CS. On 8/18/13, James Bowery wrote: > Of the two key conceptual gaps in current programming language philosophy > -- commensurability and change propagation -- commensurability, i

Re: Are set operations needed?

2013-07-21 Thread Giuseppe Castagna
On 18/07/13 17:58, Patrick R. Michaud wrote: [...] Sets do not implement well on a computer. Let me strongly disagree with this statement. Sets implement *very well* on computer, it just suffices to know how to do it. You want a constructive proof? Check the CDuce language (http://www.cduc

Re: Are set operations needed?

2013-07-18 Thread Patrick R. Michaud
On Thu, Jul 18, 2013 at 07:07:20PM +0800, Richard Hainsworth wrote: > I wondered whether the desire to have sets in perl6 was driven by > mathematical fashion sensitivity (in some roundabout unconscious > way) and because sets are important to mathematical foundations. > [...] > Sets do not impleme

Re: Are set operations needed?

2013-07-18 Thread Solomon Foster
Full list of "Texas" (ie ASCII) set operators: union: (|) intersection: (&) set difference: (-) symmetric difference: (^) subset: (<=) proper subset: (<) superset: (>=) proper superset: (>) is an element of: (elem) is contained by: (cont) On Thu, Jul 18, 2013 at 11:45 AM, Solomon Foster wrote:

Re: Are set operations needed?

2013-07-18 Thread Solomon Foster
All set operations work on Rakudo, but none of the Unicode set operators are enabled, because multibyte Unicode characters kill the performance of Rakudo's parser when compiling Rakudo. So for example you can use (|) for set union, but not ∪. I think there are probably some glitches there yet, pa

Re: Are set operations needed?

2013-07-18 Thread Richard Hainsworth
I'm well behind the curve on implementation, this I know. But before writing the email, I checked the perl6 web site on what was implemented. Set operations still given as not implemented. The impression I formed was that set operations would be a long time coming - even after Christmas. Wh

Re: Are set operations needed?

2013-07-18 Thread yary
And regardless of homotopy type theory being able to supplant set theory, with the spirit of "there's more than one way to do it", set ops are still a welcome tool. Also in that spirit, would you like to write up a summary of HoTT alternatives to common set ops, or post a link to a HoTT summarzing

Re: Are set operations needed?

2013-07-18 Thread Moritz Lenz
On 07/18/2013 01:07 PM, Richard Hainsworth wrote: Are set operations needed in Perl6? No implementation of the perl6 set specification yet exists (AFAIK). You are wrong. Both rakudo and niecza implement significant subsets of the set specification. Cheers, Moritz

Re: [perl6/specs] e85286: [S17]: Add references to hyperops, feeds, and junc...

2013-06-06 Thread yary
The commit has a link to a paper about unifying event loops & threads doesn't server the paper anymore. Looks like you can get it at http://www.cis.upenn.edu/~stevez/papers/LZ06b.pdf -y On Thu, Jun 6, 2013 at 3:53 PM, GitHub wrote: > Branch: refs/heads/master > Home: https://github.com/per

Re: Rakudo Star 2013.05 released

2013-05-30 Thread Patrick R. Michaud
On Thu, May 30, 2013 at 11:08:13PM -0500, Patrick R. Michaud wrote: > This Star release includes [release 2013.05] of the > [Rakudo Perl 6 compiler], version 5.2.0 of the [Parrot Virtual > Machine] ... Oops. The 2013.05 release actually contains Parrot 5.3.0. Sorry about the typo. Pm

Re: Problem using a module containing a grammar

2013-03-25 Thread Brandon Allbery
On Mon, Mar 25, 2013 at 11:01 AM, wrote: > grammar SalesExportGram is export { (...) > my $parsed = SalesReportGram.parsefile('sales_report.txt'); > Might help if you used the same name in both places? -- brandon s allbery kf8nh sine nomine associates allber...

Re: Problem using a module containing a grammar

2013-03-25 Thread raiph mellor
On Mon, Mar 25, 2013 at 11:01 AM, wrote: > I have created a file called SalesReport.mp6, which contains a grammar > > module SalesReport; > grammar SalesExportGram is export { Aiui you can now use this module to introduce SalesReport as a module name and SalesExportGram as a grammar name

Re: Problem using a module containing a grammar

2013-03-25 Thread phiroc
ort; my $parsed = SalesReport.parsefile('sales_report.txt'); - Mail original - De: "Brandon Allbery" À: phi...@free.fr Cc: perl6-language@perl.org Envoyé: Lundi 25 Mars 2013 16:08:14 Objet: Re: Problem using a module containing a grammar On Mon, Mar 25, 2013 at 11:01

Re: ADT and GADT (a partial implementation)

2013-03-23 Thread Timo Paulssen
On 21.03.2013 17:45, Carl Mäsak wrote: > [...] > > Using hashes and subclasses: Using > classes and subclasses: > > [...] I came up with a prototype to create those classes like in the second gist automatically by su

Re: ADT and GADT

2013-03-21 Thread Carl Mäsak
Philippe (>): > I like solution 2, but am going to have to delve into the Perl 6 > Documentation to > understand its esoteric syntax: S12 will be a big help here. You may have found it already. I include a few quick pointers below, which also may help. > -

Re: ADT and GADT

2013-03-21 Thread phiroc
t; Envoyé: Jeudi 21 Mars 2013 17:45:45 Objet: Re: ADT and GADT Hi Philippe, Philippe (>): > will Abstract Data Types and Generalized Abstract Data Types be available in > Perl6 anytime soon? Algebraic Data Types -- this is a topic that has come up before on #perl6 on IRC. Often enough I&

Re: ADT and GADT

2013-03-21 Thread Carl Mäsak
Hi Philippe, Philippe (>): > will Abstract Data Types and Generalized Abstract Data Types be available in > Perl6 anytime soon? Algebraic Data Types -- this is a topic that has come up before on #perl6 on IRC. Often enough I've been the one mentioning it. Let's just stop briefly to define a few

Re: Panda on Windows

2013-03-20 Thread Tadeusz Sośnierz
On 03/20/2013 02:18 PM, Patrick R. Michaud wrote: Out of curiosity, is there a way to get the error message to indicate what panda was attempting to connect *to*? connect failed: A connection attempt to somehost.org failed This would normally happen. Panda does: die "Unable to fetch $s

Re: Panda on Windows

2013-03-20 Thread Tadeusz Sośnierz
On 03/20/2013 02:42 PM, phi...@free.fr wrote: Hi, which ports should be authorized? Philippe Hi, panda currently connects to port 3000 on feather.perl6.nl. This may change in near future; the projects list will probably be kept in git somehow, see https://github.com/tadzik/panda/issues/33

Re: Panda on Windows

2013-03-20 Thread phiroc
Hi, which ports should be authorized? Philippe - Mail original - De: "Tadeusz Sośnierz" À: perl6-language@perl.org Envoyé: Mercredi 20 Mars 2013 13:49:21 Objet: Re: Panda on Windows On 03/20/2013 10:21 AM, phi...@free.fr wrote: > Hello, > > when I type "panda

Re: Panda on Windows

2013-03-20 Thread Patrick R. Michaud
On Wed, Mar 20, 2013 at 01:49:21PM +0100, Tadeusz Sośnierz wrote: > On 03/20/2013 10:21 AM, phi...@free.fr wrote: > >Hello, > > > >when I type "panda" on the Windows command line, I get the following message: > > > >D:\users\me>panda > >connect failed: A connection attempt failed because the connec

Re: Panda on Windows

2013-03-20 Thread Tadeusz Sośnierz
On 03/20/2013 10:21 AM, phi...@free.fr wrote: Hello, when I type "panda" on the Windows command line, I get the following message: D:\users\me>panda connect failed: A connection attempt failed because the connected party did not properly respond after a period of time, or established conn ecti

Re: NQP JVM prototype faster than Perl 5

2013-02-03 Thread Nicholas Clark
On Sun, Feb 03, 2013 at 10:35:12AM +, Nicholas Clark wrote: > On Sat, Feb 02, 2013 at 06:32:10PM -0800, Matthew Wilson wrote: > > Did you mean to use $z in the say output of the nqp and perl versions of > > the microbenchmark, or did you mean to run it twice? > > I didn't write the nqp microbe

Re: NQP JVM prototype faster than Perl 5

2013-02-03 Thread Nicholas Clark
On Sat, Feb 02, 2013 at 06:32:10PM -0800, Matthew Wilson wrote: > Did you mean to use $z in the say output of the nqp and perl versions of > the microbenchmark, or did you mean to run it twice? I didn't write the nqp microbenchmark, and I simply transcribed it to Perl 5, so it's intentional. I did

Re: NQP JVM prototype faster than Perl 5

2013-02-02 Thread Matthew Wilson
Did you mean to use $z in the say output of the nqp and perl versions of the microbenchmark, or did you mean to run it twice? On Sat, Feb 2, 2013 at 10:43 AM, Nicholas Clark wrote: > This is surprising, interesting and pleasing... > > There's some example NQP code to time calculating Fibonacci

Re: Rewrite of S21

2012-11-23 Thread Stefan O'Rear
On Fri, Nov 23, 2012 at 03:24:00PM +0100, Arne Skjærholt wrote: > Hi all. > I have rewritten S21 so that Zavolaj/NativeCall is spec. S21 as of > right now is probably the most thorough documentation of the current > state of NativeCall. > > Most of the basic functionality is fairly stable I think,

Re: Perl 6 in Perl 6?

2012-10-18 Thread Patrick R. Michaud
On Thu, Oct 18, 2012 at 09:59:21AM +0200, Moritz Lenz wrote: > > On 10/18/2012 09:02 AM, Darren Duncan wrote: > >Something (PyPy et al) got me wondering, is it a goal in the Perl > >community before too long to have a (compiling) implementation of Perl 6 > >written entirely in Perl 6? > > A fair

Re: Perl 6 in Perl 6?

2012-10-18 Thread Parrot Raiser
On Thu, Oct 18, 2012 at 3:59 AM, Moritz Lenz wrote: > > The priorities for most compiler hackers is to provide good compilers over > complete bootstrapping, and I guess most users agree with that goal. > Agreed. I'm most concerned about a reliable and consistent set of features being defined, so

Re: Perl 6 in Perl 6?

2012-10-18 Thread Moritz Lenz
On 10/18/2012 09:02 AM, Darren Duncan wrote: Something (PyPy et al) got me wondering, is it a goal in the Perl community before too long to have a (compiling) implementation of Perl 6 written entirely in Perl 6? A fair amount of the two major Perl 6 compilers, Rakudo and Niecza, are already w

Re: [perl6/specs] 5277fe: Add expmod and is-prime as built-ins in Int

2012-09-24 Thread Solomon Foster
On Mon, Sep 24, 2012 at 10:09 AM, Richard Nuttall wrote: > A quick search throws up http://primes.utm.edu/prove/prove2_3.html > > Which says that for/n/< 341,550,071,728,321 it is enough to test 2, 3, 5, 7, > 11, 13 and 17 to be definitive (and fewer specific tries for smaller n) > > That also ver

Re: [perl6/specs] 5277fe: Add expmod and is-prime as built-ins in Int

2012-09-24 Thread Richard Nuttall
A quick search throws up http://primes.utm.edu/prove/prove2_3.html Which says that for/n/< 341,550,071,728,321 it is enough to test 2, 3, 5, 7, 11, 13 and 17 to be definitive (and fewer specific tries for smaller n) That also verifies the 75/25 figures mentioned below. So, depending on the i

Re: [perl6/specs] 5277fe: Add expmod and is-prime as built-ins in Int

2012-09-20 Thread Stephen Pollei
On Thu, Sep 20, 2012 at 9:22 PM, Martin Kealey wrote: > On Thu, 20 Sep 2012, Stephen Pollei wrote: > According to Wolfram, it's 75/25; so a positive result after 10 iterations > leaves about a one-in-a-million chance of being composite (more precisely, > one in 1048576). I'd believe wolfram over

Re: [perl6/specs] 5277fe: Add expmod and is-prime as built-ins in Int

2012-09-20 Thread Martin Kealey
On Thu, 20 Sep 2012, Stephen Pollei wrote: > If it says it might be prime it's > about a 50% 50% split if it's correct. According to Wolfram, it's 75/25; so a positive result after 10 iterations leaves about a one-in-a-million chance of being composite (more precisely, one in 1048576). > multi me

Re: CFOs not aligned with Recruiting

2012-09-20 Thread Darren Duncan
So I guess we have a rare failure of a spam filter. -- Darren Duncan

Re: [perl6/specs] 5277fe: Add expmod and is-prime as built-ins in Int

2012-09-20 Thread Stephen Pollei
On Thu, Sep 20, 2012 at 11:36 AM, Martin D Kealey wrote: > On Wed, 19 Sep 2012, GitHub wrote: >> Log Message: >> --- >> Add expmod and is-prime as built-ins in Int > >> +Returns True if C<$x> is known to be a prime, or is likely to be a >> +prime based on a probabilistic Miller-Rabin

Re: state statements versus state expressions

2012-09-20 Thread Larry Wall
On Tue, Sep 11, 2012 at 10:25:03PM +0100, Nicholas Clark wrote: : On Tue, Sep 11, 2012 at 11:11:11PM +0200, Carl Mäsak wrote: : > Nicholas (>): : > > Where in the synopses (or other documents) does it explain why these two : > > are different? : > > : > > $ ./perl6 -e 'sub foo {state @a = (3, 4); s

Re: [perl6/specs] 5277fe: Add expmod and is-prime as built-ins in Int

2012-09-20 Thread Martin D Kealey
On Wed, 19 Sep 2012, GitHub wrote: > Log Message: > --- > Add expmod and is-prime as built-ins in Int > +Returns True if C<$x> is known to be a prime, or is likely to be a > +prime based on a probabilistic Miller-Rabin test. (The optional > +argument tells how many times to iterate

Re: state statements versus state expressions

2012-09-11 Thread Nicholas Clark
On Tue, Sep 11, 2012 at 11:11:11PM +0200, Carl Mäsak wrote: > Nicholas (>): > > Where in the synopses (or other documents) does it explain why these two > > are different? > > > > $ ./perl6 -e 'sub foo {state @a = (3, 4); say ++@a[0];}; foo; foo;' > > 4 > > 5 > > $ ./perl6 -e 'sub foo {(state @a) =

Re: state statements versus state expressions

2012-09-11 Thread Carl Mäsak
Nicholas (>): > Where in the synopses (or other documents) does it explain why these two > are different? > > $ ./perl6 -e 'sub foo {state @a = (3, 4); say ++@a[0];}; foo; foo;' > 4 > 5 > $ ./perl6 -e 'sub foo {(state @a) = (3, 4); say ++@a[0];}; foo; foo;' > 4 > 4 S03:4912. "Each declarator can t

Re: [perl6/specs] d9d8b3: refactor case mappings (again)

2012-07-30 Thread Smylers
Larry Wall writes: > On Tue, Jul 24, 2012 at 09:42:10PM +0100, Smylers wrote: > > : Under what circumstances is tcuc useful? I'm currently suffering > : from a lack of imagination as to when somebody would ever want that > : rather than just uc. > > A bare uc will do the wrong thing for the firs

Re: [perl6/specs] d9d8b3: refactor case mappings (again)

2012-07-30 Thread Larry Wall
On Tue, Jul 24, 2012 at 09:42:10PM +0100, Smylers wrote: : GitHub writes: : : > https://github.com/perl6/specs/commit/d9d8b35825f7abf07a9314fd90b0b5563253bd15 : > Author: Larry Wall : > : > There is no more titlecase function. Instead there is a suite : > of mapping functions appropria

Re: [perl6/specs] d9d8b3: refactor case mappings (again)

2012-07-24 Thread Smylers
GitHub writes: > > https://github.com/perl6/specs/commit/d9d8b35825f7abf07a9314fd90b0b5563253bd15 > Author: Larry Wall > > There is no more titlecase function. Instead there is a suite > of mapping functions appropriate to apply on a word-by-word basis > (tc, tclc, and tcuc), Under wh

Re: The .trans method and Least Surprise

2012-07-20 Thread Carl Mäsak
yary (>): > Speaking as a non-p6-coder "proposal sounds good to me" though the > spec raises some other questions. > >>The tr/// quote-like operator now also has a method form called >> trans(). Its argument is a list of pairs. You can use anything >> that produces a pair list: >> >> $str.trans

Re: The .trans method and Least Surprise

2012-07-13 Thread yary
Speaking as a non-p6-coder "proposal sounds good to me" though the spec raises some other questions. >The tr/// quote-like operator now also has a method form called > trans(). Its argument is a list of pairs. You can use anything > that produces a pair list: > > $str.trans( %mapping.pairs );

Re: When do named subs bind to their variables? [perl #113930]

2012-07-09 Thread Father Chrysostomos via RT
On Sat Jul 07 22:23:16 2012, thoughtstream wrote: > Father Chrysostomos asked: > > > What I am really trying to find out is when the subroutine is actually > > cloned, > > Yes. It is supposed to be (or at least must *appear* to be), > and currently is (or appears to be) in Rakudo. I said when, n

When do named subs bind to their variables? (Re: Questionable scope of state variables ([perl #113930] Lexical subs))

2012-07-09 Thread Father Chrysostomos via RT
I’m forwarding this to the Perl 6 language list, so see if I can find an answer there. [This conversation is about how lexical subs should be implemented in Perl 5. What Perl 6 does may help in determining how to iron out the edge cases.] On Sat Jul 07 13:23:17 2012, sprout wrote: > On Sat Jul 0

Re: When do named subs bind to their variables? (Re: Questionable scope of state variables ([perl #113930] Lexical subs))

2012-07-09 Thread Father Chrysostomos via RT
ared with permission. > > --tom > > From: Damian Conway > To:Tom Christiansen > CC:Larry Wall > Date: Sun, 08 Jul 2012 07:17:19 +1000 > Delivery-Date: Sat, 07 Jul 2012 15:19:09 >

Re: [perl #113930] Lexical subs

2012-07-08 Thread Damian Conway
> But by using the term ‘variable’, which is ambiguous, you are not > answering my question! :-) Sorry. I tend to think of *every* variable name as merely being an alias for some underlying storage mechanism. ;-) > Does > > my $x; > for 1..10 -> $x {} > > cause the existing name $x to ref

Re: [perl #113930] Lexical subs

2012-07-08 Thread Moritz Lenz
On 07/08/2012 09:57 PM, Father Chrysostomos via RT wrote: > my $x; > my sub f { say $x } > for 1..10 -> $x { f(); } It prints Any() Any() Any() Any() Any() Any() Any() Any() Any() Any() (because Any is the default value in uninitialized variables). As an aside, you can run short Per

Re: When do named subs bind to their variables? [perl #113930]

2012-07-08 Thread Moritz Lenz
On 07/08/2012 11:12 AM, Damian Conway wrote: > Father Chrysostomos pointed out: > >> I said when, not whether. :-) > > Isn't that just typical of me: confusing ontology with chronology. ;-) > > I'm afraid don't know the implementation details for Rakudo. It may be > bound as the surrounding block i

Re: When do named subs bind to their variables? [perl #113930]

2012-07-08 Thread Moritz Lenz
On 07/08/2012 11:12 AM, Damian Conway wrote: > Father Chrysostomos pointed out: > >> I said when, not whether. :-) > > Isn't that just typical of me: confusing ontology with chronology. ;-) > > I'm afraid don't know the implementation details for Rakudo. It may be > bound as the surrounding bloc

Re: When do named subs bind to their variables? [perl #113930]

2012-07-08 Thread Damian Conway
Father Chrysostomos pointed out: > I said when, not whether. :-) Isn't that just typical of me: confusing ontology with chronology. ;-) I'm afraid don't know the implementation details for Rakudo. It may be bound as the surrounding block is entered, or perhaps just-in-time when the Code object i

Re: When do named subs bind to their variables? (Re: Questionable scope of state variables ([perl #113930] Lexical subs))

2012-07-07 Thread Damian Conway
Father Chrysostomos asked: > What I am really trying to find out is when the subroutine is actually > cloned, Yes. It is supposed to be (or at least must *appear* to be), and currently is (or appears to be) in Rakudo. > and whether there can be multiple clones within a single call of > the encl

Re: When do named subs bind to their variables? (Re: Questionable scope of state variables ([perl #113930] Lexical subs))

2012-07-07 Thread Tom Christiansen
"Father Chrysostomos via RT" wrote on Sat, 07 Jul 2012 18:54:15 PDT: >Thank you. So the bar sub seems to be closing over the name @a (the >container/variable slot/pad entry/whatever), rather than the actual >array itself. >Since I don't have it installed, could you tell me what this does?

Re: When do named subs bind to their variables? (Re: Questionable scope of state variables ([perl #113930] Lexical subs))

2012-07-07 Thread Tom Christiansen
sion. --tom From: Damian Conway To:Tom Christiansen CC:Larry Wall Date: Sun, 08 Jul 2012 07:17:19 +1000 Delivery-Date: Sat, 07 Jul 2012 15:19:09 Subject: Re: my subs and state vars In-Reply-To: <22255.1341691089@chthon>

Re: [perl6/specs] 34fddf: [S32::Str] substr is not rw anymore, but substr-rw...

2012-06-09 Thread Moritz Lenz
On 06/09/2012 12:32 PM, Richard Hainsworth wrote: > I noticed that subst-rw does not have "is export" in the definition. > > Does this mean that subst-rw is not available outside the module? No. All routines from the setting are available to user space code, because they are simply in an outer s

Re: [perl6/specs] 34fddf: [S32::Str] substr is not rw anymore, but substr-rw...

2012-06-09 Thread Richard Hainsworth
I noticed that subst-rw does not have "is export" in the definition. Does this mean that subst-rw is not available outside the module? Richard On 06/09/2012 02:20 PM, GitHub wrote: Branch: refs/heads/master Home: https://github.com/perl6/specs Commit: 34fddf7788493098ac569f1cea7f214

Re: The trouble with awesome

2012-06-06 Thread Parrot Raiser
On Mon, Jun 4, 2012 at 12:01 AM, Peter Scott wrote: > We need multiple paths.  The term "beginner" creates problems I meant "beginner" with respect to Perl 6, but I think that Peter basically paraphrased my arguments about the problem. Although programming experience is an important variable, a

Re: The trouble with awesome

2012-06-04 Thread Peter Scott
On Tue, 22 May 2012 19:35:34 -0400, Parrot Raiser wrote: > The problem we have is to provide a path for learning 6, that presents a > comprehensible but useful subset of the language to the average user as > soon as possible, while leading the programmer with more complex needs, > (and greater abil

Re: The trouble with awesome

2012-06-03 Thread Parrot Raiser
On Wed, May 30, 2012 at 6:00 AM, Moritz Lenz wrote: > > I'd still start with simple script files, because that's what most > programmers are most familiar with. > I'd do them in Huffman order; the interpreter involves the least typing to start, and it's useful for demonstrating concepts. Usually,

Re: The trouble with awesome

2012-05-31 Thread Nicholas Clark
t behave differently on strings or numbers (++ and the bitwise operators) (this behaviour change being despite the lack of real types. ie, a hack) Then there is the "choice" of which language to implement in. The great strength of Perl 5 is all the code on CPAN. A lot of th

Re: The trouble with awesome

2012-05-30 Thread Moritz Lenz
Am 26.05.2012 21:12, schrieb Parrot Raiser: There are a lot of programmers who know several programming languages already, and who don't want to read a whole page on how to print 'Hello World', 5 pages on if-statements and while-loops and another 10 pages explaining lists and iteration. How

Re: The trouble with awesome

2012-05-28 Thread Xiao Yafeng
On Sat, May 26, 2012 at 6:34 PM, Nicholas Clark wrote: > On Fri, May 25, 2012 at 08:44:30AM -0500, B. Estrade wrote: > > > Realistically, that's not going to happen. The internals of the Perl 5 > interpreter are not flexible enough to implement a lot of the features > that > Perl 6 has that Perl

Re: The trouble with awesome

2012-05-28 Thread B. Estrade
On Mon, May 28, 2012 at 03:38:48PM +0800, Xiao Yafeng wrote: > On Sat, May 26, 2012 at 6:34 PM, Nicholas Clark wrote: > > > On Fri, May 25, 2012 at 08:44:30AM -0500, B. Estrade wrote: > > > > > > Realistically, that's not going to happen. The internals of the Perl 5 > > interpreter are not flexib

Re: The trouble with awesome

2012-05-28 Thread Parrot Raiser
> There are a lot of programmers who know several programming languages already, > and who don't want to read a whole page on how to print 'Hello World', 5 > pages on > if-statements and while-loops and another 10 pages explaining lists and > iteration. However experienced a programmer may be,

Re: The trouble with awesome

2012-05-28 Thread Patrick R. Michaud
On Sat, May 26, 2012 at 05:34:18AM +0530, Siddhant Saraf wrote: > Rakud[o] is not _the_ reference implementation of Perl 6. Actually, there is > no reference implementation for Perl 6. There never will be. Whoever wants > to make a perl6 implementation is free to do so. Just follow the spec and > y

On fashion, in Re: The trouble with awesome

2012-05-27 Thread Richard Hainsworth
On 05/23/2012 03:35 AM, Parrot Raiser wrote: Perl 6 is awesome. agreed In short, Perl 6 is awesome: "Extremely impressive or daunting, inspiring awe". http://oxforddictionaries.com/definition/awesome?view=uk That is a problem, if we want to get it adopted widely and quickly. Not convinced 'g

Re: The trouble with awesome

2012-05-26 Thread Nicholas Clark
On Fri, May 25, 2012 at 08:44:30AM -0500, B. Estrade wrote: > As an outside observer and long time fan, Perl 6 for me is more of a > formalization of the Perl language as it evolved (greatly influenced > by non-languages, such as Unix itself and natural language goals). > But, the truth is that it

Re: The trouble with awesome

2012-05-25 Thread Moritz Lenz
> My point is that while it > started out as a way to improve/formalize Perl 5, it's developed > sufficiently to the point where it is its own language and not the > "next" version of 'perl'. But it is still a version of Perl. It might not be the "next" version of Perl, but it certainly the sixth

Re: The trouble with awesome

2012-05-25 Thread Siddhant Saraf
Hello Estarde, (since I'm the 'new' guy in the community, I think only I have the energy to explain it to you :-) Well, try to think of Perl 6 as a human. Of course you can change a person's name, but who will go to the trouble of it all? eh? After all, we all know how some Mr. XYZ father likes t

Re: The trouble with awesome

2012-05-25 Thread B. Estrade
First, yes, Perl 6 is awesome. Everything that's come out as a result of this effort is awesome. The rest is inline below. On Fri, May 25, 2012 at 10:32:35AM +0200, Moritz Lenz wrote: > Hallo Parrot, > > we are well aware that the documentation for Perl 6 is quite lacking. > Any contributions i

Re: The trouble with awesome

2012-05-25 Thread Moritz Lenz
Hallo Parrot, we are well aware that the documentation for Perl 6 is quite lacking. Any contributions in that area are greatly appreciated. Am 23.05.2012 01:35, schrieb Parrot Raiser: The problem we have is to provide a path for learning 6, that presents a comprehensible but useful subset of

Re: allow .re and .im to be l-values

2012-05-18 Thread Moritz Lenz
On 05/19/2012 06:05 AM, Siddhant Saraf wrote: > r: my $x = 4 + 2i; $x.re = 5; > rakudo 45679a: OUTPUT«Cannot assign to a non-container␤ in > block at /tmp/PeeJaa8bWJ:1␤␤» > > I think $x.re (Real part of $x) and $x.im (Imaginary part of $x) > should be allowed to be l-values. > What do you sa

<    1   2   3   4   5   6   7   8   9   10   >