Re: [Patch] Win32 thread primitives

2005-05-03 Thread Vladimir Lipsky
threads_4 is testing killing threads. This is achieved by scheduling a terminate event to the running interpreter. This can only succeed, if the event system is running too. see src/events.c/Parrot_new_terinate_event() Though thr_windows.h doesn't contain error checking for now, it luckily

Re: Open and pipe

2005-05-03 Thread Larry Wall
On Mon, May 02, 2005 at 10:51:57PM -0400, Uri Guttman wrote: : LW == Larry Wall [EMAIL PROTECTED] writes: : : LW multi sub opensocket ( : LW Str +$mode = 'rw', : LW Str +$encoding = 'auto', : LW Str [EMAIL PROTECTED]) returns IO; : :

Re: Open and pipe

2005-05-03 Thread Larry Wall
On Mon, May 02, 2005 at 03:53:42PM -0700, Larry Wall wrote: : On Tue, May 03, 2005 at 12:32:58AM +0200, Juerd wrote: : : How about : : : : open ::= File::open : : URI::open : : Sys::Pipe::open : : : : And put the other aliases in the module that CGI.pm-:standard-ishly : : pollutes

Re: subtype declarations

2005-05-03 Thread Larry Wall
On Mon, May 02, 2005 at 03:04:57AM -0600, Luke Palmer wrote: : S12 says: : : subtype Str_not2b of Str where /^[isnt|arent|amnot|aint]$/; : : My brain parses this as: : : subtype Str_not2b[Str where /.../]; : : Or: : : subtype Str_not2b[Str] where /.../; : : Neither of which

Re: Code classes

2005-05-03 Thread Larry Wall
On Mon, May 02, 2005 at 05:42:47PM -0700, Larry Wall wrote: : We're still discussing it on @Larry, but I think we can make that work. Well, now I think .foo() won't work, since .foo should be reserved for a sub ref attribute to be consistent. But I think all we have to do is find some other

Re: Code classes

2005-05-03 Thread Thomas Sandlaß
Larry Wall wrote: On Mon, May 02, 2005 at 05:42:47PM -0700, Larry Wall wrote: : We're still discussing it on @Larry, but I think we can make that work. Sorry if I don't know, but where or what is @Larry? I guess some IRC? Well, now I think .foo() won't work, since .foo should be reserved for a

Re: [Patch] Win32 thread primitives

2005-05-03 Thread Leopold Toetsch
Vladimir Lipsky wrote: threads_4 is testing killing threads. This is achieved by scheduling a terminate event to the running interpreter. This can only succeed, if the event system is running too. see src/events.c/Parrot_new_terinate_event() Though thr_windows.h doesn't contain error checking

[svn meta] sorry

2005-05-03 Thread Leopold Toetsch
Sorry, I forgot to attach necessary legal bits to the last two patches I applied: new n_arithmetics tests Courtesy of Bob Rogers [Patch] Win32 thread primitives Courtesy of Vladimir Lipsky leo

Re: Code classes

2005-05-03 Thread Luke Palmer
Thomas Sandla writes: Larry Wall wrote: On Mon, May 02, 2005 at 05:42:47PM -0700, Larry Wall wrote: : We're still discussing it on @Larry, but I think we can make that work. Sorry if I don't know, but where or what is @Larry? Ahh, you came in too late. I don't remember who coined it, but

Re: Open and pipe

2005-05-03 Thread Juerd
Larry Wall skribis 2005-05-02 15:53 (-0700): : Starting to look a lot like PHP there. And I care about that because PHP is such an unsuccessful language? :-) I'd just like all the opens to sort to the same place in the manual. One of my biggest problems with PHP is that it puts in the name of

Type system questions.

2005-05-03 Thread Autrijus Tang
With the recent discussion on type sigils, and the fact that Pugs is moving toward the OO core, I'd like to inquire how the following statements evaluate (or not): # Compile time type arithmetic? ::Dual ::= ::Str | ::Num; $*Dual ::= ::Str | ::Num; # Run time type arithmetic?

Re: LABELS: block

