In message [EMAIL PROTECTED],
Jonathan Worthington writes:
: Ugh. I'm currently doing a lot of stuff to get rid of .def files and
: replace them with decorations in the code instead. You may have got
: caught up in this (or maybe the changes have hurt cygwin in a way I
: didn't anticipate).
=head1 DESCRIPTION
This test file describes an improvement for the directive .const
when an HLL is using.
In Lua, all types are implemented as PMC,
no Lua type is mapped with Parrot primitive type.
Lua PMC are derived from existing PMC, for example :
pmclass LuaNumber extends Float does
Greg Bacon [EMAIL PROTECTED] wrote:
Not quite. At r11144 on Cygwin, I see
[...]
gcc -o miniparrot.exe -s -L/usr/local/lib compilers/imcc/main.o \
-L/home/gbacon/src/parrot/blib/lib -lparrot -lcrypt src/null_config.o
compilers/imcc/main.o: In function `imcc_version':
Joshua Hoblitt wrote:
On Thu, Jan 12, 2006 at 04:53:26PM +0100, Leopold Toetsch wrote:
Klaas-Jan Stol wrote:
Hi,
I'm trying to implement some functions into the Lua PMCs, but I'm having
trouble to compile them.
I want to add a clone method to the LuaNil PMC (which should extend
On Jan 13, 2006, at 3:44, Joshua Isom wrote:
With the attached patch, which changes argv to be a
ResizableStringArray instead of an SArray, when argv reaches the pir
execution, four null strings are prepended to argv.
The SArray needs presizing (line 467), but still does push_string from
On Jan 13, 2006, at 10:20, François PERRAD wrote:
=head1 DESCRIPTION
This test file describes an improvement for the directive .const
when an HLL is using.
Not really - see below.
.const .Integer i = 12
The Integer PMC implements the constructor new_from_string, which is
called at
.const .LuaNumber n = 12.34
I presume LuaNumber doesn't have new_from_string (Float hasn't either).
Attached is a patch that implements new_from_string() for LuaNumber.
In my opinion it's handy to say:
.const .LuaNumber n = 12.34
kind regards,
klaas-jan
---
Below are some thoughts, syntax mainly, how it could look like.
leo
Proposal: Named Arguments
pdd03 is already mentioning named arguments, but a concrete syntax
is still missing, as well as how it could work.
First a snippet of the proposed syntax:
.sub named_test :main
.local pmc a, b,
This patch changes LuaNil PMC, it used to be a singleton, this patch
makes it a normal PMC.
some other methods are implemented for morphing into other Lua types
(LuaString, LuaNumber, LuaBoolean).
regards,
klaas-jan
--- languages/lua/classes/luanil.pmc2006-01-13 16:34:42.0 +0100
this patch changes the behaviour of the LuaTable PMC.
changes have to do with the reference semantics that PMCs have, and
LuaTables should not have.
Setting and getting a value now will set (and get) a copy of the value.
Clone() returns a reference to itself, as clone() should be used for
On 1/13/06, Jonathan Worthington [EMAIL PROTECTED] wrote:
Greg Bacon [EMAIL PROTECTED] wrote:
Not quite. At r11144 on Cygwin, I see
[...]
gcc -o miniparrot.exe -s -L/usr/local/lib compilers/imcc/main.o \
-L/home/gbacon/src/parrot/blib/lib -lparrot -lcrypt src/null_config.o
I tried building tcl today but got a failure in parrot, undefined
symbol. It happens when first outputting the first pbc. I did a
distclean and reconfigured without optimize or using ccache, but that
didn't help. 'make dynclasses-test' tests dynlexpad and foo without
problems(I did have to
On Fri, 2006-01-13 at 14:29 +0100, Leopold Toetsch wrote:
Proposal: Named Arguments...
Your proposal covers all the functionality that I need for Amber,
thanks.
b = new .Integer
c = 3
I'm sure everyone realised, but just for the sake of completeness: the
first identifier above should
On 1/13/06, Leopold Toetsch [EMAIL PROTECTED] wrote:
Below are some thoughts, syntax mainly, how it could look like.
Proposal: Named Arguments
[snip proposal]
Comments welcome,
leo
it's not stated explicitly in your proposal, but what is the proper
location for named params in a sub call?
jerry gay wrote:
it's not stated explicitly in your proposal, but what is the proper
location for named params in a sub call? i expect something like
named arguments must follow all positional (required and optional)
arguments in a sub or method call.
You pass arguments to a function. That
On Fri, 2006-01-13 at 17:01 +0100, Leopold Toetsch wrote:
... making argument
count mismatch detection work with '.param'?
That's as easy as emitting one instruction in main:
errorson 0x0C
Wow, it really does work. Thanks! Although it misses the case where the
called sub has zero
Roger Browne wrote:
On Fri, 2006-01-13 at 14:29 +0100, Leopold Toetsch wrote:
Proposal: Named Arguments...
Your proposal covers all the functionality that I need for Amber,
thanks.
Great.
Leo, would you be so kind as to rescind the parameter passing error
flags, and make mismatches
Roger Browne wrote:
Wow, it really does work. Thanks! Although it misses the case where the
called sub has zero .params:
.sub 'main' :main
errorson 0x0C
foo(5)
.end
.sub foo
print Not OK\n
.end
Yep. There is currently just one reason for that and it's in your
On 1/13/06, Roger Browne [EMAIL PROTECTED] wrote:
On Fri, 2006-01-13 at 17:01 +0100, Leopold Toetsch wrote:
885/4851 subtests failing, 81,76% okay.
Wow, that's a lot of tests affected by this one thing.
most of them are in the PGE tests. since there are over 1,300 PGE
tests, and and about
On 1/13/06, jerry gay [EMAIL PROTECTED] wrote:
i'll fix PGE, which will leave only about 135 failures, many of which
are in library code (no surprise there.) with a little help, i think
we can squash these failures in no time.
on second thought... before i go diving into PGE to fix something
# New Ticket Created by Joshua Isom
# Please include the string: [perl #38225]
# in the subject line of all future correspondence about this issue.
# URL: https://rt.perl.org/rt3/Ticket/Display.html?id=38225
I tried building tcl today but got a failure in parrot, undefined
symbol. It
Today I wrote some perl5 code for the umpteenth time. Basically:
for( my $i=0; $i $#ARGV; $i++ )
{
next unless $ARGV[$i] eq -f;
$i++;
$ARGV[$i] = absolute_filename $ARGV[$i];
}
chdir foo;
exec bar, @ARGV;
I'm trying to work out if there's a clever perl6 way to write
Dave Whipp wrote:
Today I wrote some perl5 code for the umpteenth time. Basically:
for( my $i=0; $i $#ARGV; $i++ )
{
next unless $ARGV[$i] eq -f;
$i++;
$ARGV[$i] = absolute_filename $ARGV[$i];
}
chdir foo;
exec bar, @ARGV;
I'm trying to work out if there's a
Joshua Isom (via RT) [EMAIL PROTECTED] wrote:
I tried building tcl today but got a failure in parrot, undefined
symbol. It happens when first outputting the first pbc. I did a
distclean and reconfigured without optimize or using ccache, but that
didn't help. 'make dynclasses-test' tests
On 1/13/06, Dave Whipp [EMAIL PROTECTED] wrote:
I'm trying to work out if there's a clever perl6 way to write this using
pattern matching:
for @*ARGV - -f, $filename {
$filename .= absolute_filename;
}
There is, but it's a different kind of pattern matching:
if @*ARGV ~~ / ,
In perl 5:
my @a = (1,2,3);
delete $a[1];
print exists $a[1];
This is false, whereas $a[0] and $a[2] do exist. This is creepy. Not
only is it creepy, it raises a whole bunch of questions with
nontrivial answers:
* does [EMAIL PROTECTED] include nonexistent elements?
* does
Hi,
* Fixed the Lua PMCs to no longer use the now-deprecated Parrot_PMC_typenum,
so it builds. Also tested out how Lua handles on Win32 - basically it builds
but all the tests give something like this:-
--
lua\t\while...NOK 2# Failed test (lua\t\while.t at line 37)
#
Well it fixed part of the parrot problem... Now I get a syntax error
for tcl.pir, line 18, unexpected dot, so I'm guessing that .DynLexPad
isn't set. I guess the little comment at the top, therefore the
.DynLexPad constant is already available isn't quite true.
Joshua
On Jan 13, 2006, at
Luke Palmer wrote:
On 1/13/06, Dave Whipp [EMAIL PROTECTED] wrote:
Would this actually work, or would it stop at the first elem that
doesn't match (-f, ::Item)?
If by stop you mean die, yes it would stop.
not what I wanted :-(
Is there some way to associate alternate codeblocks for
On Fri, Jan 13, 2006 at 10:33:23PM +, Luke Palmer wrote:
In perl 5:
my @a = (1,2,3);
delete $a[1];
print exists $a[1];
This is false, whereas $a[0] and $a[2] do exist. This is creepy. Not
only is it creepy, it raises a whole bunch of questions with
nontrivial answers:
On 1/13/06, Dave Whipp [EMAIL PROTECTED] wrote:
What happens if I simply abandon the attempt at anonymous MMD and use a
named multi-sub, instead:
{
my multi sub process_arg(-f, Str $f is rw) {
$f .= absolute_filename
}
my multi sub process_arg(--quux, Str arg1, Str arg2) {
Hi,
Today I've essentially completed the work on moving us from working with
.def files, which list symbols to be exported, to just decorating them in
the code. That includes the Parrot core, PMCs (core and dynamic) and ops
(core and dynamic).
One result of this is that functions that can
On Fri, Jan 13, 2006 at 11:42:13PM +, Luke Palmer wrote:
: On 1/13/06, Dave Whipp [EMAIL PROTECTED] wrote:
: What happens if I simply abandon the attempt at anonymous MMD and use a
: named multi-sub, instead:
:
: {
: my multi sub process_arg(-f, Str $f is rw) {
:$f .=
With some recent additions to resizablestringarray.pmc, a perhaps very
old todo can now be taken care of. It makes the proper changes to
src/embed.c, and some necessary changes to tcl.pir(shift to a string
instead of a pmc) and m4.pir(remove the work arounds, part for SArray,
part for a fixed
On 13/01/06 20:36, Dave Whipp wrote:
Is there some way to associate alternate codeblocks for different
patterns (i.e. local anonymous MMD)?
Is it possible to have an anonymous multi sub?
This would seem to require new syntax for combining two anonymous
definitions.
Of course we want
From: Bob Rogers [EMAIL PROTECTED]
Date: Fri, 6 Jan 2006 23:22:19 -0500
If sub A pushes an error handler and then calls B, B can do a
'clear_eh' to get rid of A's handler. This seems to work until B
returns, at which point the control stack unwinding done by
RetContinuation
On Fri, Jan 13, 2006 at 10:33:23PM +, Luke Palmer wrote:
: In perl 5:
:
: my @a = (1,2,3);
: delete $a[1];
: print exists $a[1];
:
: This is false, whereas $a[0] and $a[2] do exist. This is creepy. Not
: only is it creepy, it raises a whole bunch of questions with
: nontrivial
37 matches
Mail list logo