Ron Blaschke wrote:
Ron Blaschke wrote:
t\pmc\bigint.t1 256221 4.55% 22
The problem seems to be caused by the Cfree(s); in
Fbigint.pmc/get_string. Well, not the actual cause, but that's
where we fail.
mpz_get_str() returned a string that was very likely allocated by a
So I'm finally starting to implement multi-level invocants in MMDs.
I'd like to sanity check some cases first, though.
Are these two assumed to be identical?
multi sub foo ($x, $y)
multi sub foo ($x, $y : )
But these two are _not_ identical?
multi sub foo ($x : $y : $z)
multi
Uri Guttman wrote:
i can't spit out the syntax but here is the conceptual way i would do
it. we do have multidimensional slices so we could grab each slice
(maybe with zip?) and pass that to [+] and then grab the list of results
back into a array/matrix with one less dimension than the original.
# New Ticket Created by Dino Morelli
# Please include the string: [perl #35892]
# in the subject line of all future correspondence about this issue.
# URL: https://rt.perl.org/rt3/Ticket/Display.html?id=35892
file: docs/submissions.pod
Updated the How To Submit Something New section to
Leopold Toetsch [EMAIL PROTECTED] wrote:
3) Proposal: PIR syntax enhancement
.pragma n_operators
...
Px = Py + 1
...
[EOF]
Within this pragma (valid inside and until end of file) the shortcuts
'+', '-', ... should translate to n_add, n_sub, ...
This simplifies the
HaloO Luke,
you wrote:
I wonder how we specify meta
operators that only work on comparators, or only on assignment forms,
or etc. etc. etc.
Well, Perl6 has got first class Code types, hasn't it?
So it's a matter of defining a type hierarchy among the
operators and then you can dispatch on them
Autrijus == Autrijus Tang [EMAIL PROTECTED] writes:
Autrijus On Tue, May 17, 2005 at 03:00:14PM +0100, Colin Paul
Autrijus Adams wrote:
But when I look at http://www.parrotcode.org/docs/embed.html, I
can see no way of getting information back from the script -
not even an
On Fri, May 20, 2005 at 10:34:39AM +0100, Colin Paul Adams wrote:
I have a problem with this - namely that the function is variadic, and
the interface generator can't cope with this.
Hmm, in Haskell FFI, we hard-coded two cases of invocation, treating
the function as two distinct, non-variadic
Colin Paul Adams [EMAIL PROTECTED] wrote:
I have a problem with this - namely that the function is variadic, and
the interface generator can't cope with this.
Have a look at src/inter_run.c e.g.
void *
Parrot_runops_fromc_arglist(Parrot_Interp interpreter, PMC *sub,
const char *sig,
Dino Morelli [EMAIL PROTECTED] wrote:
Updated the How To Submit Something New section to include patching
the MANIFEST file.
Thanks, applied.
leo
Autrijus == Autrijus Tang [EMAIL PROTECTED] writes:
Autrijus On Fri, May 20, 2005 at 10:34:39AM +0100, Colin Paul
Autrijus Adams wrote:
I have a problem with this - namely that the function is
variadic, and the interface generator can't cope with this.
Autrijus Hmm, in
Leopold == Leopold Toetsch [EMAIL PROTECTED] writes:
Leopold Colin Paul Adams [EMAIL PROTECTED] wrote:
I have a problem with this - namely that the function is
variadic, and the interface generator can't cope with this.
Leopold Have a look at src/inter_run.c e.g.
Leopold
Leopold Toetsch wrote:
Ron Blaschke wrote:
Ron Blaschke wrote:
t\pmc\bigint.t1 256221 4.55% 22
The problem seems to be caused by the Cfree(s); in
Fbigint.pmc/get_string. Well, not the actual cause, but that's
where we fail.
mpz_get_str() returned a string that
Mark == Mark A Biggar [EMAIL PROTECTED] writes:
Mark The usual definition of reduce in most languages that support it, is
Mark that reduce over the empty list produces the Identity value for the
Mark operation.
In Smalltalk, the equivalent of reduce is inject:into:, so a
sum reduce looks like:
Randal == Randal L Schwartz merlyn@stonehenge.com writes:
Randal For example, if I wanted the identity hash (where all values are 1,
Randal but keys are original list elements), I could do:
Randal my %hash = @somelist.inject({}, { $^a{$^b} = 1; $^a });
And yes, I know I can spell this as:
my
I'm currently rewriting the hash implementation in src/hash.c. The new
hash structure has just one piece of malloced memory with bucket
pointers and buckets in one piece.
But before comitting I'd like to have some stress and benchmarks tests
that first show that my implementation is correct
I am trying to work out how to compile a perl script using pugs.
(Am I on the right mailing list?)
If I do pugs -h, then it suggests to me the -C option will do the
trick, but does not say what value the backend might be.
But I'm also having trouble running the script. It runs OK with perl
5,
On Fri, May 20, 2005 at 06:09:55AM -0700, Randal L. Schwartz wrote:
Mark == Mark A Biggar [EMAIL PROTECTED] writes:
Mark The usual definition of reduce in most languages that support it, is
Mark that reduce over the empty list produces the Identity value for the
Mark operation.
In
On 5/20/05, Ron Blaschke [EMAIL PROTECTED] wrote:
t/pmc/bigint now passes, but with Rev 8133 there are several other
failures (even with a fresh checkout).
Failed Test Stat Wstat Total Fail Failed List of Failed
John Macdonald wrote:
... (and there may be additional
operator attributes that make sense there too, although none
come immediately to mind).
Well, I wonder why people neglect the fact that the neutral/identity
element is not a property of the operator alone?! Besides the
associativity and
A highly experimental implementation of coroutines has landed to Pugs.
The `coro` keyword denotes a coroutine. It may appear at any place
where `sub` may appear, i.e. in both named and anonymous forms.
I borrowed the semantics from Coro::Cont on CPAN, with the following
restriction that you
On Fri, May 20, 2005 at 03:13:52PM +0100, Colin Paul Adams wrote:
I am trying to work out how to compile a perl script using pugs.
(Am I on the right mailing list?)
Well, yes and no. To run Perl 5 in Parrot, you want the ponie-dev
mailing list -- this is perl6-compiler after all. :-)
If I do
John Macdonald wrote:
Is there a built-in operator that doesn't have a meaningful
identity value? I first thought of exponentiation, but it has
an identity value of 1 - you just have to realize that since
it is a right associative operator, the identity has to be
applied from the right.
Well the
Autrijus == Autrijus Tang [EMAIL PROTECTED] writes:
Autrijus You may wish to use Parrot_call_sub's SS form, where
Autrijus you pass in a string and get back a string. Something
Autrijus like this:
Autrijus my $interp = Parrot_new(undef);
Autrijus # ... load a .pir
LT == Leopold Toetsch [EMAIL PROTECTED] writes:
LT I'm currently rewriting the hash implementation in src/hash.c. The
LT new hash structure has just one piece of malloced memory with
LT bucket pointers and buckets in one piece.
here is an odd thought to add to that. since your hash is a
Leopold Toetsch wrote:
I'm currently rewriting the hash implementation in src/hash.c. The new
hash structure has just one piece of malloced memory with bucket
pointers and buckets in one piece.
But before comitting I'd like to have some stress and benchmarks tests
that first show that my
On Fri, May 20, 2005 at 05:42:48PM +0100, Colin Paul Adams wrote:
The problem I'm finding with this, is getting back the returned string
characters.
I assume the void * returned is pointing to a Parrot String.
Certainly it's not a const char *.
Yes.
There is a function declaration
On Sat, May 21, 2005 at 12:53:15AM +0800, Autrijus Tang wrote:
On Fri, May 20, 2005 at 05:42:48PM +0100, Colin Paul Adams wrote:
There is a function declaration
Parrot_string_cstring
in string_funcs.h, but it appears to have no definitoon anywhere, so
that's not much use to me.
On Sat, May 21, 2005 at 12:53:15AM +0800, Autrijus Tang wrote:
Yeah, I bumped against that too. You need to look at the strstart
field in the ParrotString struct.
In Haskell I use:
peekCString = #{peek STRING, strstart} s5
Actually, never mind; string_to_cstring is the way to go.
Uri Guttman wrote:
LT == Leopold Toetsch [EMAIL PROTECTED] writes:
LT I'm currently rewriting the hash implementation in src/hash.c. The
LT new hash structure has just one piece of malloced memory with
LT bucket pointers and buckets in one piece.
here is an odd thought to add to that. since
At 1:15 AM +0800 5/21/05, Autrijus Tang wrote:
On Sat, May 21, 2005 at 12:53:15AM +0800, Autrijus Tang wrote:
Yeah, I bumped against that too. You need to look at the strstart
field in the ParrotString struct.
In Haskell I use:
peekCString = #{peek STRING, strstart} s5
Actually, never
Mark A. Biggar wrote:
Well the identity of % is +inf (also right side only).
I read $n % any( $n..Inf ) == $n. The point is there's no
unique right identity and thus (Num,%) disqualifies for a
Monoid. BTW, the above is a nice example where a junction
needn't be preserved :)
E.g. if XY is left
Hola,
Some of us on #perl6 bitched once more about how lazy will make our
IO brain hurt a lot.
The concensus is that a lazy context has not been discussed yet.
Here is a proposal for lazyness defined with coroutines.
we have a lazy modifier:
my $a = lazy { get_value(5, 10) };
C. Scott Ananian wrote:
I think Ingo was trying to explicitly specify the normally-implicit
invocant; ie, invoke the method via the reference *without* using a '.'.
If this is possible (and I think it is), it's not (yet) clear what the
syntax would be. Maybe
$ref(Foo.new():)
I think for MMD
Hola,
In PerlGuts Illustrated you have some very pretty diagrams...
Could you please hint me on what you generated them with, so that I
can use it for the forthcomming PugsGuts Illustrated?
Grazie!
--
() Yuval Kogman [EMAIL PROTECTED] 0xEBD27418 perl hacker
/\ kung foo master: /me kicks
Leopold == Leopold Toetsch [EMAIL PROTECTED] writes:
Leopold Colin Paul Adams [EMAIL PROTECTED] wrote:
I have a problem with this - namely that the function is
variadic, and the interface generator can't cope with this.
Leopold Have a look at src/inter_run.c e.g.
Leopold
On Thursday 19 May 2005 09:39, Luke Palmer wrote:
On 5/19/05, Edward Cherlin [EMAIL PROTECTED] wrote:
It turns out that the domain and range and the location of
the cut lines have to be worked out separately for different
functions. Mathematical practice is not entirely consistent
in
On Thursday 19 May 2005 12:48, Uri Guttman wrote:
LP == Luke Palmer [EMAIL PROTECTED] writes:
LP On 5/18/05, Anthony Heading [EMAIL PROTECTED] wrote:
Is there a way to target hyperoperators at different axes
of a multi-dimensional array? This is an attractive
feature of various
Colin Paul Adams wrote:
Leopold == Leopold Toetsch [EMAIL PROTECTED] writes:
Leopold void * Parrot_runops_fromc_arglist(Parrot_Interp
Leopold interpreter, PMC *sub, const char *sig, va_list args)
Despite what I said before, this is actually worse than
Parrot_call_sub.
The interface
At 8:10 PM +0100 5/20/05, Colin Paul Adams wrote:
Leopold == Leopold Toetsch [EMAIL PROTECTED] writes:
Leopold Colin Paul Adams [EMAIL PROTECTED] wrote:
I have a problem with this - namely that the function is
variadic, and the interface generator can't cope with this.
Leopold
On Thursday 19 May 2005 19:51, Sam Vilain wrote:
Edward Cherlin wrote:
Here is the last answer from Ken Iverson, who invented
reduce in the 1950s, and died recently.
file:///usr/share/j504/system/extras/help/dictionary/intro28
.htm
On Fri, 20 May 2005, Dan Sugalski wrote:
Well, mostly. string-cstring conversion is potentially lossy, if for no
other reason than embedded nulls will get in your way. I see we're not
exposing anything to do that, though, which we ought to fix.
pascal-style strings (ie, char* and length) are the
On 20/05/05 22:06 +0300, Yuval Kogman wrote:
Hola,
In PerlGuts Illustrated you have some very pretty diagrams...
Could you please hint me on what you generated them with, so that I
can use it for the forthcomming PugsGuts Illustrated?
I used to sit next to Gisle at ActiveState.
At 4:35 PM -0400 5/20/05, C. Scott Ananian wrote:
On Fri, 20 May 2005, Dan Sugalski wrote:
Well, mostly. string-cstring conversion is potentially lossy, if
for no other reason than embedded nulls will get in your way. I see
we're not exposing anything to do that, though, which we ought to
fix.
On Fri, 20 May 2005, Yuval Kogman wrote:
then it is not finalized into a real value. Here's how the range
operator would be implemented:
sub infix:.. ($from, $to where { $to $from }){ reverse $to ..
$from }
sub infix:.. ($from, $to) { lazy gather {
while ($from =
On Fri, May 20, 2005 at 05:15:24PM -0400, C. Scott Ananian wrote:
On Fri, 20 May 2005, Yuval Kogman wrote:
then it is not finalized into a real value. Here's how the range
operator would be implemented:
sub infix:.. ($from, $to where { $to $from }){ reverse $to ..
$from }
On Fri, May 20, 2005 at 14:20:04 -0700, Jan Dubois wrote:
IIRC(AIDRC), he hand-hacked postscript files for those diagrams :P
After drawing them with a pen on graphing paper first to get the
coordinates right. The PostScript sources are all on CPAN too:
I am impressed and humbled.
I will
Dan Sugalski wrote:
There are interfaces in the extension system to get a void * and length
back from a PMC when fetching string data out, but I see we don't have
that for plain strings. I'll probably fix that this weekend if someone
doesn't beat me to it.
There was a disucssion WRT that on
On Fri, 20 May 2005, Colin Paul Adams wrote:
Leopold void * Parrot_runops_fromc_arglist(Parrot_Interp
Leopold interpreter, PMC *sub, const char *sig, va_list args)
And as for hand-writing interfaces, I'm not sure I know HOW to create
a va_list.
void *Parrot_runops_fromc_argsN(Parrot_Interp
On Fri, May 20, 2005 at 17:15:24 -0400, C. Scott Ananian wrote:
This is very elegant. It might be worthwhile for someone to attempt to
define a 'core
perl' set of operators, etc, so that the 'rest of perl' can be defined in
perl proper...
Have a look at synopsis 29... For documentation
On Fri, 20 May 2005, Dan Sugalski wrote:
So, I see four real options:
1) Someone fixes the Eiffel interface generator to understand C variadic
functions.
2) We provide a function and method call interface that assumes you've
already pre-filled in the registers according to parrot's calling
r8136, I'm seeing this test failure:
$ perl t/harness t/library/pcre.t
t/library/pcreCan't use string (Test::Builder) as a HASH ref while
strict refs in use at lib/Test/Builder.pm line 304.
# Looks like your test died before it could output anything.
t/library/pcredubious
Test
On Fri, 2005-05-20 at 17:49 -0400, Dino Morelli wrote:
r8136, I'm seeing this test failure:
$ perl t/harness t/library/pcre.t
t/library/pcreCan't use string (Test::Builder) as a HASH ref while
strict refs in use at lib/Test/Builder.pm line 304.
This is a feature of the Test-Simple
On Fri, 20 May 2005, Brian Ingerson wrote:
On 20/05/05 22:06 +0300, Yuval Kogman wrote:
Hola,
In PerlGuts Illustrated you have some very pretty diagrams...
Could you please hint me on what you generated them with, so that I
can use it for the forthcomming PugsGuts Illustrated?
I
# New Ticket Created by jerry gay
# Please include the string: [perl #35900]
# in the subject line of all future correspondence about this issue.
# URL: https://rt.perl.org/rt3/Ticket/Display.html?id=35900
dynclasses and spawnw have been busted on win32 for some time now.
with this patch,
# New Ticket Created by jerry gay
# Please include the string: [perl #35903]
# in the subject line of all future correspondence about this issue.
# URL: https://rt.perl.org/rt3/Ticket/Display.html?id=35903
i'm seeing the same failure, with perl 5.8.6, msvc 7.1, and win32
--
Mark A. Biggar wrote:
Well the identity of % is +inf (also right side only).
I read $n % any( $n..Inf ) == $n. The point is there's no
unique right identity and thus (Num,%) disqualifies for a
Monoid. BTW, the above is a nice example where a junction
needn't be preserved :)
If as usual
On Fri, 20 May 2005, chromatic wrote:
On Fri, 2005-05-20 at 17:49 -0400, Dino Morelli wrote:
r8136, I'm seeing this test failure:
$ perl t/harness t/library/pcre.t
t/library/pcreCan't use string (Test::Builder) as a HASH ref while
strict refs in use at lib/Test/Builder.pm line 304.
Mark~
On 5/20/05, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote:
Mark A. Biggar wrote:
Well the identity of % is +inf (also right side only).
I read $n % any( $n..Inf ) == $n. The point is there's no
unique right identity and thus (Num,%) disqualifies for a
Monoid. BTW, the above is a
59 matches
Mail list logo