2005-05-03 Thread Juerd
Larry Wall skribis 2005-05-02 19:02 (-0700): In any event, none of the proposals that bury the label is going to be acceptable. As a vital visual element of control flow, the label has to be out front where it can be seen. Something that putting quotes around them accomplishes... (I'd still

Re: Open and pipe

2005-05-03 Thread Luke Palmer
Juerd writes: : I don't think the command should default to $_ : Why?! Because $_ is primarily for the use of inner loops, not outer loops, and open tends to be in the outer loop rather than the inner loop. As someone who tries to write clean code, I agree that the outer loop should

Re: Open and pipe

2005-05-03 Thread Juerd
Luke Palmer skribis 2005-05-03 1:34 (-0600): for @files { open; say uc for =$_; close; } Wait, so you want open to both open the filename in $_ /and/ set $_ to the opened filehandle? You are right. The example code makes no sense at all. say uc for =io($_); I didn't know io was

Re: Code classes

2005-05-03 Thread Thomas Sandlaß
Luke Palmer wrote: Ahh, you came in too late. I don't remember who coined it, but @Larry is the array of Larrys, that is, the design team. Aha. What does [EMAIL PROTECTED] evaluate to? How do the elements of @Larry communicate? I agree with you there. $Larry has said that he wants `when` to

Re: [Patch] Win32 thread primitives

2005-05-03 Thread Vladimir Lipsky
And on the third hand, if I understood the code correctly ... src/threads.c: 40: thread_func() src/threads.c: 53: interpreter-thread_data-state |= THREAD_STATE_FINISHED; src/threads.c: 312: pt_thread_join () src/threads.c: 321: if (interpreter-thread_data-state == THREAD_STATE_JOINABLE ||

Re: [Patch] Win32 thread primitives

2005-05-03 Thread Leopold Toetsch
Vladimir Lipsky wrote: It's state is set to PREVIOUS_STATE+FINISHED So it's never equal to just FINISHED Ah, Yep. Works for JOINABLE, which is 0, but ... Typo or what? Inexact ;-) leo

Re: Pugs on Cygwin

2005-05-03 Thread Rob Kinyon
Gaal - I pulled svn r2461 and it does compile on cygwin, yes. But, the @INC problem is still there, preventing 'make test' from running successfully. Do you want me to look at that? Rob On 5/2/05, Gaal Yahas [EMAIL PROTECTED] wrote: On Mon, May 02, 2005 at 09:06:42AM -0400, Rob Kinyon

Re: Pugs on Cygwin

2005-05-03 Thread Autrijus Tang
On Tue, May 03, 2005 at 07:36:24AM -0400, Rob Kinyon wrote: I pulled svn r2461 and it does compile on cygwin, yes. But, the @INC problem is still there, preventing 'make test' from running successfully. Do you want me to look at that? Please do, thanks. :-) Also there is the problem with

[Fwd: [PROPOSAL] call syntax abstraction]

2005-05-03 Thread Aaron Sherman
From a Perl 6 perspective, we should probably read this and think about what this gives us, and what it doesn't. Parrot doesn't have to support everything in Perl's calling conventions, but it has to support enough so that Perl's invocations are efficient. -- Aaron Sherman [EMAIL PROTECTED]

[PROPOSAL] call syntax abstraction

2005-05-03 Thread Leopold Toetsch
Below is a POD that tries to the describe an extensible calling scheme that should cover most of our targets HLLs call syntax. Comments welcome, leo =head1 TITLE Calling convention abstraction =head1 ABSTRACT The current Parrot calling conventions as described in

Re: Code classes

