JIT failure with Fedora

2003-12-11 Thread Peter Gibbs
I have just installed Fedora Core 1 on a Pentium 4 system, and various tests are segfaulting when trying to invoke a compiler. I tracked it down to Parrot_jit_build_call_func. If I undef CAN_BUILD_CALL_FRAMES then all tests pass. Also, everything segfaults using parrot -j. uname -a Linux peter4

Re: Iterating through two arrays at once

2003-12-11 Thread Jonathan Scott Duff
On Wed, Dec 10, 2003 at 11:44:15PM -0500, Joe Gottman wrote: In Perl 6, how will it be possible to iterate through two arrays at the same time? According to Apocalypse 4, the syntax is for @a; @b - $a; $b { According to the book Perl 6 Essentials the syntax is for zip(@a, @b)

Re: [perl #24638] [PATCH] brushup of Getop_Long.imc and getopt_demo.imc

2003-12-11 Thread Leopold Toetsch
Bernhard Schmalhofer [EMAIL PROTECTED] wrote: This patch mostly improves the embedded POD in Getopt_Long.imc and getopt_demo.imc. There are also some code beautifications, including a s/.pcc_sub/.sub/. Thanks, applied. leo

Mac OS X Dynaloading less broken

2003-12-11 Thread Dan Sugalski
If you're on OS X 10.3, I unbroke (sort of) the dynaloading code, so it now uses the platform dlopen call. This handles .dylib files like, say, libncurses.dylib. That's good. The bad news, such as it is, is: *) Still crashes. Ick. a ulimit -c unlimited in the terminal will generate gdb-able

Namespaces

2003-12-11 Thread Dan Sugalski
Okay, okay, I give -- hierarchic namespaces are the way to go. Makes local overrides somewhat interesting, but we'll burn that bridge when we get to it. That does, though, argue that we need to revisit the global access opcodes. If we're going hierarchic, and we want to separate out the name

enums and bitenums

2003-12-11 Thread Stéphane Payrard
Hi, I don't remember anything about enums and bitenums in the apocalypses. This is probably not very difficult to roll out something using macros but I feel that should belong to the standard language. -- stef

Re: enums and bitenums

2003-12-11 Thread Larry Wall
On Thu, Dec 11, 2003 at 02:48:06PM +0100, Stéphane Payrard wrote: : Hi, : : I don't remember anything about enums and bitenums in the : apocalypses. This is probably not very difficult to roll out : something using macros but I feel that should belong to the : standard language. [Warning:

Re: [CVS ci] object stuff

2003-12-11 Thread Jeff Clites
On Dec 10, 2003, at 12:37 AM, Luke Palmer wrote: Dan Sugalski writes: At 05:14 PM 12/5/2003 +0100, Leopold Toetsch wrote: set I2, P1[Foo\x00i] # I1 == I2 gets currently the attribute idx (0) of $Foo::i. Q: Should the assembler mangle the Foo::i to Foo\0i I don't like it either, but the

Re: Namespaces

2003-12-11 Thread Melvin Smith
At 11:57 AM 12/11/2003 -0500, Dan Sugalski wrote: That does, though, argue that we need to revisit the global access opcodes. If we're going hierarchic, and we want to separate out the name from the namespace, that would seem to argue that we'd want it to look like: find_global P1,

Re: [CVS ci] object stuff

2003-12-11 Thread Melvin Smith
I think a heirarchy is a good idea for namespacing in general. I've always wanted to be able to tie namespaces in Perl 5. It would only make sense that if I tie Foo::, that Foo::anything:: would also go through that tie to get the anything:: stash. What do you mean by tie here? Are you talking

Re: Mac OS X Dynaloading less broken

2003-12-11 Thread Jeff Clites
I have some other fixes for this--I'll clean them up and send them in. I got something working which doesn't crash, and which can find libraries in standard locations w/o knowing the path. It uses the native dyld API rather than dlopen--the dlopen which shipped with Panther is just the

Re: Namespaces

2003-12-11 Thread Leopold Toetsch
Dan Sugalski [EMAIL PROTECTED] wrote: find_global P1, ['global', 'namespace', 'hierarchy'], thingname That is, split the namespace path from the name of the thing, and make the namespace path a multidimensional key. Or I suppose we could just punt and toss the special global access

Re: Mac OS X Dynaloading less broken

2003-12-11 Thread Dan Sugalski
At 9:51 AM -0800 12/11/03, Jeff Clites wrote: I have some other fixes for this--I'll clean them up and send them in. I got something working which doesn't crash, and which can find libraries in standard locations w/o knowing the path. It uses the native dyld API rather than dlopen--the dlopen

RE: [CVS ci] object stuff

2003-12-11 Thread Melvin Smith
At 03:05 PM 12/11/2003 -0500, Gordon Henriksen wrote: Melvin Smith [EMAIL PROTECTED] wrote: my $foo = Oracle::Instance::DEV1::db_block_buffers; The namespace lookup in Oracle::Init checks the Oracle config parameters which is external code. All sorts of neat possibilities. :) It is truly

RE: Namespaces

2003-12-11 Thread Gordon Henriksen
Leopold Toetsch [EMAIL PROTECTED] wrote: Dan Sugalski [EMAIL PROTECTED] wrote: Okay, okay, I give -- hierarchic namespaces are the way to go. Makes local overrides somewhat interesting, but we'll burn that bridge when we get to it. find_global P1, ['global', 'namespace',

RE: [CVS ci] object stuff

2003-12-11 Thread Gordon Henriksen
Melvin Smith [EMAIL PROTECTED] wrote: my $foo = Oracle::Instance::DEV1::db_block_buffers; The namespace lookup in Oracle::Init checks the Oracle config parameters which is external code. All sorts of neat possibilities. :) It is truly remarkable the lengths that Perl programmers seem to

