Ann Barcomb
Sun, 01 Oct 2006 15:23:37 -0700
This week on the Perl 6 mailing lists
"And here I thought you were a responsible, law-abiding citizen... :P "
-- Jonathan Lang, commenting on Larry Wall's `self.HOW does Hash`
Language
class interface of roles <http://xrl.us/rzbh>
TSa wondered how typing of mixins <http://xrl.us/rzbi> would look in
Perl 6. A code example of how it might look was included. There were
also some questions on roles in Perl 6.
Capture Literals <http://xrl.us/rzbj>
Responding to an earlier thread, Austin Hastings asked if Capture
literals would replace or unify "assuming"/"currying".
Motivation for /<alpha>+/ set Array not Match? <http://xrl.us/rzbk>
In a previous week, Audrey Tang quoted a section of S05 concerning
subrules. She found the 'quantified' clause to be unintuitive and
wondered if it would be possible to modify it to produce Match objects
and to reserve Array only for noncontiguous same-name subrules.
Patrick R. Michaud and Flavio S. Glock made some alternate
suggestions.
More recently Audrey replied to the thread, wondering if there was a
hidden cost to making `/<foo>+/` always react so that `$<foo>.from`
returns something. Masak preferred the proposed semantics and asked if
the question had been discussed off-list.
Nitpick my Perl6 - parametric roles <http://xrl.us/rzbm>
Sam Vilain sent some code on Perl 6 core types as collections and
asked if anyone would like to poke holes in it. TSa applauded the use
of functions but wondered if it would work. Several other people
followed up on that thought.
Mutability vs Laziness <http://xrl.us/rzbn>
Aaron Sherman pursued a conversation which began in IRC. He listed
some immutable types declared in S06 and noted that there appear to be
three core attributes (Mutability, Laziness and Ordered), each of
which has two states (true or false). From this he derived 8 types of
containers.
Dave Whipp thought there was a fourth attribute, exclusivity. Sam
Vilain felt that ordered was not an attribute of a collection.
[svn:perl6-synopsis] r12398 - doc/trunk/design/syn <http://xrl.us/rzbo>
In a recent commit, Larry Wall removed the special `[,]`, which is now
just a list op form of `[...]`. In order to support the `|func()`
syntax, `|` became the new disigilized `*`.
Luke Palmer replied in support of the new syntax. TSa also approved,
but would have liked the new operator spelled. Aaron Crane thought
that was undesirable because there are already terms which begin with
`/`, namely regular expressions.
Common Serialization Interface <http://xrl.us/rzbp>
Brad Bowman wondered if there was a common element to a serialization
role which could be included in the default implementation. Mark
Stosberg noted that there is already a `.yaml` and a `.perl` to
serialize to these formats, but he did not know if they were suitable
substitutes for the role-based approach Brad had in mind. He included
a code sample. Aaron Sherman and Luke Palmer offered additional code
examples. Larry Wall commented that it makes a big difference whether
the entire string must be held in memory or not.
[svn:perl6-synopsis] r12417 - doc/trunk/design/syn <http://xrl.us/rzbq>
Audrey Tang committed a change which introduced the `$$x` form in
adverbial pair parsing to S02 and canonicalized the term 'item' in S02
and S04.
[svn:perl6-synopsis] r12432 - doc/trunk/design/syn <http://xrl.us/rzbr>
In S03, Audrey Tang noted that chained comparisons short-circuit and
never evaluate arguments more than once.
RFC: multi assertions/prototypes: a step toward programming by contract
<http://xrl.us/rzbs>
Aaron Sherman wrote to suggest a signature prototype that all multis
defined in or exported to the current namespace must match, as a means
of implementing the paradigm of programming by contract.
Trey Harris felt that the point of multiple dispatch is that arguments
are not bound to a single type, and the proposal might defeat this
use, although junctive types, subsets and roles make 'single type'
less of a constraint. Miroslav Silovic was bothered by the possible
duplication of functionality and believed that declarative
requirements should go in to roles. Many other people responded to
this thread.
In addition, there was a discussion on the terminology of libraries in
Perl 5 and Perl 6--'package' being the Perl 5 term, and 'module' the
Perl 6 term. The definition of 'programming by contract' was also
discussed.
There was also a discussion on whether 'package' implied a Perl 5
library and 'module' suggested a Perl 6 one. Larry Wall attempted to
clarify.
special named assertions <http://xrl.us/rzbt>
David Brunton posted about an IRC conversation from earlier. He listed
the seven special named assertions found in S05, and the twenty-four
found in `docs/Perl6/Overview/Rule.pod`. He found another one in
`t/regex/from_perl6_rules/stdrules.t`. In his opinion, it was worth
creating a single place in S05 where all of these named assertions are
listed.
Patrick R. Michaud disagreed with the inclusion of `<'...'>` and
`<"...">` as named assertions. He stated that he would compare the
list with what PGE has implemented and report differences. Mark A.
Biggar noted that the documentation should distinguish between
pre-defined character classes and special builtins. Patrick responded
with PGE's view on what constitutes a special builtin.
Parrot Porters
A dedicated per-context stack for bsr/jsr/ret <http://xrl.us/rzbx>
Bob Rogers sent a patch to create a `return_stack` for `bsr/jsr/ret`
ops. Leopold Toetsch replied that separate stacks are good, but
wondered if a return stack per context was desired. Bob Rogers replied
in detail and included another patch.
postgres interface <http://xrl.us/rzby>
Leopold Toetsch has been working on `postgres.pir` and reported
several changes, including a new test file. Bob Rogers sent a patch to
make it more forgiving of an absent `libpq.so`. It was applied.
[perl #40410] Segfault in packfile code <http://xrl.us/rzbz>
In ticket [perl #40410] <http://xrl.us/rzb2>, Jonathan Worthington
reported a segmentation fault in generating a packfile for compiled
PIR generated by .Net. Later he found the bug and implemented a
workaround.
FYI improved pugs smokes <http://xrl.us/rzb3>
Leopold Toetsch referred to the recently improved smoke tests for
Pugs, and wondered if it would be possible to do something similar for
Parrot. Jerry Gay replied that he'd been working on a Parrot
implemention.
External PDD Checkin <http://xrl.us/rzb4>
chromatic reported that he had added details to the external API draft
PDD and welcomed comments on `docs/pdds/clip/pdd10_embedding.pod`.
[PATCH] Parrot-Embed on Win32 <http://xrl.us/rzb5>
Fran??ois Perrad supplied a patch to make Parrot-Embed compile and run
on Win32.
FYI compiling PIR function calls <http://xrl.us/rzb6>
Leopold Toetsch wanted people to know about alternate syntax for
generating PIR calls from a compiler:
`.pcc_begin
.arg "hello"
.arg "n"
.invocant obj
.meth_call "_meth"
.result $S0
.pcc_end`
Allison Randal replied that she felt the problem was one of
inconsistency. She gave a few suggestions, which Leopold Toetsch
responded to. Jonathan Scott Duff also proposed a slight modification
of syntax. A discussion on the syntax followed.
[svn:parrot-pdd] r14741 - in trunk: . docs/pdds/clip
<http://xrl.us/rzb7>
Allison Randal made some modifications to PDD22 to create a first
release candidate of the I/O PDD.
A moment of Zen <http://xrl.us/rzb8>
Allison Randal posted that the single most important thing in the
project is shipping a 1.0 release of Parrot, which is now very close.
She called for functionality over elegant theory for the moment.
call/return and CPS <http://xrl.us/rzb9>
Watson Ladd asked how call and ret opcodes will interact with
continuations. chromatic replied that the opcodes invoke the
appropriate continuations.
PDD 22 - I/O release candidate 1 <http://xrl.us/rzca>
Allison Randal announced that she'd committed an updated I/O PDD. She
requested feedback, especially on which lightweight concurrency model
to use for asynchronous operations. She also asked for a reaction on
async ops returning status objects while sync ops return integer error
codes.
chromatic suggested that ops could always return PMCs, and simply
check the intval if required. Tim Bunce wondered if speed-sensitive
ops which might be used in loops could be given the PMC to reuse.
Leopold Toetsch remarked that he did not like I/O opcodes and
explained why. chromatic disagreed with one of the arguments and
Leopold replied.
Joshua Hoblitt asked for more details on Allison's comment about
concurrency models: was she speaking of the Parrot API, the actual
implementation, or both? He felt that the implementation would need to
be highly platform specific.
[CAGE] perl coding standards... <http://xrl.us/rzcb>
Will Coleda created a perlcritic tests, `t/codingstd/perlcritic.t`,
which isn't run by default. It currently reports only a few rules. He
suggested that Cage Cleaners could run this test to receive a long
list of things to fix. He offered some advice on addressing the issues
which show up.
[perl #40419] 2 PDD 07s <http://xrl.us/rzcc>
In ticket [perl #40419] <http://xrl.us/rzcd>, Will Coleda reported
that there are two PDDs numbered 07.
Prototyping variable-sized PMCs <http://xrl.us/rzce>
Allison Randal summarized a telephone conversation with Leopold
Toetsch. They discussed proposals on variable-sized PMCs and a shared
base class for PMC types ('Two new pdds <http://xrl.us/rzcf>'). In
Allison's opinion, variable-sized PMCs are a step toward closing the
gap between low-level PMCs and higher-level Parrot Object PMCs. She
also thought there were several good ideas in the shared base class
proposal. The new PMCs will be implemented first as prototypes, and
assessed/rewritten without changing the existing system.
Two new pdds <http://xrl.us/rzcf>
Leopold Toetsch announced two new documents in `docs/pddfs/clip` as of
r14774. One, `pddXX_cstruct.pod` is the metaclass of all publically
accessible C-derived structures used in Parrot. The other,
`pddXX_pmc.pod`, describes the general structure of PMC internal
layout.
Jonathan Worthington replied to the commit ([svn:parrot-pdd] r14774 -
in trunk: . docs/pdds/clip <http://xrl.us/rzqk>) to give his thoughts
on Leopold's proposals.
A related thread is 'Prototyping variable-sized PMCs
<http://xrl.us/rzce>'.
FYI: $job <http://xrl.us/rzcg>
Leopold Toetsch announced that his job will require him to reduce his
Parrot commitments, but that he would continue to follow development
as time permits. Allison Randal thanked him for his contributions.
socket related constants <http://xrl.us/rzch>
Nicholas Clark replied to an older thread. He said that there are two
problems to be solved, namely parsing C header files and identifying
the constants, and injecting identified constants in to Parrot
appropriately. Nicholas explained a little about how this is going in
Perl 5.10.
Joshua Hoblitt was reminded of the question of whether anyone had
looked at APR for doing portable I/O.
[HOWTO] call a method on a PMC in PIR <http://xrl.us/rzck>
Karl Forner wanted to call the `elements()` method on a
FixedBooleanArray, or add a custom method `get_allocated_size()` to
the FixedBooleanArray.pmc. Leopold Toetsch replied with suggestions.
Draft of Bytecode PDD <http://xrl.us/rzcm>
Allison Randal announced that Jonathan Worthington had written a draft
PDD for Parrot's bytecode format, which was checked in as
'[svn:parrot-pdd] r14784 - trunk/docs/pdds/clip <http://xrl.us/rzco>'.
Later some additional changes (based upon a conversation with Allison)
were also committed.
In 'Bytecode PDD <http://xrl.us/rzcq>' Jonathan asked for feedback.
Leopold Toetsch offered a few comments.
Ben Morrow wanted to know if pbc files could allow an optional `#!`
line so that they could be used as executables. Jonathan replied that
he had considered this, but rejected it because it is UNIX-specific.
There was additional discussion on the topic.
requirements gathering on mini transformation language
<http://xrl.us/rzcn>
Allison Randal asked for a volunteer to write up the requirements for
a mini transformation language to use the compiler tools. The job
would involve spending time with Allison and Patrick Michaud and
combining their ideas along with your own perspective. Adriano
Ferreira offered some opinions on the subject, and Markus Triska
volunteered to do it if it relates to his area of expertise.
[perl #40428] [PATCH] Return perl script and module file locations in
parrot distro <http://xrl.us/rzcr>
In ticket [perl #40428] <http://xrl.us/rzqm>, Paul Cochrane submitted
a patch to return the names and locations of the perl script and
module files within the Parrot distribution.
[perl #40429] [PATCH] test for perl code coda <http://xrl.us/rzcs>
Paul Cochrane supplied a patch in [perl #40429] <http://xrl.us/rzqn>
to add a test for the Perl code coda. Will Coleda rejected the patch
because he'd just added the same test as a Perl::Critic policy class.
[perl #40430] [PATCH] rename and update C code coda test
<http://xrl.us/rzct>
Paul Cochrane renamed the C coda test and removed Perl-specific code
from the test. It was applied as r14812. The ticket for this patch is
[perl #40430] <http://xrl.us/rzqo>.
Users
How to pass a ref from a language with no refs <http://xrl.us/rzcu>
This week the long-running CGI thread splintered in to the question of
how to pass a reference from a language with no references when Mark
Stosberg replied to a discussion on how Perl 5 embeds in Perl 6.
Mark saw some recent Pugs commits on Perl 5 embedding, which
encouraged him to experiment with passing hashes and arrays. In his
tests, he was able to send an array as an arrayref, but was unable to
get a hashref. He wondered if there was another way to do it.
Aristotle Pagaltzis replied.
Perl6 "style-guide" <http://xrl.us/rzcv>
Last week, Fagyal Csongor asked if someone was willing to write a Perl
6 style guide. This led to a discussion on other resources, desired
and existing. This week, Chris Dolan asked if anyone wanted to start a
port of Perl::Critic.
xx operator <http://xrl.us/rzcx>
Fagyal Csongor included some code which gave an unexpected result and
wondered if the code or Pugs was at fault. A. Pagaltzis replied that
the `xx` operator is list-repeat rather than string-repeat. Juerd also
explained further, and the code was fixed.
Acknowlegements
This summary was prepared using Mail::Summary::Tools
<http://xrl.us/rzcz>, now available on CPAN.
If you appreciate Perl, consider contributing to the Perl Foundation
<http://donate.perlfoundation.org> to help support the development of
Perl.
Jamie Cheetham supplied server access this week.
Thank you to everyone who has pointed out mistakes and offered
suggestions for improving this series. Comments on this summary can be
sent to Ann Barcomb, <[EMAIL PROTECTED]>.
Distribution
This summary can be found in the following places:
* use.perl.org <http://use.perl.org/>
* The Pugs blog <http://pugs.blogs.com/>
* The perl6-announce mailing list <http://xrl.us/rzc2>
* ONLamp <http://www.oreillynet.com/onlamp/blog/>
See Also
* Perl Foundation activities <http://blog.perlfoundation.org>
* Perl 6 Development <http://dev.perl.org/perl6>
* Planet Perl Six <http://planetsix.perl.org/perl6>