Re: [svn:parrot] r31570 - trunk/src/ops

2008-10-02 Thread NotFound
On Thu, Oct 2, 2008 at 11:00 PM, chromatic <[EMAIL PROTECTED]> wrote: > Can anything in the PIO_open() path throw an exception? If so, these strings > will leak. In a first look, it does not throw, but given that it calls layer functions, one never can be sure. But I don't see a better solution

globs and rules and trees, oh my! (was: Re: XPath grammars (Was: Re: globs and trees in Perl6))

2008-10-02 Thread Timothy S. Nelson
On Fri, 3 Oct 2008, Timothy S. Nelson wrote: On Fri, 3 Oct 2008, Timothy S. Nelson wrote: On Thu, 2 Oct 2008, Timothy S. Nelson wrote: Now that Perl6 is in the mix, though, I think that the best way to do it is to make roles that model eg. Nodes, Plexes (Documents), Elements, and the like,

[perl #59112] Failing test in t/examples/library.t

2008-10-02 Thread James Keenan via RT
Forgot to forward to list: On Thu Oct 02 18:37:05 2008, [EMAIL PROTECTED] wrote: > On Wed Oct 01 16:09:41 2008, julianalbo wrote: > > > > > I see a more generic problem. Several modules add lib links to the > > parrot executable. Makes sense to link static libraries if that is the > > intention

Re: globs and trees in Perl6

2008-10-02 Thread Timothy S. Nelson
On Thu, 2 Oct 2008, Moritz Lenz wrote: [snip] It sounds like a perfect idea for a very general library or rather library framework. Perl 6 has all the hooks to install stuff like this. Agree 100%. But I thought it might be useful toget some feedback from others on this; I'd like to see the

Re: XPath grammars (Was: Re: globs and trees in Perl6)

2008-10-02 Thread Timothy S. Nelson
On Fri, 3 Oct 2008, Timothy S. Nelson wrote: On Thu, 2 Oct 2008, Timothy S. Nelson wrote: Now that Perl6 is in the mix, though, I think that the best way to do it is to make roles that model eg. Nodes, Plexes (Documents), Elements, and the like, and then have operators on them do all the wor

XPath grammars (Was: Re: globs and trees in Perl6)

2008-10-02 Thread Daniel Ruoso
Qui, 2008-10-02 às 12:55 +0100, Tim Bunce escreveu: > Like applying XPath to an XML DOM, only more general and taken > further. > By "more general and taken further" I'm thinking of the same kind of > evoltion from simple regular expressions in perl5 to grammars in perl6. > An XPath query is like a

[perl #59560] [PATCH] any-pir p5chomp implementation

2008-10-02 Thread via RT
# New Ticket Created by Ahmad Zawawi # Please include the string: [perl #59560] # in the subject line of all future correspondence about this issue. # http://rt.perl.org/rt3/Ticket/Display.html?id=59560 > Hello, Here is the p5chomp patch that makes the first four tests to pass. To test it, p

[perl #59576] [PATCH] 'property' scope for PAST::Var

2008-10-02 Thread via RT
# New Ticket Created by I Sop # Please include the string: [perl #59576] # in the subject line of all future correspondence about this issue. # http://rt.perl.org/rt3/Ticket/Display.html?id=59576 > I just copied the 'attribute' method, renamed everything, and changed the parameter order for

[perl #59570] $*OS and $*EXECUTABLE_NAME globals initial implementation

2008-10-02 Thread via RT
# New Ticket Created by Ahmad Zawawi # Please include the string: [perl #59570] # in the subject line of all future correspondence about this issue. # http://rt.perl.org/rt3/Ticket/Display.html?id=59570 > Hi, With this patch, $*OS and $*EXECUTABLE_NAME are now working. However, $?... is not

[perl #59556] [PATCH] any-str.pir chomp implementation

2008-10-02 Thread via RT
# New Ticket Created by Ahmad Zawawi # Please include the string: [perl #59556] # in the subject line of all future correspondence about this issue. # http://rt.perl.org/rt3/Ticket/Display.html?id=59556 > Hello, Here is the chomp patch that makes all chomp.t tests pass. To test it, please us

Re: [svn:parrot] r31570 - trunk/src/ops

2008-10-02 Thread chromatic
On Thursday 02 October 2008 13:37:28 [EMAIL PROTECTED] wrote: > Author: julianalbo > Date: Thu Oct 2 13:37:27 2008 > New Revision: 31570 > > Modified: >trunk/src/ops/io.ops > > Log: > some fixes in the open opcode > --- trunk/src/ops/io.ops (original) > +++ trunk/src/ops/io.ops Thu

Re: XPath grammars (Was: Re: globs and trees in Perl6)

2008-10-02 Thread Jon Lang
For tree-oriented pattern matching syntax, I'd recommend for inspiration the RELAX NG Compact Syntax, rather than XPath. Technically, RELAX NG is an XML schema validation language; but the basic principle that it uses is to describe a tree-oriented pattern, and to consider the document to be valid

Re: XPath grammars (Was: Re: globs and trees in Perl6)

2008-10-02 Thread Brandon S. Allbery KF8NH
On Oct 2, 2008, at 10:36 , Timothy S. Nelson wrote: On Thu, 2 Oct 2008, Timothy S. Nelson wrote: Now that Perl6 is in the mix, though, I think that the best way to do it is to make roles that model eg. Nodes, Plexes (Documents), Elements, and the like, and then have operators on them do all

Re: [perl #59542] null hash keys give segfault

2008-10-02 Thread NotFound
> maybe a duplicate of #43485 > > PIR code to reproduce: > > ..sub 'foo' :main > $S0 = null > $P0 = new 'Hash' > # no crash without next line > $P0['yum'] = 5 > $P1 = $P0[$S0] > ..end Fixed in r31566, together with a test adapted from this code. Don't know if is related to #43

Re: [perl #59538] [BUG] imcc freezes (compute_dominance_frontiers) -- Possible fix

2008-10-02 Thread chromatic
On Wednesday 01 October 2008 21:24:39 Stephen Weeks via RT wrote: > Attached is a possible fix of this problem. I'm fairly certain that > it's correct, but I'd like review from at least one other person before > I commit it. It makes sense to me. I wonder if we could re-enable the optimization

Re: [perl #59546] [PATCH] Combine hash exists/get into a new opcode (5% performance gain)

2008-10-02 Thread NotFound
>> > I think will be better the other way, using the return value to flag >> > existence, and passing a pointer to store the result. This will allow >> > shorter and cleaner code. > > Another possibility might be to avoid the extra parameter altogether, > returning NULL (not PMCNULL) if the element

Re: [perl #59546] [PATCH] Combine hash exists/get into a new opcode (5% performance gain)

2008-10-02 Thread Patrick R. Michaud
On Thu, Oct 02, 2008 at 04:51:32PM +0100, Nick Glencross wrote: > NotFound, > > That would look cleaner, wouldn't it? I'll give it a go. > > Nick > > On Thu, Oct 2, 2008 at 3:35 PM, NotFound <[EMAIL PROTECTED]> wrote: > > I think will be better the other way, using the return value to flag > > e

Re: [perl #59546] [PATCH] Combine hash exists/get into a new opcode (5% performance gain)

2008-10-02 Thread Nick Glencross
NotFound, That would look cleaner, wouldn't it? I'll give it a go. Nick On Thu, Oct 2, 2008 at 3:35 PM, NotFound <[EMAIL PROTECTED]> wrote: > I think will be better the other way, using the return value to flag > existence, and passing a pointer to store the result. This will allow > shorter and

Re: [perl #59544] open(null) kills parrot

2008-10-02 Thread NotFound
> (I'd expect an exception to be raised instead.) > > > PIR code: > > ..sub 'foo' :main > $S0 = null > $P0 = open $S0, '<' > ..end > > output: > src/string.c:2106: failed assertion 's' Fixed in r31565 , but several questions opened: Where to put a test for this? There is no t/ops/io.t and

Re: XPath grammars (Was: Re: globs and trees in Perl6)

2008-10-02 Thread Timothy S. Nelson
On Thu, 2 Oct 2008, Timothy S. Nelson wrote: Now that Perl6 is in the mix, though, I think that the best way to do it is to make roles that model eg. Nodes, Plexes (Documents), Elements, and the like, and then have operators on them do all the work (like my idea of using a slash for a combine

Re: globs and trees in Perl6

2008-10-02 Thread Moritz Lenz
Timothy S. Nelson wrote: > Hi all. I've enjoyed(?) reading over the February/March thread > entitled "Musings on operator overloading". I've brought a few thoughts > along; if they're old news, please tell me where to do more reading on it :). > > Over the last year or two, I've di

Re: globs and trees in Perl6

2008-10-02 Thread TSa
HaloO, Tim Bunce wrote: But I have a nagging suspicion that this is a very powerful idea. Applying the expressive power of a grammar-like mechanism to search, backtrack, and match within a tree-like data structure. Is this new or has anyone discussed it before? I've mentioned the idea of usin

Re: [perl #59546] [PATCH] Combine hash exists/get into a new opcode (5% performance gain)

2008-10-02 Thread NotFound
I think will be better the other way, using the return value to flag existence, and passing a pointer to store the result. This will allow shorter and cleaner code. -- Salu2

Re: XPath grammars (Was: Re: globs and trees in Perl6)

2008-10-02 Thread Timothy S. Nelson
On Thu, 2 Oct 2008, Daniel Ruoso wrote: One thing we realized at that time is that XPath is good enough, even if it seems to be adressing XML specifically, it has the concept of "dimension" that can be extended to represent arbitrary aspects of objects. Hmm. Back in March, before I discovere

Re: globs and trees in Perl6

2008-10-02 Thread Timothy S. Nelson
On Thu, 2 Oct 2008, Tim Bunce wrote: The key point Brandon is making, that I'm not sure you're answering, You probably mean "OtherTim" (ie. me) instead of "Brandon" here :). Yeap, sorry Tim. (I've seen comments like this totally confuse everyone, so I thought I'd better mention i

[perl #59552] [PATCH] any-str.pir p5chop implementation

2008-10-02 Thread via RT
# New Ticket Created by Ahmad Zawawi # Please include the string: [perl #59552] # in the subject line of all future correspondence about this issue. # http://rt.perl.org/rt3/Ticket/Display.html?id=59552 > Hello, Here is the p5chop patch that makes our tests pass the first 4 tests. To test it

Re: [perl #59546] [PATCH] Combine hash exists/get into a new opcode (5% performance gain)

2008-10-02 Thread Nick Glencross
All, Sorry, I see that I said opcode a new times, when of course I meant PMC vtable entry. Nick

Re: globs and trees in Perl6

2008-10-02 Thread Tim Bunce
On Thu, Oct 02, 2008 at 07:01:39PM +1000, Timothy S. Nelson wrote: > On Thu, 2 Oct 2008, Tim Bunce wrote: > >> On Wed, Oct 01, 2008 at 11:24:04PM -0400, Brandon S. Allbery KF8NH wrote: >>> On 2008 Oct 1, at 22:23, Timothy S. Nelson wrote: On Wed, 1 Oct 2008, Brandon S. Allbery KF8NH wrote: >>>

[perl #58006] Fix .{"key"} parsefail when (hash index into $_)

2008-10-02 Thread Moritz Lenz via RT
On Sat Aug 16 07:56:04 2008, [EMAIL PROTECTED] wrote: > - likely parser bug (Rakudo grammar.pg) r31561 $ ./rakudo -e '$_ = { a => 1, b => 2}; say .{"b"}' 2 This has been fixed by Patrick some time ago.

[perl #59546] [PATCH] Combine hash exists/get into a new opcode (5% performance gain)

2008-10-02 Thread via RT
# New Ticket Created by Nick Glencross # Please include the string: [perl #59546] # in the subject line of all future correspondence about this issue. # http://rt.perl.org/rt3/Ticket/Display.html?id=59546 > Hi All, This patch adds two new opcodes which allow a hash "exists" and "get" to be p

Re: globs and trees in Perl6

2008-10-02 Thread Tim Bunce
On Wed, Oct 01, 2008 at 11:24:04PM -0400, Brandon S. Allbery KF8NH wrote: > On 2008 Oct 1, at 22:23, Timothy S. Nelson wrote: >> On Wed, 1 Oct 2008, Brandon S. Allbery KF8NH wrote: >>> On 2008 Oct 1, at 22:14, Timothy S. Nelson wrote: Hi all. I've enjoyed(?) reading over the February/March

Re: [perl #59538] [BUG] imcc freezes (compute_dominance_frontiers) -- Possible fix

2008-10-02 Thread NotFound
Looks correct. Tested on Linux i386, parrot test pass, perl6 test pass, test program in the RT does not hang and the generated pbc contains the expected opcodes. Good work! -- Salu2

[perl #59542] null hash keys give segfault

2008-10-02 Thread via RT
# New Ticket Created by I Sop # Please include the string: [perl #59542] # in the subject line of all future correspondence about this issue. # http://rt.perl.org/rt3/Ticket/Display.html?id=59542 > maybe a duplicate of #43485 PIR code to reproduce: ..sub 'foo' :main     $S0 = null     $P0 =

Re: globs and trees in Perl6

2008-10-02 Thread Timothy S. Nelson
On Thu, 2 Oct 2008, Tim Bunce wrote: On Wed, Oct 01, 2008 at 11:24:04PM -0400, Brandon S. Allbery KF8NH wrote: On 2008 Oct 1, at 22:23, Timothy S. Nelson wrote: On Wed, 1 Oct 2008, Brandon S. Allbery KF8NH wrote: On 2008 Oct 1, at 22:14, Timothy S. Nelson wrote: Hi all. I've enjoyed

[perl #59532] say typeof(namespace) gives a segfault

2008-10-02 Thread via RT
# New Ticket Created by I Sop # Please include the string: [perl #59532] # in the subject line of all future correspondence about this issue. # http://rt.perl.org/rt3/Ticket/Display.html?id=59532 > The following PIR code causes a segfault:

[perl #59538] [BUG] imcc freezes (compute_dominance_frontiers) -- Possible fix

2008-10-02 Thread Stephen Weeks via RT
Attached is a possible fix of this problem. I'm fairly certain that it's correct, but I'd like review from at least one other person befor eI commit it. 0001--imcc.patch Description: Binary data

[perl #59544] open(null) kills parrot

2008-10-02 Thread via RT
# New Ticket Created by I Sop # Please include the string: [perl #59544] # in the subject line of all future correspondence about this issue. # http://rt.perl.org/rt3/Ticket/Display.html?id=59544 > (I'd expect an exception to be raised instead.) PIR code: ..sub 'foo' :main     $S0 = null  

[perl #59532] say typeof(namespace) gives a segfault

2008-10-02 Thread NotFound via RT
The problem is that the vtable function get_class return NULL. This is easily fixable, but the root of the problem is that the _class attribute is set in init as PMCNULL, but later it contains NULL.