?
my ($x, @a);
$x := @a[0];# vivified or not?
@a = (1..100);
say $x;
Thanks,
/Autrijus/
pgpY7nocOXCNd.pgp
Description: PGP signature
On Sat, Apr 23, 2005 at 09:50:26PM +0200, Juerd wrote:
Autrijus Tang skribis 2005-04-24 3:47 (+0800):
$x := @a[0];# vivified or not?
Vivified, because you're taking a reference (not at language level) and
you can't have a reference (at internal level) pointing to something
of the intended:
# Works correctly
%ret = map(sub ($_) { $_ = uc $_ }, split(, $text));
Is this a known issue?
Thanks,
/Autrijus/
pgpB0h0cY8Ev9.pgp
Description: PGP signature
to me.
Thanks,
/Autrijus/
pgpSrBabV4fWE.pgp
Description: PGP signature
.
That way, p6-to-p6 translators in the future can, at worst, trigger a
reparse under the appropriate subrules level, and obtain the information
we optimized away.
Thanks,
/Autrijus/
pgpMrB9z2eohX.pgp
Description: PGP signature
On Wed, Apr 20, 2005 at 10:21:32AM -0700, Larry Wall wrote:
On Thu, Apr 21, 2005 at 12:50:56AM +0800, Autrijus Tang wrote:
: I see. Do you think preserving the /span/ (i.e. the character offset
ranges)
: of each AST element is enough to do that? That effectively means each
: node points
So, following up on the Parens handling, are these two equivalent?
# Assuming is has the parameter signature (Str, Str, Str)
is((1,2), (3,4), hey);
is([1,2], [3,4], hey);
What happens if is is of type (Any, Any, Str)?
Thanks,
/Autrijus/
pgp0OW38SoE0X.pgp
Description: PGP signature
;
If there is some consensus on this, I'd like to change Pugs's
existing `eval_perl5()` and `inline` syntax to agree with it.
Thanks,
/Autrijus/
pgpcJeRR2TD26.pgp
Description: PGP signature
-- qr/abc$/ is just fine. Is it something we need
to special-case for rx?
Thanks,
/Autrijus/
pgpSvwQMyMWSN.pgp
Description: PGP signature
allowed
infinite slicing of arrays to simply mean slice until the end.
That is:
@b = @a[1...]; # elements from 1 onward
@b = @a[1..Inf];# same thing
I think that's far more more intuitive and convenient.
Thanks,
/Autrijus/
pgpJeoZ9nKnM7.pgp
Description: PGP signature
I am delighted to report that the first major milestone of Pugs, version
6.2.0, has been released to CPAN:
http://wagner.elixus.org/~autrijus/dist/Perl6-Pugs-6.2.0.tar.gz
SIZE (Perl6-Pugs-6.2.0.tar.gz) = 642482
MD5 (Perl6-Pugs-6.2.0.tar.gz) = 8d5438d49db872ffe2394fd4995d335b
,
/Autrijus/
pgpg8GK3nohFL.pgp
Description: PGP signature
supports to get this done. Parrot is
really much, much saner than I had hoped; it eeriely supports lots of
things needed by a Perl 6 implementation. I wonder why that is the
case. :-)
Thanks,
/Autrijus/
pgp3LrqcpdaGL.pgp
Description: PGP signature
in Perl6: The Gathering golfing tournaments! :)
I like them. They look really really good to my eyes after the first
20 minutes or so of mental reconfiguration. For some strange
psychological reasons, they make Pugs 6.2 so much more enjoyable to
work on for me. :-)
Thanks,
/Autrijus
to implement it that way.
Is using wrap/call the correct choice here, or is there another way
to do it that I missed?
Thanks,
/Autrijus/
pgpU4SEdazzFT.pgp
Description: PGP signature
On Wed, Mar 16, 2005 at 08:46:03PM +0800, Autrijus Tang wrote:
Does that form still work with Perl 6? Or should I use this?
{ local _ := ok; call($lhs == $rhs, $todo); }
s/local/my/ of course. :-)
Thanks,
/Autrijus/
pgpGy03aIypYS.pgp
Description: PGP signature
On Wed, Mar 16, 2005 at 10:24:16AM -0800, Larry Wall wrote:
On Wed, Mar 16, 2005 at 08:46:03PM +0800, Autrijus Tang wrote:
: Is using wrap/call the correct choice here, or is there another way
: to do it that I missed?
wrap/call should do what you want there, but if you want to hack
to not conflict with user-defined subs.
Thanks,
/Autrijus/
pgpMdkE8bpGa5.pgp
Description: PGP signature
On Tue, Mar 15, 2005 at 08:23:19AM -0800, Larry Wall wrote:
I'd go with either istrue or so. ok is another possibility,
though that seems to connote definedness more than truth.
Hmm, so is so good. So can we make it so? :)
Thanks,
/Autrijus/
pgpVnDqeuQFYm.pgp
Description: PGP signature
in it. :-)
As long as surprises can be minimized (or at least explained), that's
entirely fine, I think. :)
Thanks,
/Autrijus/
pgpnyvrdLFRBW.pgp
Description: PGP signature
,
/Autrijus/
pgpEBaFEN7Eb3.pgp
Description: PGP signature
order. What will be more fun is if they are all
part of some other lazy lists, which may be accessed in some
unpredictable order.
That is why lazy languages typically use some sort of typechecking to
avoid mixing computations with actions... :)
Thanks,
/Autrijus/
pgp0PQK7x77aI.pgp
Description
On Tue, Mar 08, 2005 at 04:55:28PM -0600, Rod Adams wrote:
I thought Larry already declared that we are not making Perl act like ML
(yet).
And that was re: type inferencing, not re: pattern matching. :)
Thanks,
/Autrijus/
pgp3tE8H37UB0.pgp
Description: PGP signature
Just a quick question: Is Hash keys still Strings, or can they
be arbitary values? If the latter, can Int 2, Num 2.0 and Str 2
point to different values?
Thanks,
/Autrijus/
pgpWfMqiYCwrU.pgp
Description: PGP signature
. This document
(PA01) is a higher-level overview of the project.
* What is Pugs?
Started in February 2005, Pugs is an implementation of the Perl 6 language.
Autrijus Tang is responsible for the design and development of Pugs with
help from a group of committers and contributors.
Thanks,
/Autrijus
the most common ancestor rule can be applied without
exceptions. Am I on crack here? :)
Thanks,
/Autrijus/
pgp9m2LSuByG9.pgp
Description: PGP signature
= .. ^.. ..^ ^..^
How many are similarily right associative? I was listing everything
as non-associative, but it seems that but and does is left-assoc?
Thanks,
/Autrijus/
pgppzCeVIgOIK.pgp
Description: PGP signature
By the way, is $pair.keys simply ($pair.key)?
What is %hash.key? Type error?
Thanks,
/Autrijus/
pgpZDx9WRiA1B.pgp
Description: PGP signature
!
Thanks,
/Autrijus/
pgpfXyKp9P33h.pgp
Description: PGP signature
write to $!.filename: $! for *$IN;# Or
however it's done this week
I think it's an unary = this week, according to S04:
print for =*$IN;
Thanks,
/Autrijus/
pgpK2a19S3Fk6.pgp
Description: PGP signature
Hi. As my today's journal ( http://use.perl.org/~autrijus/journal/23258 )
announced, we have created a #perl6 channel on freenode to discuss
everything about perl6, in particular to coordinate development of
the Perl6 Compiler and Pugs. All is welcome to join.
Also, I've registered http
$rhs;
return 0
}
Hrm, so Junction.isa(Any) == False? I need to retype print(), say()
and other primitives, then.
Thanks,
/Autrijus/
pgpFXp9YvzxMF.pgp
Description: PGP signature
quicksort( *[] )
Can mean a slurpy nullnary, but I failed to find relevant text in
Synopses, so here I am. :-)
(PS. Yes, I understand that I can use array unpacking and have
quicksort always take a single array argument, but I'd still like to
inquire about slurpy nullary...)
Thanks,
/Autrijus
ordered by local vs global, then by subtyping
distance of invocants, then finally by then finally by the order of
creation of CODE objects. That's just a working heuristics, though.
Thanks,
/Autrijus/
pgppdqXsP7VuK.pgp
Description: PGP signature
? Or is there a way to annotate values with types, similar
to Haskell's :: construct?
pugs (1 2, 2 1)
(0 as Bool, 1 as Bool)
Thanks,
/Autrijus/
pgpBOnIuv0xyM.pgp
Description: PGP signature
On Sat, Feb 12, 2005 at 10:55:05AM -0600, Patrick R. Michaud wrote:
On Sat, Feb 12, 2005 at 12:09:37PM +0800, Autrijus Tang wrote:
[...]
- one() checks its operands for duplicates; if found, it collapses
itself into an empty one() junction, thus failing all tests
to keep implementation decision of using Sets without duplicate
elements, unless it is unavoidable, in which case I'll switch back
to a List...
Thanks,
/Autrijus/
pgpmc4fAvk4y2.pgp
Description: PGP signature
(); the .values() method
will then return two items for each element in the none() subset, and one
for each in the one() subset.
Does it make sense?
Thanks,
/Autrijus/
pgpQD8lgtm8ll.pgp
Description: PGP signature
:
% wget -m -np http://svn.openfoundry.org/pugs/
% cd svn.openfoundry.org/pugs
% perl Makefile.PL
% make
% ./pugs -e (any(2,3,4,5) any(4,5,6,7)).perl
((4 | 5 | 6 | 7))
Thanks,
/Autrijus/
pgpuMAO1H1yOJ.pgp
Description: PGP signature
certainly adjust to the \ notation.
Thanks,
/Autrijus/
pgpnevsOGysCw.pgp
Description: PGP signature
On Fri, Feb 11, 2005 at 07:45:33PM +0100, Thomas Sandla wrote:
Autrijus Tang wrote:
as well as the non-short-circuitting !! logical operator, and the
lower-precedenced nor.
I'm not sure if '!' fits the heavy weight perl6 grammar. But why is
'nor' not short-circuitting? It only continues
(1, 3), 2 )
so that 2 now only occurs once? Is it sane?
Thanks,
/Autrijus/
pgpqV6sVw2dDk.pgp
Description: PGP signature
. :-/
Thanks for your quick feedback. :)
/Autrijus/
pgpBJZ8wz5yl7.pgp
Description: PGP signature
On Sat, Feb 12, 2005 at 03:28:15AM +0800, Autrijus Tang wrote:
Yes. In Pugs 6.0.3 (released one minute ago), that operator is
simply called :
I satnd corrected. The implementation is incorrect.
Pugs 6.0.4 has just been released (now with the eval primitive!),
it has cleaned up the collapsing
are
aware of? I'd like to work out declarations and implementations
of them in one sweep, if possible. :-)
Thanks,
/Autrijus/
pgpztJ5GG2UX9.pgp
Description: PGP signature
On Sat, Feb 12, 2005 at 03:16:20PM +0800, Autrijus Tang wrote:
the toplevel sequencing only handles IO of ... types, so the junction
above will not print anything. Instead it may raise a warning of using a
Junction in a void context, or something equally ominous.
Thinking about
Hey. In Pugs 6.0.2 (cf. http://use.perl.org/~autrijus/journal/23093 )
I'm beginning to flesh out a signature list for primitives. It's
currently, well, quite primitive but already works with the multimethod
dispatched and the context propagator, so I'd like to call for review:
http
holds, so
I think it's the way to go. Please correct me if you see serious
flaws with this approach.
Thanks,
/Autrijus/
pgp2YqC1IJS0m.pgp
Description: PGP signature
for more details.
I will keep an implementor's journal in use.perl:
http://use.perl.org/~autrijus/journal/
Project-related information are currently kept on the Haskell Wiki:
http://autrijus.org/pugs/
Special thanks to many people on irc.perl.org #perl, especially Juerd,
for last-minute
On Sat, Feb 05, 2005 at 02:08:32PM +0800, Autrijus Tang wrote:
Here's another quick question: In S03 zip() is used like this:
for zip(@names, @codes) - $name, $zip { ... }
But in S04 it becomes:
for zip(@a;@b) - $a, $b { ... }
Why semicolon? Is it a special form? Or am I
this:
pugs ? 1|2 = 3|4
(((1 = 3)|(1 = 4))|((2 = 3)|(2 = 4)))
Since junctions are documented to only flatten on boolean context,
here the pair-building arrow has been autothreaded. Is it the intended
semantic? What about the list-building semicolon?
Thanks,
/Autrijus/
pgpj7CbHk75Wh.pgp
Sick, eh?
Thanks,
/Autrijus/
pgp5MAviWjsuy.pgp
Description: PGP signature
:
pugs (0/0 .. 1/0)
That is, do we need to preserve NaN and Inf at the Int (arbitary
precision inteeger) level?
Thanks,
/Autrijus/
pgpI58F5WlIHc.pgp
Description: PGP signature
that
if the left hand side evaluates to #f, it will return the junction
itself, not #f. This is true in both spec and pugs implementation.
Thanks,
/Autrijus/
pgpGt6mI3i4SY.pgp
Description: PGP signature
the .bit
value of the referent?
Thanks,
/Autrijus/
pgp5YiP7zSHyI.pgp
Description: PGP signature
.values,
and it followed quite naturally.
Cheers,
/Autrijus/
...Hmm. I was going to ask something about infix:? and function
composition, but that seems to be a really bad idea, so never mind that. :)
pgp4sW1ZI61tJ.pgp
Description: PGP signature
On Sat, Feb 05, 2005 at 02:39:26PM +, Nicholas Clark wrote:
On Sat, Feb 05, 2005 at 10:04:02PM +0800, Autrijus Tang wrote:
On Sat, Feb 05, 2005 at 01:52:05PM +, Nicholas Clark wrote:
#t and (0 | 6) 2 # reduction in boolean
context(!)
Why
. It is not short-circuiting over individual values.
So I agree. All evaluations to sets needs to be done fully.
Thanks,
/Autrijus/
pgpkA1EAm1PeL.pgp
Description: PGP signature
On Thu, Feb 03, 2005 at 03:59:06PM -0800, Brent 'Dax' Royal-Gordon wrote:
Autrijus Tang [EMAIL PROTECTED] wrote:
However, I'd still like to know whether my understanding on punning
(same class 'Array' used as both Implementation Type and Value Type)
and the validity of matching on $var
On Fri, Feb 04, 2005 at 06:04:52PM +0800, Autrijus Tang wrote:
my @array of Array;
my @array is Array of (Any is Array of (Any is Scalar))
If so, may I consider it as equivalent to this Haskell code?
class TArray baseVtype elemVtype where {- ... -} -- Array Trait
class
Pair, Junction and Undef are not list among Perl6's standard
types in S06. I'm assuming that they are actually basic types for now;
if that is the case, below is a patch to say that.
Thanks,
/Autrijus/
--- S06.pod.origFri Feb 4 04:29:34 2005
+++ S06.pod Fri Feb 4 19:32:53 2005
?
Or something else altogether?
Thanks,
/Autrijus/
pgpKls8O9J6nb.pgp
Description: PGP signature
Today I have finished implementing 90% of primitive operators; Pugs can
now evaluate most simple expressions, including junctive autothreading
and magical/infinite ranges. Their implementation are in:
http://wagner.elixus.org/~autrijus/darcs/pugs/Prim.hs
As such, there are some corner cases
On Sat, Feb 05, 2005 at 04:44:41AM +0800, Autrijus Tang wrote:
* What is the value of a reference in any of the scalar contexts?
Currently I'm blindly dereferencing it.
It seems that I got four out of five correct; the blind referencing
has an important exception in the references
intuition are way off
base, please do let me know. :-)
Thanks,
/Autrijus/
pgpZDOZGGqHTa.pgp
Description: PGP signature
On Thu, Feb 03, 2005 at 11:17:50AM -0500, Mark J. Reed wrote:
On 2005-02-03 at 11:13:30, Autrijus Tang wrote:
Today I've started implementing typing relations for value types in
FP6. ...
Shouldn't this have gone to perl6-internals, not perl6-language?
Uh, as this is an ask
On Fri, Feb 04, 2005 at 12:19:36AM +0800, Autrijus Tang wrote:
Uh, as this is an ask-for-clarification for a Synopsis, I think p6l
is the correct forum. Of course, as I'm new to this list, I may be
totally wrong, in which case please tell me so. :-)
To be more precise, according to S06
with such a subset...
Thanks,
/Autrijus/
pgpwVyOtfCpvq.pgp
Description: PGP signature
sincere apologies for not making my question clear the first time.
Thanks,
/Autrijus/
pgpPn682DHnBz.pgp
Description: PGP signature
On Fri, Feb 04, 2005 at 04:09:03AM +0800, Autrijus Tang wrote:
Okay. So Egg is the value type for elements in @carton. But what
is the implementation type of @carton?
my @carton of Egg is Scalar;# is @carton Scalar?
my @carton of Egg is Array; # is @carton Array
and semantics for one() gives me troubles,
as my intuition on how to evaluate one() is weak.
As the implementation progresses, I'll probably bother the list with
many of such naive questions. Thanks in advance for your patience. :-)
Cheers,
/Autrijus/
pgpTz6ZM9SacC.pgp
Description: PGP signature
. Please, keep them coming.
I will. :)
Thanks,
/Autrijus/
pgp80nVsiTtcX.pgp
Description: PGP signature
already in Perl6.
Core support for reading (and seeking) HTTP/FTP sources would be pretty cool,
but not required.
Thanks,
/Autrijus/
pgpRle6yihF0l.pgp
Description: PGP signature
201 - 273 of 273 matches
Mail list logo