[patch] no strict for -e scripts

2006-10-16 Thread Sean O'Rourke
The enclosed patch removes strict 'vars' for -e scripts via the nonstandard $?STRICT variable. /s Index: src/Pugs/Eval.hs === --- src/Pugs/Eval.hs (revision 13160) +++ src/Pugs/Eval.hs (working copy) @@ -268,6 +268,10 @@ -- Reduction

Re: take: bug or feature?

2006-12-18 Thread Sean O'Rourke
Ovid <[EMAIL PROTECTED]> writes: > Did something break? If so, I'll add a test. Otherwise, what's > wrong with this code? I noticed this as well, and believe it's a bug -- pugs accepts the code if you remove all the newlines. Then again, I'm not sure this is the desired behavior: pugs> grou

Re: GC design

2002-05-26 Thread Sean O'Rourke
On Sun, 26 May 2002, Peter Gibbs wrote: > "Mike Lambert" wrote: > > > I know Dan's proposed solution has already been committed, but I'd > > like to add my support for this. In addition to providing a counter per > > opcode to ensure that we don't prematurely GC data, this field could also > > be

Re: GC design

2002-05-27 Thread Sean O'Rourke
On Mon, 27 May 2002, Jerome Vouillon wrote: > On Sun, May 26, 2002 at 08:20:23AM -0700, Sean O'Rourke wrote: > > I'm sure it's been discussed before somewhere, but why can't we guarantee > > that we only do GC runs between ops? Each op would just have to guara

Re: GC design

2002-05-28 Thread Sean O'Rourke
On Tue, 28 May 2002, Jerome Vouillon wrote: > That's an interesting point, actually. What is the right thing to do > when we run out of memory? > - Abort immediately. > This is not very user-friendly. > - Return a special value. > But then we need to check the return value of almost all funct

Re: Stack

2002-06-05 Thread Sean O'Rourke
Another thing to toss into the discussion, preferably sooner rather than later: continuations. From what I can tell, implementing continuations relies on having an arbitrary graph of "stack" frames, and garbage collecting them when they can no longer be reached. Putting continuations on top of a

Re: Perl6 grammar

2002-06-18 Thread Sean O'Rourke
Based on perlop(1) and the note at the end of apocalypse 3, here's a start on a Parse::RecDescent grammar for Perl 6 expressions. It does not handle some variables; in particular, qq/${"foo"}/ won't fly. It should handle precedence and hyping when adding new operators in the "right way". To add

Re: extension API

2002-06-26 Thread Sean O'Rourke
On Wed, 26 Jun 2002, Dave Goehrig wrote: > 1.) Data creation function having both of the following properties: > a.) Create & register new PMCs > b.) Toggle GC on/off > > say with the following API for sake of arugment: > let TYPE be either a char* or

Re: Perl 6 grammar progress?

2002-06-30 Thread Sean O'Rourke
On Sun, 30 Jun 2002, Ashley Winters wrote: > I don't know how the grammars are going, and I'm not fit to write one > myself, Hey, neither am I, but that hasn't stopped me from taking a stab or two, figuring that through pain comes fitness. The attempt has certainly given me a much better unders

Re: Reflection...

2002-07-05 Thread Sean O'Rourke
On 5 Jul 2002 [EMAIL PROTECTED] wrote: > dan <[EMAIL PROTECTED]> writes: > > > At 8:29 AM -0700 7/4/02, Sean O'Rourke wrote: > > >Sick. Anyways, I think it seems like a more natural way to do things than > > >traditional call/cc. "$block.continuat

Re: Reflection...

2002-07-04 Thread Sean O'Rourke
On 4 Jul 2002 [EMAIL PROTECTED] wrote: > Dan Sugalski <[EMAIL PROTECTED]> writes: > > > At 8:32 AM +0100 7/3/02, [EMAIL PROTECTED] wrote: > > > > > >For true scariness, consider: > > > > > > $sub.current_continuation($new_continuation); > > > > > Some days you really, really scare me Piers...