2005-05-03 Thread Aaron Sherman
On Tue, 2005-05-03 at 05:33, Thomas Sandlaß wrote: Luke Palmer wrote: BTW, what does $.foo outside of class scope mean? It means: BEGIN { die Can't use \$.foo outside of class scope; } That contradicts $Larry's statement: By the way, this probably goes along with a policy of

Re: Code classes

2005-05-03 Thread Larry Wall
On Tue, May 03, 2005 at 07:59:19AM -0400, Aaron Sherman wrote: : I like the idea that $.foo ALWAYS means the $.foo in the current class. : Anything else gets very ugly later on. Well, since I'm not going with for self, I'm probably not going with the $.foo meaning anything outside of the class

Re: Open and pipe

2005-05-03 Thread Larry Wall
On Tue, May 03, 2005 at 11:22:06AM +0200, Juerd wrote: : I didn't know io was blessed already. It pretty much is, just not the subsequent overloading of and . We'll use == and == instead. Larry

Re: Code classes

2005-05-03 Thread Aaron Sherman
On Tue, 2005-05-03 at 08:07, Larry Wall wrote: On Tue, May 03, 2005 at 07:59:19AM -0400, Aaron Sherman wrote: : On a side note about auto-accessors, if I say: : : class X { : has $.foo; : } : class Y is X { : has %.foo; : } : : What happens to

Re: Type system questions.

2005-05-03 Thread Larry Wall
On Tue, May 03, 2005 at 05:06:15PM +0800, Autrijus Tang wrote: : With the recent discussion on type sigils, and the fact that Pugs : is moving toward the OO core, I'd like to inquire how the following : statements evaluate (or not): : : # Compile time type arithmetic? : ::Dual ::= ::Str |

Re: Code classes

2005-05-03 Thread Larry Wall
On Tue, May 03, 2005 at 08:29:22AM -0400, Aaron Sherman wrote: : On Tue, 2005-05-03 at 08:07, Larry Wall wrote: : On Tue, May 03, 2005 at 07:59:19AM -0400, Aaron Sherman wrote: : : : On a side note about auto-accessors, if I say: : : : : class X { : : has $.foo; : : } : :

should push (etc) be available via extend.h ?

2005-05-03 Thread Nicholas Clark
Should There be a Parrot_PMC_push_pmc() [and friends?] in extend.h to allow parrot-extending code direct access to those vtable methods? Eventually, should extend.h contain methods to make calls on all public vtable methods? Nicholas Clark

Re: should push (etc) be available via extend.h ?

2005-05-03 Thread Leopold Toetsch
Nicholas Clark wrote: Should There be a Parrot_PMC_push_pmc() [and friends?] in extend.h to allow parrot-extending code direct access to those vtable methods? Eventually, should extend.h contain methods to make calls on all public vtable methods? Yep. Think so. But note that all vtables denoted

Re: surprising consequences

2005-05-03 Thread Larry Wall
On Mon, Apr 25, 2005 at 02:37:40PM -0500, Rod Adams wrote: : Something that crossed my mind while writing this: Does : :for { say } == @a; : : Work? Nope. The brackets where a term is expected would be misconstrued as an argument to the for. Maybe we need an @= for a placeholder: for

Re: use junction

2005-05-03 Thread Juerd
Larry Wall skribis 2005-05-03 6:22 (-0700): sub foo (IntStr block) {...} sub foo (:(IntStr) block) {...} Alternately, we install a small heuristic and document it in the fine print. I personally would not mind requiring whitespace around in those cases. If parens are used for the

Re: should push (etc) be available via extend.h ?

2005-05-03 Thread Nicholas Clark
On Tue, May 03, 2005 at 02:55:22PM +0200, Leopold Toetsch wrote: Nicholas Clark wrote: Should There be a Parrot_PMC_push_pmc() [and friends?] in extend.h to allow parrot-extending code direct access to those vtable methods? Eventually, should extend.h contain methods to make calls on all

Re: Type system questions.

2005-05-03 Thread Autrijus Tang
On Tue, May 03, 2005 at 05:32:44AM -0700, Larry Wall wrote: : # Type Instantiation? : sub apply (fun::a returns ::b, ::a $arg) returns ::b { : fun($arg); : } The first parameter would be fun:(::a) these days, but yes. (Stylistically, I'd leave the off the call.) So, the

Re: object/method tailcalls ?

2005-05-03 Thread Leopold Toetsch
Bob Rogers wrote: How about extending .return to cover these: .return foo(x, ...) # tail function call .return o.foo(x, ...) # tail method call Done - rev 7959. More tests are welcome, as always. See imcc/t/syn/tail.t for existing ones. leo

Yet Another TODO Model for Test.pm

2005-05-03 Thread Stevan Little
The ongoing search to find a good model for TODO tests in Pugs continues ... To start with, the idea of some kind of switch to turn all failures into TODOs has been removed. It was a bad idea from the start and since it never actually was implemented, I have ditched it entirely. Second, I

Re: use junction

2005-05-03 Thread Thomas Sandlaß
Juerd wrote: I personally would not mind requiring whitespace around in those cases. Same here. Actually the whitespace after makes the destinction, or not? If parens are used for the grouping, then why is the colon required? Because it escapes into type-space like ::() escapes into name-space

Re: Code classes

2005-05-03 Thread David Wheeler
On May 3, 2005, at 00:04 , Luke Palmer wrote: I agree with you there. $Larry has said that he wants `when` to work Shouldn't that be @Larry[0]? Cheers, David smime.p7s Description: S/MIME cryptographic signature

Re: Code classes

2005-05-03 Thread Larry Wall
On Tue, May 03, 2005 at 09:00:49AM -0700, David Wheeler wrote: : On May 3, 2005, at 00:04 , Luke Palmer wrote: : : I agree with you there. $Larry has said that he wants `when` to work : : Shouldn't that be @Larry[0]? That depends on whether you think the rest of them are pushy or shiftless.

Re: Yet Another TODO Model for Test.pm

2005-05-03 Thread Nathan Gray
On Tue, May 03, 2005 at 10:36:40AM -0400, Stevan Little wrote: The ongoing search to find a good model for TODO tests in Pugs continues ... To start with, the idea of some kind of switch to turn all failures into TODOs has been removed. It was a bad idea from the start and since it never

Re: Type system questions.

2005-05-03 Thread Thomas Sandlaß
Autrijus Tang wrote: On Tue, May 03, 2005 at 05:32:44AM -0700, Larry Wall wrote: : # Type Instantiation? : sub apply (fun::a returns ::b, ::a $arg) returns ::b { : fun($arg); : } The first parameter would be fun:(::a) these days, but yes. (Stylistically, I'd leave the off the

Re: should push (etc) be available via extend.h ?

2005-05-03 Thread chromatic
On Tue, 2005-05-03 at 14:48 +0100, Nicholas Clark wrote: And should they eventually even be autogenerated ;) Now, that bit I agree with. A task for someone who likes writing perl? I like writing Perl. Where can I find the source information, where should I write it, and how should it look?

