Re: Retry: ITypes and VTypes.
Brent 'Dax' Royal-Gordon writes: > Alexey Trofimenko <[EMAIL PROTECTED]> wrote: > >my $var = "test"; > >my @arr := $var; > > error? or maybe it would be the same weirdness, like in former example? or > > maybe it's a ["test"]? > > The := operator uses the same rules as parameter passing. So, what do > you think this does? > > sub foo(@arr) {...} > foo($var); > > I would assume the answer is "syntax error". (Remember, array > parameters don't slurp in Perl 6 unless they have a *.) Not really "syntax error", but runtime error. The function is expecting an array, and it gets a string. This is perfectly legal: sub foo(@arr) {...} my $var = [1,2,3]; foo($var); And it works just as if there were an @ on the front of var. Luke > > -- > Brent 'Dax' Royal-Gordon <[EMAIL PROTECTED]> > Perl and Parrot hacker > > "For those of you that can't spell, this site also contains free > imags, iamges, imges, picturs, pcitures, picktures, picturess, and > pistures." >
S03 inconsistency
Either --- S03.pod.old 2005-02-06 13:12:21.0 +0100 +++ S03.pod 2005-02-06 13:12:46.0 +0100 @@ -325,7 +325,7 @@ autoincrement ++ -- exponentiation ** symbolic unary ! + - ~ ? * ** +^ ~^ ?^ \ -multiplicative * / % x xx +& +<< +>> ~& ~<< ~>> +multiplicative * / % x xx +& +< +> ~& ~< ~> additive + - ~ +| +^ ~| ~^ junctive and (all) & junctive or(any) | ^ or --- S03.pod.old 2005-02-06 13:12:21.0 +0100 +++ S03.pod 2005-02-06 13:14:07.0 +0100 @@ -36,7 +36,7 @@ =item * Bitwise operators get a data type prefix: C<+>, C<~>, or C. For example, C<|> becomes either C<+|> or C<~|> or C, depending on whether the operands are to be treated as numbers, strings, or boolean -values. Left shift C< << > becomes C< +< >, and correspondingly with +values. Left shift C< << > becomes C< +<< >, and correspondingly with right shift. Unary C<~> becomes either C<+^> or C<~^> or C, since a bitwise NOT is like an exclusive-or against solid ones. Note that C is functionally identical to C. C differs from C<||> in that Juerd -- http://convolution.nl/maak_juerd_blij.html http://convolution.nl/make_juerd_happy.html http://convolution.nl/gajigu_juerd_n.html
Pugs 6.0.0 released.
(Sorry for the cross-posting; announcement of future releases will appear only on the perl6-compiler list.) Quite appropriately, on Day 6 of Pugs, I have released Pugs 6.0.0. It should be on a CPAN near you in a few hours, under the Perl6::Pugs namespace. You may install it from the CPAN shell just like any other CPAN module, provided that you have GHC on your system. This initial release offers the following features: * Evaluation of most simple Perl6 expressions. * Junctions and chained comparisons. * Interactive shell and #!/usr/bin/pugs support. See the Perl6::Pugs POD 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 testing. Also I'd like to thank freenode #haskell for tolerating my newbie questions, as well as various helpful clarifications from perl6-language. Cheers! :-) Feedbacks, patches, ideas and other suggestions are very much welcome. Thanks, /Autrijus/ pgpxL2wAQuqMw.pgp Description: PGP signature