[netlabs #769] [PATCH] let imcc use "if PMC, label"

2002-07-07 Thread Sean O'Rourke
# New Ticket Created by "Sean O'Rourke" # Please include the string: [netlabs #769] # in the subject line of all future correspondence about this issue. # http://bugs6.perl.org/rt2/Ticket/Display.html?id=769 > imcc currently only seems to support string and integer compar

[netlabs #770] [PATCH] imcc strangeness

2002-07-07 Thread Sean O'Rourke
# New Ticket Created by "Sean O'Rourke" # Please include the string: [netlabs #770] # in the subject line of all future correspondence about this issue. # http://bugs6.perl.org/rt2/Ticket/Display.html?id=770 > simplify() was getting called with no arguments, but expecting

Re: vtables and multimethod dispatch

2002-07-07 Thread Sean O'Rourke
On Sun, 7 Jul 2002, Dan Sugalski wrote: > Basically what we need is a lookup matrix for each vtable method > (add, subtract, multiply, whatever) that we can index by left and > right types to get the actual method to call. I suppose resolution based on distance in number-of-args dimensional type

Re: Reflection...

2002-07-08 Thread Sean O'Rourke
On 8 Jul 2002 [EMAIL PROTECTED] wrote: > caller with no args is the same as C (for certain values of > 'the same as'), caller(0) already returns the current execution > context. You're right. I stand corrected. > > If you can set a block's continuation at runtime, I think you should be > > able

[netlabs #791] [PATCH] add some ops to core.ops

2002-07-10 Thread Sean O'Rourke
# New Ticket Created by "Sean O'Rourke" # Please include the string: [netlabs #791] # in the subject line of all future correspondence about this issue. # http://bugs6.perl.org/rt2/Ticket/Display.html?id=791 > This patch adds several ops that exist in the vtables, an

[netlabs #792] [PATCH] add some ops to Perl PMC's

2002-07-10 Thread Sean O'Rourke
# New Ticket Created by "Sean O'Rourke" # Please include the string: [netlabs #792] # in the subject line of all future correspondence about this issue. # http://bugs6.perl.org/rt2/Ticket/Display.html?id=792 > This patch does the following: - add defined() to PerlUndef

[netlabs #793] [PATCH] bitshift operations on PMC's

2002-07-11 Thread Sean O'Rourke
# New Ticket Created by "Sean O'Rourke" # Please include the string: [netlabs #793] # in the subject line of all future correspondence about this issue. # http://bugs6.perl.org/rt2/Ticket/Display.html?id=793 > This patch adds shl and shr for PMC's.

[netlabs #801] [PATCH] PerlArray in scalar context

2002-07-11 Thread Sean O'Rourke
# New Ticket Created by "Sean O'Rourke" # Please include the string: [netlabs #801] # in the subject line of all future correspondence about this issue. # http://bugs6.perl.org/rt2/Ticket/Display.html?id=801 > This patch makes the following behave as it does in Perl 5: @a

Re: Perl6 grammar (take V)

2002-07-11 Thread Sean O'Rourke
It's time for my weekly post to this old thread. The grammar has grown enough to deserve more than one file, and is starting to change in new directions. For example, it's now Turing-complete, if you have a Parrot engine and a bit of spare time. Call it a primitive "demo version" of some of Per

clean up core.ops

2002-07-12 Thread Sean O'Rourke
The situation with set vs. set_keyed vs. set_keyed_integer is pretty foul now. The last half of core.ops has a bunch of set() functions and, corresponding to (most of) them, set_keyed_integer() functions with the exact same arguments and bodies. From what I gather, the 3-argument set() functions

Re: Parrot contribution

2002-07-13 Thread Sean O'Rourke
On Sat, 13 Jul 2002, John Porter wrote: > > Ask Bjoern Hansen wrote: > > [EMAIL PROTECTED] (John Porter) writes: > > > > > Yeah, look at the so-called Parrot FAQ. Someone needs to > > > get serious and make a real FAQ for parrot developers. > > > > I'm sure noone would mind if you start one! > >

[perl #813] [PATCH] update IMCC to use keyed ops

2002-07-14 Thread Sean O'Rourke
# New Ticket Created by "Sean O'Rourke" # Please include the string: [perl #813] # in the subject line of all future correspondence about this issue. # http://bugs6.perl.org/rt2/Ticket/Display.html?id=813 > - updates IMCC to use keyed ops for spilling - fixes a spelling

[perl #814] [PATCH] fix PMC type morphing

2002-07-14 Thread Sean O'Rourke
# New Ticket Created by "Sean O'Rourke" # Please include the string: [perl #814] # in the subject line of all future correspondence about this issue. # http://bugs6.perl.org/rt2/Ticket/Display.html?id=814 > PerlString sets the PMC_is_buffer_ptr_FLAG flag in pmc->flags,

Re: [perl #814] [PATCH] fix PMC type morphing

2002-07-14 Thread Sean O'Rourke
On Sun, 14 Jul 2002, Mike Lambert wrote: > There currently is a 'morph' vtable entry, which I believe is intended to > morph from one vtable type to another. I think it'd be better to implement > this function properly than to use macros (talk to Robert ;), especially > considering that certain vt

[perl #815] [PATCH] fix assembler's floating-point constant RE

2002-07-14 Thread Sean O'Rourke
# New Ticket Created by "Sean O'Rourke" # Please include the string: [perl #815] # in the subject line of all future correspondence about this issue. # http://bugs6.perl.org/rt2/Ticket/Display.html?id=815 > Should handle things like "1e8", but it now r

RE: Perl6 grammar (take V)

2002-07-14 Thread Sean O'Rourke
On Sun, 14 Jul 2002, Brent Dax wrote: > Deborah Ariel Pickett: > # My perl5 sensibilities tell me that that's likely to cause a > # problem when I want to do something like this: > # > # $hashref = { function_returning_hash() }; > # > # because I won't get the function's return values put into a

Re: hyper operators - appalling proposal

2002-07-15 Thread Sean O'Rourke
On Mon, 15 Jul 2002, Luke Palmer wrote: > On Mon, 15 Jul 2002, Karl Glazebrook wrote: > > > @solution = (^-@b + sqrt(@b^**2 ^+ 4^*@a^*@c) ) ^/ (2^*@a); > > That would not be very pretty, indeed. It would also not be very > efficient. (BTW, its b**2 - 4ac, not + :)A more efficient, pretty,

Grammar (take V.00I_0I)

2002-07-15 Thread Sean O'Rourke
The short version: This is intended to be the "cleaned up to check into the Parrot tree" version Dan mentioned, so now would be a good time to yell if you have problems with it. The documentation is much better (or at least larger) than that in the previous version. You _will_ run into bugs, but

[perl #823] [PATCH] put numeric comparisons in the right order

2002-07-15 Thread Sean O'Rourke
# New Ticket Created by "Sean O'Rourke" # Please include the string: [perl #823] # in the subject line of all future correspondence about this issue. # http://bugs6.perl.org/rt2/Ticket/Display.html?id=823 > NOTE: this may be part of the monster-patch to fix the over-agress

Re: [perl #823] [PATCH] put numeric comparisons in the right order

2002-07-15 Thread Sean O'Rourke
In-Reply-To: <[EMAIL PROTECTED]> Message-ID: <[EMAIL PROTECTED]> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII On Mon, 15 Jul 2002, John Porter wrote: > Sean O'Rourke wrote: > > NOTE: this may be part of the monster-patch to fix the over-agressive >

Re: [perl #823] [PATCH] put numeric comparisons in the right order

2002-07-16 Thread Sean O'Rourke
On Tue, 16 Jul 2002, Nicholas Clark wrote: > 5.8.0 does the full fun and games of integer or floating point comparison: > > perl5.8.0-64 -le '$a = ~0; $b = $a & ~1; printf "%x <=> %x\n", $a, $b; print $a <=> >$b; {use integer; print $a <=> $b}' > <=> fffe > 1 > 1 > >

[perl #15009] [PATCH] test for for loops

2002-07-17 Thread Sean O'Rourke
# New Ticket Created by "Sean O'Rourke" # Please include the string: [perl #15009] # in the subject line of all future correspondence about this issue. # http://bugs6.perl.org/rt2/Ticket/Display.html?id=15009 > This file is intended to be languages/perl6/t/compiler/5.

languages/perl6 and 5.005_03

2002-07-23 Thread Sean O'Rourke
The compiler should work with 5.005_03 now (you may need to get a newer version of Class::Struct -- I'm waiting to hear back on this). Thanks to Leopold Toetsch for rooting out uses of the forbidden 'our' and lvalue subs, and for tracking down a but with /x and embedded qr// regexen. /s

Re: of Mops, jit and perl6

2002-07-29 Thread Sean O'Rourke
On Mon, 29 Jul 2002, Dan Sugalski wrote: > Just out of curiosity, I presume the (rather abysmal) perl 6 numbers > include time to generate the assembly and assemble it--have you tried > running the generated code by itself as a test? (At the moment, the > assembler's rather slow) It's mostly the

Re: I'm back...

2002-07-29 Thread Sean O'Rourke
On Mon, 29 Jul 2002, Dan Sugalski wrote: > In the mean time, someone can go ahead and implement the cmps and > cmpi ops to do string and integer compares respectively. Do you mean {gt,ge,eq,ne,le,lt}{s,n} conditional branches, or something like "cmps Ix, Py, Pz"? Also, would num-comparisons be

Re: I'm back...

2002-07-29 Thread Sean O'Rourke
On Mon, 29 Jul 2002, Dan Sugalski wrote: > If I thought anyone'd do control flow with it, I'd have a version of > the op for that, but I don't think we're going to see that, and perl > doesn't do it, so... Okay, writing this email has convinced me that maybe we don't need these ops. If Perl's go

Re: Array vs. PerlArray

2002-07-27 Thread Sean O'Rourke
On Fri, 26 Jul 2002, Melvin Smith wrote: > I can't remember who wrote what (I know it wasn't me, Jeff maybe?), > but if there aren't any complaints I'm going to copy PerlArray over > Array and then start from there. > > Any complaints? PerlArray converts arrays to their lengths to do math on them

we need more ops.

2002-07-27 Thread Sean O'Rourke
Two problems: - As things stand currently, there's no way to get to the cmp_num and cmp_string vtable methods from parrot assembly. - The cmp() method/op is completely useless for Perl, since Perl comparison operators force their operands to be interpreted as either strings or numbers. As thing

Re: we need more ops.

2002-07-28 Thread Sean O'Rourke
On Sun, 28 Jul 2002, Nicholas Clark wrote: > On Sat, Jul 27, 2002 at 08:07:50PM -0700, Sean O'Rourke wrote: > > Whether plain cmp (as a vtable function or an op on PMCs) should be kept > > at all is questionable -- there's no way to get at it syntactically from > &

methods, take 1

2002-07-28 Thread Sean O'Rourke
The attached patch (plus two files and an example) is a simple implementation of methods, plus the following three methods for PerlArray: @a.length: return @a's length @a.get_item($n): get the $nth item in @a @a.stash: get @a's (well, PerlArray's) stash hash This last lets you define methods wri

Re: I'm back...

2002-07-30 Thread Sean O'Rourke
On Tue, 30 Jul 2002, Dan Sugalski wrote: > I need to get Larry to nail some things down. On the one hand, he's > said that chained comparisons evaluate their parameters just once. > That argues for moving the values to N or S registers. I read that as "expressions are evaluated once", not "PMC's

Re: I'm back...

2002-07-30 Thread Sean O'Rourke
On Tue, 30 Jul 2002, Sean O'Rourke wrote: > And if you've tied a variable to have side effects every time it's > accessed, you shouldn't care if the results are unpredictable. s/tied a variable/implemented a type/. Argh. /s

Re: we need more ops.

2002-07-30 Thread Sean O'Rourke
On Tue, 30 Jul 2002, Melvin Smith wrote: > I think of Parrot as a CPU. When we have adequately designed the CPU, > people don't need new ops. I think of it as a VAX, in which case "adequately designed" means "just a few microcode ops" ;). /s

maybe-PATCH: sub/continuation/dlsym/coroutine clean-up

2002-07-30 Thread Sean O'Rourke
This patch implements native extensions and continuations as pmcs. It also cleans up the existing Sub and Coroutine types, and removes the following now-obsolete ops: callco callcc capturecc call callnative These are all handled through various uses of "invoke" (see t/pmc/sub.t for simple exampl

Re: [PRE-RELEASE] Release of 0.0.7 tomorrow evening

2002-07-31 Thread Sean O'Rourke
t; On Mon, Jul 22, 2002 at 11:14:15AM +0100, Sam Vilain wrote: > >>> > "Sean O'Rourke" <[EMAIL PROTECTED]> wrote: > >>> > > >>> > > languages/perl6/README sort of hides it, but it does say that > >>>"If you

Re: Lexical variables, scratchpads, closures, ...

2002-08-01 Thread Sean O'Rourke
On 31 Jul 2002, Jonathan Sillito wrote: > > > invoke# assumes sub is in P0 > > > # on invoke the sub pmc fixes the current > > > # context to have the correct lexicals > > > > Can you elaborate on this? What is done precisely to fix the current > > context? > >

Re: Lexical variables, scratchpads, closures, ...

2002-08-01 Thread Sean O'Rourke
On Thu, 1 Aug 2002, Jerome Vouillon wrote: > On Wed, Jul 31, 2002 at 11:22:56PM -0400, Melvin Smith wrote: > > We chose to implement > > the access as ops, and you prefer using a PMC Array directly. I can > > at least see one advantage to the explicit ops: they don't require > > a register to use

Re: Lexical variables, scratchpads, closures, ...

2002-08-01 Thread Sean O'Rourke
On Thu, 1 Aug 2002, Melvin Smith wrote: > Jerome Vouillon writes: > >On Wed, Jul 31, 2002 at 11:22:56PM -0400, Melvin Smith wrote: > >> And they need to be COW, as closures have access to their > >> own copies of lexicals. I asked Jonathan to reuse the stack code > >> I had already written becau

parrot "press"

2002-08-01 Thread Sean O'Rourke
A bit of Parrot bloggage where I didn't expect it http://lambda.weblogs.com/discuss/msgReader$3850 including evidence that the Python folks are not completely dormant: http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/python/python/nondist/sandbox/parrot/ /s

Re: maybe-PATCH: sub/continuation/dlsym/coroutine clean-up

2002-08-01 Thread Sean O'Rourke
On 1 Aug 2002, Jonathan Sillito wrote: > Looks good to me. Couple of quick things, when I applied the patch > locally, it indented the end bracket of the invoke op in core.ops which > breaks ops2c.pl. That's a bug. > Also the patch removed the yield op from core.ops, was this > intentional? Mor

Re: negative index in arrays

2002-08-01 Thread Sean O'Rourke
On Thu, 1 Aug 2002, Stephen Rawls wrote: > > It should pass them on to the PMC directly, which > > should then handle them properly. > > Let me rephrase. How should the PerlArray pmc handle > negative indecis when the absolute value of the index > is greater than the size of the array. IMHO it

Re: negative index in arrays

2002-08-01 Thread Sean O'Rourke
On Thu, 1 Aug 2002, Dan Sugalski wrote: > No, I don't think this is appropriate. The PerlArray class implements > Perl arrays, and should implement their semantics. It implements Perl 6 arrays, though. If it's a useful semantic extension (restrictions are another matter), I don't see why "perl 5

Re: [perl #15942] UNICOS/mk new unhappiness: hash.c

2002-08-02 Thread Sean O'Rourke
That's me. Will fix. /s On Fri, 2 Aug 2002, Jarkko Hietaniemi wrote: > # New Ticket Created by Jarkko Hietaniemi > # Please include the string: [perl #15942] > # in the subject line of all future correspondence about this issue. > # http://rt.perl.org/rt2/Ticket/Display.html?id=15942 > > > >

Re: Lexical variables, scratchpads, closures, ...

2002-08-02 Thread Sean O'Rourke
On Fri, 2 Aug 2002, Jerome Vouillon wrote: > On Thu, Aug 01, 2002 at 10:57:34AM -0700, Sean O'Rourke wrote: > > My naive implementation would have an array of hashes for each sub, with > > one entry for each level of scope within. > > I would use an array of arrays

Re: maybe-PATCH: sub/continuation/dlsym/coroutine clean-up

2002-08-02 Thread Sean O'Rourke
On Fri, 2 Aug 2002, Jerome Vouillon wrote: > On Tue, Jul 30, 2002 at 09:07:11PM -0700, Sean O'Rourke wrote: > > - take a look at "new" in core.ops. Creating a new continuation captures > > context, but the register holding that continuation is part of the > >

Re: Lexical variables, scratchpads, closures, ...

2002-08-02 Thread Sean O'Rourke
On Fri, 2 Aug 2002, Melvin Smith wrote: > At 08:50 AM 8/2/2002 -0700, Sean O'Rourke wrote: > >Without performance numbers, this is hard to test, but it can potentially > >turn a single "a = b + c", which is just "add P0, P1, P2" if a, b, and c >

Re: [perl #15942] UNICOS/mk new unhappiness: hash.c

2002-08-04 Thread Sean O'Rourke
On Sun, 4 Aug 2002, Mike Lambert wrote: > Unfortunately, this causes different semantics for whether you are storing > primitives or pointers (primitives copy, whereas pointers are shallow). Of > course, one could argue that the previous one didn't work at all. :) > > Thoughts? Well, it's certain

Re: status on matrix patch?

2002-08-09 Thread Sean O'Rourke
On Fri, 9 Aug 2002, Dan Sugalski wrote: > 1) Bind the ops to the PMC implementation and just peek under the hood > 2) Make method calls and have the PMCs do what they need to. > > #1 requires a way to load up PMC classes along with supporting opcode > libs and parrot bytecode libs, which is infras

RE: cvs commit: parrot/config/gen/makefiles perl6.in

2002-08-10 Thread Sean O'Rourke
On Sat, 10 Aug 2002, Brent Dax wrote: > [EMAIL PROTECTED]: > # Modified:config/gen/makefiles perl6.in > # Log: > # grab some info for perl6 driver to generate compiled exes. > > # +perl6-config: ../../Makefile pconfig.pl > # + $(myperl) pconfig.pl ../../Makefile perl6-config

Re: [perl #16114] [PATCH] faster assembler

2002-08-10 Thread Sean O'Rourke
A few more tweaks: - inline and remove _to_keyed and _to_keyed_integer. - inline pack_op - reorder the big elsif to test for /^\[/ once at the top, then only match against keyed/non-keyed. At this point, startup time dominates for anything as small as our test programs, so for testing purposes

Re: 'while <> {' in Perl 6

2002-08-11 Thread Sean O'Rourke
On Fri, 9 Aug 2002, Larry Wall wrote: > (Had an interesting typo there. I put => insteaqd of ->. I wonder > how much trouble that sort of thing is gonna cause. Maybe pairs > can be disallowed or warned about where a pointy sub might be > expected.) To add to the list of helpful warnings, I ran

Re: Perl 6 regexes...

2002-08-11 Thread Sean O'Rourke
Working on it. I've got greedy quantifiers (including <$n,$m>), interpolated arrays and scalars, enumerated character classes, code assertions, embedded blocks. It's all static, so runtime-compiled regexes aren't going in. Hypotheticals will be hard, but should be doable. Same with the various

Re: Perl 6 regexes... (fwd)

2002-08-12 Thread Sean O'Rourke
to CVS, email me and I'll send you the duct tape I'm using to hold it together now. /s -- Forwarded message -- Date: Mon, 12 Aug 2002 03:00:27 -0400 From: Dan Sugalski <[EMAIL PROTECTED]> To: Sean O'Rourke <[EMAIL PROTECTED]> Cc: [EMAIL PROTECTED] Subject: Re

Re: [COMMIT] GC_DEBUG, Some GC Fixes, and Remaining GC Bugs

2002-08-12 Thread Sean O'Rourke
On Mon, 12 Aug 2002, Steve Fink wrote: > farther yet. Oh, and I do have your recent patch to set > interpreter->lo_var_ptr early. How early is "early"? It looks like setting lo_var_ptr in Parrot_runcode instead of runops should be necessary/sufficient. If not, does initializing it to the addres

Re: [perl #16087] [PATCH] Scratchpad pmc

2002-08-12 Thread Sean O'Rourke
On Mon, 12 Aug 2002, Melvin Smith wrote: > >4) Parrot_Coroutine's 'init' is not longer used and can go away, I guess > >I could remove it in a future patch ... ok so that's not a question > > I wish this wouldn't go away. I think passing the constructor argument > for any PMC is a good optimizatio

Re: [perl #16256] Bug in P6C::IMCC

2002-08-16 Thread Sean O'Rourke
You are correct. /s On Fri, 16 Aug 2002, Benjamin Goldberg wrote: > In the file perl6/P6C/IMCC.pm, in the import sub, the else block: > > } else { > foreach (@_) { > *{$caller . '::' . $_} = \&$_; > } > } > > I think that it should be: > > } else { >

Re: "Functional" Perl6 compiler doesn't seem to be functioning

2002-08-19 Thread Sean O'Rourke
"Welcome, guests! (ah, fresh victims...)" On Tue, 20 Aug 2002, Chris Dutton wrote: > "Code must live with a function" at line 219 in P6C/IMCC.pm. From what > I gathered from trying to read that module, it appears that somehow > $curfunc is getting undefined, and then never redefined. This is a

regexen? rules? patterns?

2002-08-20 Thread Sean O'Rourke
I just put a rough cut at them in CVS. To actually use them, you'll need to apply a rather brutal patch/hack to IMCC, which I'll post to the list shortly. This does not use Jeff's grammar -- I wanted to get what I had into CVS before taking a look at that. Enjoy, /s

imcc hack for perl6 regexes

2002-08-20 Thread Sean O'Rourke
This is what you'll need. It uses dlopen(), and is likely Bad in a number of other ways, but if you're on a fairly normal UNIX, it should allow imcc to grok what P6C produces for regexes. /s ? languages/imcc/a.out ? languages/imcc/anyop.c ? languages/imcc/anyop.h ? languages/imcc/a.pasm ?

Re: imcc hack for perl6 regexes

2002-08-21 Thread Sean O'Rourke
Replying to myself because I forgot to include these files... /s anyop.tgz Description: Binary data

Re: imcc hack for perl6 regexes

2002-08-21 Thread Sean O'Rourke
On Wed, 21 Aug 2002, Angel Faus wrote: > About the implementation, I think we will need the following metadata about > each op: > > i) the opcode, and the op name. > ii) the type of arguments, including in/out/etc.. Both of these are available, though there currently isn't an efficient interface

Re: imcc hack for perl6 regexes

2002-08-21 Thread Sean O'Rourke
On Wed, 21 Aug 2002, Melvin Smith wrote: > At 11:15 PM 8/21/2002 +0200, Leopold Toetsch wrote: > >_SV_s1 = clone $P1 > > I've considered changing '=' to mean clone, and add ':=' to imply set. > What do you think? Heh. What's the universal sign for "assign" (as opposed to "clone" or "set

Re: INP ("imcc's not parrot")

2002-08-21 Thread Sean O'Rourke
On Wed, 21 Aug 2002, Melvin Smith wrote: > At 07:00 PM 8/21/2002 -0400, 'John Porter' wrote: > >No; but statements like "imcc MUST provide access to ALL of parrot's > >(still very dynamic) feature set" and discussions of imcc syntax > >naturally lead to questions of imcc's role in the parrot proje

Re: imcc hack for perl6 regexes

2002-08-21 Thread Sean O'Rourke
On Wed, 21 Aug 2002, Leopold Toetsch wrote: > Melvin Smith wrote: > > I still prefer infix notation to prefix notation for an intermediate > > language. > > The current infix notation is fine. It makes intermediate code, and > perl6 IMCC code generation more readable. > > Sean (IMHO) is not trying

Re: Off-list discussions, was Re: imcc hack for perl6 regexes

2002-08-21 Thread Sean O'Rourke
On Wed, 21 Aug 2002 [EMAIL PROTECTED] wrote: > >Can I respectfully request that you guys make a lot more of your > >discussions public? I'd like to dispel rumors of a vast off-list conspiracy. I've been taking and discussing patches to languages/perl6 from a couple of people (hi, Leo) off-list,

Re: INP ("imcc's not parrot")

2002-08-21 Thread Sean O'Rourke
On Wed, 21 Aug 2002, 'John Porter' wrote: > Sean O'Rourke wrote: > > However, if we already have a working register > > allocator and peephole optimizer, I see little reason to write another. > > Maybe you're taking a very perl6-centric view. (I don'

Re: [perl #16745] imcc doesn't compile anymore

2002-08-25 Thread Sean O'Rourke
Added the necessary files, so it should be working again. There are still a couple outstanding syntax issues, but you should only run into those on some of the regex tests. /s On Sun, 25 Aug 2002, Markus Laire wrote: > # New Ticket Created by "Markus Laire" > # Please include the string: [pe

Re: [netlabs #801] [PATCH] PerlArray in scalar context

2002-08-25 Thread Sean O'Rourke
I ran across this in looking at tidying up old bugs. It seems like things are backwards below -- hyper-operation is a language-level shorthand for iteration over a container, so there's no reason for the container's vtable methods to be "hyper". Actually, it seems like there are at least a coupl

Re: [perl #16755] imcc requires Parrot_dlopen but HAS_DLOPEN isnever defined

2002-08-25 Thread Sean O'Rourke
On Sun, 25 Aug 2002, Tom Hughes wrote: > That sounds like a separate bug in the imcc makefile - the main > parrot makefile only links against libdl if Configure.pl discovers > that perl5 does. Yes. I will update imcc to do so as well. /s

Re: [perl #16755] imcc requires Parrot_dlopen but HAS_DLOPEN isnever defined

2002-08-25 Thread Sean O'Rourke
On Sun, 25 Aug 2002, Tom Hughes wrote: > In message <20020825155505$[EMAIL PROTECTED]> > Tom Hughes (via RT) <[EMAIL PROTECTED]> wrote: > > > Recent changes to imcc make it require a working Parrot_dlopen but > > unfortunately as things stand it never does work because Configure.pl > >

Re: [perl #16755] imcc requires Parrot_dlopen but HAS_DLOPEN isnever defined

2002-08-25 Thread Sean O'Rourke
On Mon, 26 Aug 2002, Markus Laire wrote: > I tested than on Cygwin and imcc does compile, but I have some > problems: > > If I compile imcc with 'make imcc', most perl6 tests will fail with > error "readline() on closed filehandle P6C::TestCompiler::PASM at > P6C/TestCompiler.pm line 55." "make i

Re: [perl #16755] imcc requires Parrot_dlopen but HAS_DLOPEN isnever defined

2002-08-25 Thread Sean O'Rourke
On Mon, 26 Aug 2002, Markus Laire wrote: > > Does the same thing happen when you do a "make shared" > > in the base parrot directory? > > "make shared" dies with 'missing .h files' More competent and/or Windows-savvy hands than mine are working on this as we speak. > "make && make shared" gives

Re: DOD etc

2002-08-26 Thread Sean O'Rourke
On Mon, 26 Aug 2002, Nicholas Clark wrote: > All ways of doing deterministic destruction seem to have considerable > overhead. One possible alternative would be to have file handles and other objects with destructors that have to be called in a timely fashion keep ref-counts. When the refcount d

Re: [perl #16755] imcc requires Parrot_dlopen but HAS_DLOPEN isnever defined

2002-08-26 Thread Sean O'Rourke
On Mon, 26 Aug 2002, Markus Laire wrote: > On 25 Aug 2002 at 23:01, Sean O'Rourke wrote: > > > Ah, _parser_ tests! (hits self on head). Those are out-of-date, and > > should be disabled. The fact that all the compiler tests pass is a > > relief, and indicates tha

Re: rule, rx and sub

2002-08-26 Thread Sean O'Rourke
On Mon, 26 Aug 2002, Glenn Linderman wrote: > because the rules and patterns are no longer regular, but if rx isn't a > short form of regex, what is it a short form of? It's a short form of "r$x" for some value of "$x" ;). /s

significant imcc commit

2002-08-26 Thread Sean O'Rourke
Okay, I just added a big chunk of code to imcc. The code does two main things: - changes imcc syntax to disallow newlines within ops. You can still have all the newlines you want between ops and after labels, but this: if $P1 goto label will no longer work. Since no one app

Re: rule, rx and sub

2002-08-27 Thread Sean O'Rourke
On Tue, 27 Aug 2002, Luke Palmer wrote: > On 27 Aug 2002, Piers Cawley wrote: > > Damian Conway <[EMAIL PROTECTED]> writes: > > > Debbie Pickett asked: > > > > (Offtopic: can I say: > > > > $c = -> $xyz { mumble } > > > > > > Yes. Though you need a semicolon at the end unless its the last > > >

Re: rule, rx and sub

2002-08-27 Thread Sean O'Rourke
On Tue, 27 Aug 2002, Luke Palmer wrote: > No, it's right. But it doesn't break that. In the grammar, C-like > languages include (something like): > > statement: expression ';' > statement: if expression block > > So an if _statement_ terminates itself. The } on a line of its own is a

Re: DOD etc

2002-08-27 Thread Sean O'Rourke
On Tue, 27 Aug 2002, Mike Lambert wrote: > Is there still a need for determinstic destruction, even in light of the > alternative approaches mentioned above? Yes, if the destruction of the resource is itself important to the program. For example, one way to do exception-safe locks in C++ is to h

Re: PMC assignment stuff

2002-08-27 Thread Sean O'Rourke
On Tue, 27 Aug 2002, Jason Gloudon wrote: > Dan Sugalski wrote: > > This includes all forms of assignment, not just the ASSIGN op kind. > > When we do an ADD Px, Py, Pz, we're calling Px's set_pmc vtable entry > > with a PMC that represents the addition of Y and Z. Whether X changes > > its type i

Re: perl6 test failures

2002-08-27 Thread Sean O'Rourke
On Tue, 27 Aug 2002, Steve Fink wrote: > I would like to take a shot at making perl6 front- and backend > adapters for languages/regex, but so far I have seen all the tests in > languages/perl6 pass exactly once (and I updated again immediately > after, and a bunch of them broke again.) So I'm a l

Re: perl6 test failures

2002-08-27 Thread Sean O'Rourke
On Tue, 27 Aug 2002, Leopold Toetsch wrote: > Steve Fink wrote: > On a recent tree try this: > > $ perl6 --force --test# force rebuid grammar, run all tests s/force/force-grammar/? /s

Re: perl6 test failures

2002-08-27 Thread Sean O'Rourke
On Tue, 27 Aug 2002, Steve Fink wrote: > For those following along at home: regex engines seem to be too much > fun for people to resist. I know of at least 5 parsers, 4 compilers, > and 5 backend op sets that have been written over the course of the > Parrot project: > > Parsers: > - My language

Re: Does ::: constrain the pattern engine implementation?

2002-08-28 Thread Sean O'Rourke
On Wed, 28 Aug 2002, Deven T. Corzine wrote: > Would it be better for the matching of (Jun|June) to be "undefined" and > implementation-dependent? Or is it best to require "leftmost" semantics? For an alternation spelled out explicitly in the pattern, it seems like undefined matching would be co

Re: Regex status?

2002-08-28 Thread Sean O'Rourke
On Wed, 28 Aug 2002, Dan Sugalski wrote: > How're we coming with the perl 6 regex stuff? What works, what > doesn't, and are we at a state where we can release something for > people to play with? There are plenty of things, like anonymous rules, any of the builtin assertions, and modifiers, that

Re: Hypothetical synonyms

2002-08-28 Thread Sean O'Rourke
On Thu, 29 Aug 2002, Markus Laire wrote: > (only 32bit numbers, modulo not fully working, no capturing regexps, > ) Where does modulo break? /s

Re: rule, rx and sub

2002-08-28 Thread Sean O'Rourke
On Wed, 28 Aug 2002, Damian Conway wrote: > Any subroutine/function like C that has a signature (parameter list) > that ends in a C<&sub> argument can be parsed without the trailing > semicolon. So C's signature is: > > sub if (bool $condition, &block); > > So the trailing semicolon isn't re

Re: rule, rx and sub

2002-08-28 Thread Sean O'Rourke
On Wed, 28 Aug 2002, Luke Palmer wrote: > > Second, is there a prototype-way to specify the arguments to "for" > > (specifically, the first un-parentesized multidimensional array argument)? > > In other words, is that kind of signature expected to be used often enough > > to justify not forcing p

Re: Goal call for 0.0.9

2002-09-02 Thread Sean O'Rourke
On Mon, 2 Sep 2002, Dan Sugalski wrote: > Here's a call for potential goals for the 0.0.9 release of parrot. My list: > > *) Exceptions > *) initial PMC freeze/thaw API > *) Sub indicators in bytecode > *) On-the-fly bytecode section generation *) methods (in PASM and C) *) implementation of som

  1   2   3   >