in reply to Thoughts on Perl6 - Love it? Hate it?

(Update: @seen{...} is now %seen{...}) So long as I can write %seen{@data} ^= 1 and @histogram[map /\d/, $n] ^++, I will be the happiest person alive. Those will be Perl idioms one will be hard-pressed to find in any other language. The hyper-operators are, I feel, long overdue, and should be received with much celebration. The loops required to mimic them in current versions of Perl will be optimized into the Perl core, which -- apart from sounding nifty -- is nifty.

Perl 6 is mainly about re-engineering our core processes and utilizing new paradigms for work efficiency and extending our empowerment to meet a wide spectrum of abilities.

Oh, sorry, I was reading "The Dilbert Principle". Where was I?

Perl 6 is about rethinking a lot that programmers want to do, but can't really, in Perl. The amount of "stuff" is measured by CPAN's growing number of Perl extension modules -- things like Switch and Attribute::Handlers and [insert favorite Damian module here].

But it's also about making the language more inviting to people from other backgrounds (which is a good reason to make the -> to . change) and to make a good enough impression that first-time callers become long-time supporters.

Anything I've found icky about Perl 6, I've taken with a grain of salt. Larry knows what he's doing, and one thing he's doing is listening to us. Another thing he's doing is milking the damned colon for all it's worth! STOP COLON EXPLOITATION NOW! But it will be for the best.

Jeff[japhy]Pinyan: Perl, regex, and perl hacker.
s++=END;++y(;-P)}y js++=;shajsj<++y(p-q)}?print:??;

Replies are listed 'Best First'.
Re^2: Thoughts on Perl6 - Love it? Hate it?
by Aristotle (Chancellor) on Jan 10, 2002 at 21:31 UTC

    That's pretty much the way I feel. When I read the Apocalypses (I read them both before reading either Exegesis), I must admit I was almost disgusted. The one thing I've grown so very fond of in Perl is the relation between %hash, @hash{@list} and $hash{$scalar}. My world broke down when I read that this is going away.

    But then, though I wasn't around then, I imagine that when people went from Perl 4 to Perl 5, they must have found themselves in an odd world too.

    That is what I think it's going to be like to move from Perl 5 to Perl 6. Perl 6 will have its own idioms. We will all have to change the way we think and get accustomed to them. For what price? Well - I doubt anyone would nowadays say things were better, back in Perl 4, without all the newfangled stuff.

    Perl 6 is going to have newfangled stuff as well - I predict that eventually we'll get used to it and will look down on Perl 5 as an inferior stepstone from the past, the same way we look down on Perl 4 now even if we remember it fondly.

    The hyper operators are one of the things I also am every excited about. Part of Perl I immediately fell in love with is map and grep. Now come to think about them - aren't they are basically "poor man's hyper operators"? And guess what - we will have dinner with silver cutlery in the future.

(Ovid) Re(2): Thoughts on Perl6 - Love it? Hate it?
by Ovid (Cardinal) on Jan 10, 2002 at 22:39 UTC

    Just out of curiosity, I know there's still a lot up in the air (err?), but won't this be a syntax error?

    @seen{@data} ^= 1;

    You have an @ to designate "seen" as an array (Perl6 terminology, folks!, I know that's not correct for Perl5), but you're using the curlies for a hash. I am assuming that what you meant to do was use a hash slice of elements in @data and set all elements to 1 (true). If so, I believe that would be:

    %seen{@data} ^= 1;

    For those not familiar with Perl 6 idioms, that would be the equivalent of the following in Perl 5:

    @seen{@data} = (1) x @data; # or foreach (@data) { $seen{ $_ } = 1; }


    Join the Perlmonks Setiathome Group or just click on the the link and check out our stats.

      Dammit. Old habits die hard. I'm going to get flooded with those error messages, I'm sure.

      Jeff[japhy]Pinyan: Perl, regex, and perl hacker.
      s++=END;++y(;-P)}y js++=;shajsj<++y(p-q)}?print:??;