Re: More object stuff

2003-12-11 Thread Harry Jackson
Dan Sugalski wrote: Yep, though that's a big part of it. postgres.pasm is generated from postgres.declarations, FWIW--there's a script in the library somewhere. Is /parrot/build_tools/build_nativecall.pl the script in question and if so whats its usage. I have done postgres.declarations, please

Re: enums and bitenums

2003-12-11 Thread Michael Lazzaro
On Thursday, December 11, 2003, at 10:04 AM, Larry Wall wrote: Explicitly: $bar.does(Color)# does $bar know how to be a Color? $bar.as(Color) # always cast to Color Implicitly boolean: $bar ~~ Color # $bar.does(Color) ?$bar.Color # $bar.does(Color) if

Re: enums and bitenums

2003-12-11 Thread Luke Palmer
Larry Wall writes: Anyway, this all implies that use of a role as a method name defaults to returning whether the type in question matches the subtype. That is, when you say $foo.true it's asking whether the Boolean property fulfills the true constraint. When you say $bar.red

Re: enums and bitenums

2003-12-11 Thread Larry Wall
On Thu, Dec 11, 2003 at 02:01:17PM -0800, Michael Lazzaro wrote: : So Cas would be for casting, not coercion, right? : : Suppose you have a class Foo, such that: : : class Foo does (Bar, Baz) { : ... : } : : ... or however that looks. May I then presume that : : $foo.Bar.zap

Re: enums and bitenums

2003-12-11 Thread Larry Wall
On Thu, Dec 11, 2003 at 04:18:19PM -0700, Luke Palmer wrote: : Larry Wall writes: : Anyway, this all implies that use of a role as a method name defaults to : returning whether the type in question matches the subtype. That is, : when you say : : $foo.true : : it's asking whether the

Re: enums and bitenums

2003-12-11 Thread Uri Guttman
LW == Larry Wall [EMAIL PROTECTED] writes: Or are you worried that these have to be declared at all? I think we need to declare them or we can't use them as bare identifiers. There are no barewords in Perl 6, so they have to be something predeclared, or otherwise syntactically

Re: enums and bitenums

2003-12-11 Thread Larry Wall
On Thu, Dec 11, 2003 at 04:18:19PM -0700, Luke Palmer wrote: : Larry Wall writes: : Anyway, this all implies that use of a role as a method name defaults to : returning whether the type in question matches the subtype. That is, : when you say : : $foo.true : : it's asking whether the

roles (Was: enums and bitenums)

2003-12-11 Thread Jonathan Lang
I'm invoking the principle that the only stupid question is the one not asked: Larry Wall wrote: if indeed properties can be unified with roles (and roles with classes). Based on the source material pointed to as your inspiration for roles, I'm a little confused as to how roles and classes

RE: [CVS ci] object stuff

2003-12-11 Thread chromatic
On Thu, 2003-12-11 at 12:05, Gordon Henriksen wrote: It is truly remarkable the lengths that Perl programmers seem to be willing go to in order to hide a function call or obscure the existence of an object. :) Not all of the poly- and allomorphism in the world comes from traditional object

Re: Namespaces

2003-12-11 Thread Leopold Toetsch
Gordon Henriksen [EMAIL PROTECTED] wrote: Leopold Toetsch [EMAIL PROTECTED] wrote: What about: getinterp P2 set P1, P2['global';'namespace';'hierarchy';'thingname'] What if global.namespace happens to be autoloaded or otherwise magic? Will the get_keyed break down and do something

Macros, PIR, and PASM

2003-12-11 Thread Dan Sugalski
Folks, As IMCC's in some flux and likely to get gutted and reworked, the question of macros has come up. (They cause some grammar issues) So, to make life easier: Parrot's built-in PIR and PASM parsing modules do *not* need to do macros. (Though they do need to do .const things) Macro

Re: Namespaces

2003-12-11 Thread Dan Sugalski
At 12:34 PM -0500 12/11/03, Melvin Smith wrote: At 11:57 AM 12/11/2003 -0500, Dan Sugalski wrote: That does, though, argue that we need to revisit the global access opcodes. If we're going hierarchic, and we want to separate out the name from the namespace, that would seem to argue that we'd

Re: Macros, PIR, and PASM

2003-12-11 Thread Melvin Smith
At 06:06 PM 12/11/2003 -0500, Dan Sugalski wrote: Folks, As IMCC's in some flux and likely to get gutted and reworked, the question of macros has come up. (They cause some grammar issues) So, to make life easier: Parrot's built-in PIR and PASM parsing modules do *not* need to do macros.

Re: roles (Was: enums and bitenums)

2003-12-11 Thread Paul Hodges
--- Jonathan Lang [EMAIL PROTECTED] wrote: Incidently, I think I've caught on to _one_ of the concepts in the upcoming object-orientation proposal: linguistically, there's a triad of basic verbs - namely be, do, and have. If I'm following things properly, one could think of an object's

Re: roles (Was: enums and bitenums)

2003-12-11 Thread chromatic
On Thu, 2003-12-11 at 18:15, Jonathan Lang wrote: Based on the source material pointed to as your inspiration for roles, I'm a little confused as to how roles and classes could be unified. From what I read in the source material, a key point of a role (well, they weren't actually calling it

Re: roles (Was: enums and bitenums)

2003-12-11 Thread Jonathan Lang
Paul Hodges wrote: Jonathan Lang [EMAIL PROTECTED] wrote: Incidently, I think I've caught on to _one_ of the concepts in the upcoming object-orientation proposal: linguistically, there's a triad of basic verbs - namely be, do, and have. If I'm following things properly, one could think