As far as I can see, the three biggest changes in existing syntax are:

  1. Sigils don't change on different access (%foo[1])
  2. Arrow is replaced by dot, concatenation is done by underscore
  3. For's topic's location changes (for @foos -> $foo) and C-style loops are done with loop
So how will converting scripts go?
  1. Because the sigils don't change, $foo[1] will unambiguously mean $foo.[1] (Perl 5: $foo->[1]). That means that converting existing scripts will be easiest when you simply replace %foo by $foo, instead of the other way around. If I understand correctly, context will force $foo into being a hash reference.
  2. First, replace all dots by underscores, adding whitespace if it's not already there. (You may want to rething your design anyway. Perhaps the stringifying unary underscore can help you out: _($foo, $bar, $baz).) Then, simply substitute arrows for dots - or remove them, if you're not calling an object method, because $ref->{foo} will be $ref.{foo} which can be shortened to $ref{foo} (which is element 'foo' of hash %$ref, not hash %ref!)
  3. Then, find all for and foreach loops, and change them
That'll be quite a hassle... BUT... There will be a Perl5-to-Perl6 conversion script, so I don't think it'll be a problem. I think the general conversion process will be:
  1. Backup
  2. Automatically convert
  3. Try
  4. Fix
  5. Try again
And then, you can enjoy Perl 6's new features. I think converting existing scripts is a small price to pay for the great improvements this new language will have. Yes, I do consider Perl 6 to be a new language - it's not (Perl 5)++, it's Perl 6.

Besides, Perl 5 will be around for a long time. This WILL be like the 4-to-5 transition: it'll take at least two years before the general Perl public is used to Perl 6 and has enough trust in it to actually start using it. We now ask ourselves how we have managed without references. We will ask ourselves how we have managed without hyper-operators (^+), the default-operator (//, err) and given/when blocks.

U28geW91IGNhbiBhbGwgcm90MTMgY
W5kIHBhY2soKS4gQnV0IGRvIHlvdS
ByZWNvZ25pc2UgQmFzZTY0IHdoZW4
geW91IHNlZSBpdD8gIC0tIEp1ZXJk


In reply to Re: With Fear and Wonder by Juerd
in thread With Fear and Wonder by impossiblerobot

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.