Re: supertyping

2006-12-12 Thread TSa
HaloO, Jonathan Lang wrote: In any case, one should never add anything while going from specific to general. The crux of my example is that one indeed adds methods in the supertype. The subtype receives a standard implementation. This pattern is applicable whenever you have a case like the

Error running Pugs tests

2006-12-12 Thread Ovid
Hi all, Just built GHC 6.6 from source (oh joy!) and upgraded to Pugs Version: 6.2.13 (r14881). After building it I did a make install and in the pugs directory, I tried this: pugs $ pugs t/general/basic.t pugs: user error (*** Unexpected Str expecting \\, :, *, parameter name

Re: Error running Pugs tests

2006-12-12 Thread Gaal Yahas
On Tue, Dec 12, 2006 at 02:14:42AM -0800, Ovid wrote: pugs $ pugs t/general/basic.t pugs: user error (*** Unexpected Str expecting \\, :, *, parameter name or ) at /usr/local/lib/perl6/Test.pm line 34, column 21 t/general/basic.t line 1, column 1) You have

Past-pm basic string types

2006-12-12 Thread Allison Randal
Patrick, what's the best way to pass-through string types from a compiler to Parrot without doing full string processing? To pass the current tests, Punie only needs Parrot's single- and double-quoted strings, but Past-pm is escaping them. So: print \n; reaches the PIR translation as:

Past-pm printing the return value of the main routine

2006-12-12 Thread Allison Randal
In Punie or Perl 6, when I execute a simple statement: print 2; It prints 21. This is because a) the return value of a successful print is 1, b) the main routine is returning the value of the last statement (note this is correct for Perl, but isn't correct for all languages), and c)

Re: Past-pm printing the return value of the main routine

2006-12-12 Thread Patrick R. Michaud
On Tue, Dec 12, 2006 at 09:47:16AM -0800, Allison Randal wrote: In Punie or Perl 6, when I execute a simple statement: print 2; It prints 21. This is because a) the return value of a successful print is 1, b) the main routine is returning the value of the last statement (note this is

Re: Past-pm printing the return value of the main routine

2006-12-12 Thread Allison Randal
Patrick R. Michaud wrote: What revision number are you working with? I think this was fixed in a later revision of HLLCompiler. Aye, this was yesterday. Working now. Allison

Re: Past-pm basic string types

2006-12-12 Thread Patrick R. Michaud
On Tue, Dec 12, 2006 at 09:43:39AM -0800, Allison Randal wrote: Patrick, what's the best way to pass-through string types from a compiler to Parrot without doing full string processing? To pass the current tests, Punie only needs Parrot's single- and double-quoted strings, but Past-pm is

Re: Past-pm basic string types

2006-12-12 Thread Allison Randal
Patrick R. Michaud wrote: PAST-pm expects it to be pretty rare that a HLL's string literal format will exactly match what works as a string literal in PIR, so PAST::Val nodes expect the HLL to have already decoded the string constant according to whatever rules the HLL uses. Then PAST-pm can

Past-pm printing the return value of the main routine

2006-12-12 Thread Allison Randal
In Punie or Perl 6, when I execute a simple statement: print 2; It prints 21. This is because a) the return value of a successful print is 1, b) the main routine is returning the value of the last statement (note this is correct for Perl, but isn't correct for all languages), and c)

Re: Error running Pugs tests

2006-12-12 Thread Ovid
--- Gaal Yahas [EMAIL PROTECTED] wrote: On Tue, Dec 12, 2006 at 02:14:42AM -0800, Ovid wrote: pugs $ pugs t/general/basic.t pugs: user error (*** Unexpected Str expecting \\, :, *, parameter name or ) at /usr/local/lib/perl6/Test.pm line 34, column 21

Introspection and list question

2006-12-12 Thread Ovid
Hi all, A couple of quick things. First, how do I do introspection in Pugs? CPAN's Perl6::Bible hasn't been updated in a while, but the various ways to get a list of methods (from http://search.cpan.org/dist/Perl6-Bible/lib/Perl6/Bible/S12.pod#Introspection or http://tinyurl.com/yxukar) don't

Re: Introspection and list question

2006-12-12 Thread jerry gay
On 12/12/06, Ovid [EMAIL PROTECTED] wrote: Hi all, A couple of quick things. First, how do I do introspection in Pugs? CPAN's Perl6::Bible hasn't been updated in a while, but the various ways to get a list of methods (from

Re: supertyping

2006-12-12 Thread Luke Palmer
On 12/12/06, TSa [EMAIL PROTECTED] wrote: HaloO, Jonathan Lang wrote: In any case, one should never add anything while going from specific to general. The crux of my example is that one indeed adds methods in the supertype. The subtype receives a standard implementation. This pattern is

Re: supertyping

2006-12-12 Thread Luke Palmer
On 12/13/06, Luke Palmer [EMAIL PROTECTED] wrote: Things work a little differently for required methods. When a superrole requires a method be implemented, we (the language designers) have a choise to make: it is illegal if the superrole requires a method that the subroles don't implement or