Re: Yet Another TODO Model for Test.pm

2005-05-03 Thread Stevan Little
Nathan, On May 3, 2005, at 12:32 PM, Nathan Gray wrote: On Tue, May 03, 2005 at 10:36:40AM -0400, Stevan Little wrote: The ongoing search to find a good model for TODO tests in Pugs continues ... To start with, the idea of some kind of switch to turn all failures into TODOs has been removed. It

[perl #35195] [PATCH] @MAIN defined twice - behavior documented and tested

2005-05-03 Thread via RT
# New Ticket Created by jerry gay # Please include the string: [perl #35195] # in the subject line of all future correspondence about this issue. # URL: https://rt.perl.org/rt3/Ticket/Display.html?id=35195 i couldn't find documentation on the behavior of IMCC if the @MAIN subpragma was

New version of PGE released

2005-05-03 Thread Patrick R. Michaud
The short story --- I've just committed a new, rewritten version of PGE to the Parrot repository. It's still somewhat preliminary and many rule features are still missing. On the other hand, it's now written entirely in PIR (no more C compiling!) and provides a stronger base

Pugs now embeds Parrot.

2005-05-03 Thread Autrijus Tang
Because I want to embed PGE in Pugs, I end up embedding the entire libparrot. :-) As of two hours ago, if you set the PUGS_EMBED environment variable to parrot and run perl Makefile.PL, Pugs will build and link against Parrot, and provide a require_parrot() primitive for you. JIT works as one

Re: Pugs now embeds Parrot.

2005-05-03 Thread Rob Kinyon
Will this change remove the need for pugscc to be cygpath'ed on cygwin? Or, should I go ahead and work on this? Rob On 5/3/05, Autrijus Tang [EMAIL PROTECTED] wrote: Because I want to embed PGE in Pugs, I end up embedding the entire libparrot. :-) As of two hours ago, if you set the

Re: Pugs now embeds Parrot.

