user-pic

smls

  • Commented on Smartmatch in 5.27.7
    Maybe documenting some rationale for at least "whereso" would help It's probably inspired by the so function from Perl 6, which simply coerces its argument to Bool - like the not function but without the negation....
  • Commented on COMPLETION Report / Perl 6 IO TPF Grant
    Very nice!...
  • Commented on Converting glob patterns to regular expressions
    I wrote this once, for one of my own scripts: # Given a glob pattern, return a regex that has the following behavior when # matched against Cwd::realpath canolicalized path strings: # - matches successfully if and only if the...
  • Commented on Try rakudobrew and play with concurrency
    There are cases where Rakudo/MoarVM keeps up with Perl 5 at built-ins, or beats it handily. At built-ins. Check out the benchmarks and see for yourself. I only see 3 kinds of micro-benchmarks on that page where Perl 6 comes...
  • Commented on Data::Dumper Debugging
    @Toby Inkster You're right, Data::Printer has some quirks. The prototype thing is a trade-off; it allows p to treat an array variable with a single value differently than a scalar variable, and an array differently than a hash -- with...
  • Commented on Try rakudobrew and play with concurrency
    They're finally working on making Perl 6 fast. In some examples, it's actually an order of magnitude faster than Perl 5 To be fair, I think that's only the case for micro-benchmarks that compare Perl 6 built-in features with the...
  • Commented on Data::Dumper Debugging
    Nice, although I wouldn't write use Data::Dumper; print Dumper($somevar); in the first place, I'd write: use Data::Dump; dd $somevar; or: use Data::Printer; p $somevar; ...which are not only more convenient to type, but also produce much prettier output....
  • Commented on Perl and Me, Part 8: Endless Forms Most Beautiful and Most Wonderful
    I disagree about P5 smart-matching, I think it was rightfully deprecated (i.e. an example of "self-correcting progress" rather than "progress being blocked"). The implementation tried to overload a single operator with far too many meanings, many of which where not...
  • Commented on Marpa version of Perl6 Advent Calendar, Day 18
    "Perl6's definition: ... Marpa::R2's definitions: suit ~ [♥♦♣♠] ..." I'm pretty sure the Perl 6 grammar could *also* have used a single token (with a character class) for the suits. Afaik, separating alternations into multiple tokens connected to a proto...
  • Commented on Most common build-in functions or operators beginners should know about Perl
    Note that you need to add use Scalar::Util qw(looks_like_number); to the program before being able to call looks_like_number()...
  • Commented on A Tiny Code Quiz
    He argued that even experienced developers will often get this wrong. Many Perl programmers might not guess the correct answer when presented with this "quiz". However, I believe very few would accidentally write such code in practice while ignorant of...
  • Commented on Arrow Operator Shenanigans
    chaining may be easier to read than g(f(x)). FYI, Perl6 has sequencer operators for that: source() ==> filter() ==> sink() http://perlcabal.org/syn/S03.html...
  • Commented on Perl module ideas #5
    no joy; no such ...;...
  • Commented on Why you don't need File::Slurp…
    "For small files, it's actually significantly faster" Hm... Skimming over the code of File::Slurp, it seems to use the very same technique that you present here, in the case of small files. So rob.kinyon may be right, it might just...
Subscribe to feed Recent Actions from smls

Subscribe to feed Responses to Comments from smls

About blogs.perl.org

blogs.perl.org is a common blogging platform for the Perl community. Written in Perl with a graphic design donated by Six Apart, Ltd.