2005-05-03 Thread Autrijus Tang
On Tue, May 03, 2005 at 03:46:54PM -0400, Rob Kinyon wrote: Will this change remove the need for pugscc to be cygpath'ed on cygwin? Or, should I go ahead and work on this? Please go ahead -- pugscc will still be needed to create native executables without using parrot. Thanks, /Autirjus/

Re: New version of PGE released

2005-05-03 Thread Nicholas Clark
On Tue, May 03, 2005 at 02:33:25PM -0500, Patrick R. Michaud wrote: [snip the good bit] Three cheers for Patrick. Boo hiss to real life, especially when it gets in the way. Not yet implemented, but coming soon (rough priority order): - updated test harness/test suite - cut operations

Re: New version of PGE released

2005-05-03 Thread Autrijus Tang
On Tue, May 03, 2005 at 09:22:11PM +0100, Nicholas Clark wrote: Whilst I confess that it's unlikely to be me here, if anyone has the time to contribute some help, do you have a list of useful self-contained tasks that people might be able to take on? Following some discussion on #perl6, it

Re: should push (etc) be available via extend.h ?

2005-05-03 Thread Nicholas Clark
On Tue, May 03, 2005 at 10:35:50AM -0700, chromatic wrote: On Tue, 2005-05-03 at 14:48 +0100, Nicholas Clark wrote: And should they eventually even be autogenerated ;) Now, that bit I agree with. A task for someone who likes writing perl? I like writing Perl. Where can I find the

Perl 6 Summary for 2004-04-26 through 2005-05-03

2005-05-03 Thread Matt Fowles
Perl 6 Summary for 2004-04-26 through 2005-05-03 All~ Welcome to another weeks summary. This week I shall endeavor not to accidentally delete my summary or destroy the world. So here we go with p6c. Perl 6 Compilers implicit $_ on for loops Kiran Kumar found a bug in

disassemble segfaults

2005-05-03 Thread Bob Rogers
. . . but I can't figure out why. I thought the patch below would help, but it appears that the value of c is itself broken somehow. . . . This GDB was configured as i586-suse-linux... (gdb) r runtime/parrot/library/config.pbc Starting program: /usr/src/parrot/disassemble

Re: disassemble segfaults

2005-05-03 Thread Matt Fowles
Bob~ On 5/3/05, Bob Rogers [EMAIL PROTECTED] wrote: . . . but I can't figure out why. I thought the patch below would help, but it appears that the value of c is itself broken somehow. . . . This GDB was configured as i586-suse-linux... (gdb) r

Re: Test::Builder change BAILOUT - BAIL_OUT

2005-05-03 Thread chromatic
On Tue, 2005-05-03 at 15:36 -0700, Michael G Schwern wrote: Test::Simple/More/Builder 0.61 will introduce a change to Test::Builder whereby the BAILOUT() method becomes BAIL_OUT(). Additionally Test::More finally features a BAIL_OUT() function. Using cpansearch [1] I've determined that you

Re: Test::Builder change BAILOUT - BAIL_OUT

2005-05-03 Thread Michael G Schwern
On Tue, May 03, 2005 at 09:23:01PM -0700, chromatic wrote: Parrot bundles Test::Builder 0.11 (from Test-Simple 0.41). Is it worth upgrading? Couldn't hurt. A whole mess of is_deeply() bugs have been fixed since 0.41. -- Michael G Schwern [EMAIL PROTECTED]

Re: New version of PGE released

2005-05-03 Thread Patrick R. Michaud
On Tue, May 03, 2005 at 09:22:11PM +0100, Nicholas Clark wrote: Whilst I confess that it's unlikely to be me here, if anyone has the time to contribute some help, do you have a list of useful self-contained tasks that people might be able to take on? Very good question -- I can probably come

Re: PMC flags

2005-05-03 Thread Leopold Toetsch
Aaron Sherman wrote: On Mon, 2005-05-02 at 08:58 +0200, Leopold Toetsch wrote: The vtable functions Cisa and Cdoes, which take now a string, are a bit heavy-weighted and might get an extension in the log run that take an integer flag. Unless this happens, this would be a HUGE performance hit.