user-pic

Aristotle

  • Commented on Subject Verb Object notation; declarative Perl without the framework
    But you haven’t shown any benefit of the language feature. The code examples you showed could just as well be written like this, and would mean and do the exact same thing: try { Location::is_in( $character, $location ); Wallet::contains( $character,...
  • Commented on Subject Verb Object notation; declarative Perl without the framework
    If Location isn’t inheriting from anything then these are just functions masquerading as methods, obscured by the use of a special case of the arrow operator. Not sure what the big revelation is.If ECS is the actual revelation here, then...
  • Commented on I failed to pause before blogging
    It seems to me that PAUSE could check for a semicolon, but there are probably exceptions for that.Indeed there are.$ perldoc -f package | head -4 package NAMESPACE package NAMESPACE VERSION package NAMESPACE BLOCK package NAMESPACE VERSION BLOCK...
  • Commented on An easy way to use WebSockets?
    If you only need client-side server event notifications, a less complex alternative than WebSockets might be server-sent events....
  • Commented on Alles in Ordnung
    You’re looking for the code in pp_sort, aren’t you? After all, you want to offer basically the same interface as Perl’s sort. That suggests to go looking at its implementation. Looking at pp_sort itself, a lot of it isn’t implemented...
  • Commented on Where do you like bugs reported?
    You can get overviews of your issues across repositories on GitHub too. I’ve written about the ones I use. Of course queries at GitHub are relatively blunt as the available metadata isn’t nearly as rich as in RT. You can...
  • Commented on Narrowly destricted refs
    I’m afraid you are just being taken for a ride by the peephole optimiser: $ perl -l $_ = "boo"; sub x : lvalue { do { $_ } } x = "yay"; print yay $ perl -l $_ =...
  • Commented on Narrowly destricted refs
    For that example in isolation, I agree, that would be the cherry on top. It falls apart in the push example though. And if you have both cases in close proximity, I’d rather preserve symmetry than simplify just one of...
  • Posted Narrowly destricted refs to Aristotle
    *{; no strict 'refs'; \*{ "${pkg}::type" } } = sub () { $type };
    # ... and so on

    I really don’t feel like I have anything to add but I suppose it may not be obvious that the point of this …

  • Commented on My Y2020 Bug
    Thank you very much for Modern functions in a post-modern language. You provided the impetus to write it. 🙂 There had been other discussions about the new functions, but the conversation in this comment thread is what pushed me to...
  • Commented on My Y2020 Bug
    Isn’t Time::Piece->strptime( '1970-01-01', '%Y-%m-%d' ) far more defensive in that sense than either timegm( 0, 0, 0, 1, 0, 1970 ) or timegm_modern( 0, 0, 0, 1, 0, 1970 )?(Isn’t it great that that says … 1, 0, 1970 rather...
  • Posted Modern functions in a post-modern language to Aristotle

    The new _modern function variants in Time::Local have come up a few times lately. I have some thoughts on them, but presenting my position dispassionately enough to…

  • Commented on My Y2020 Bug
    Is that in fact a better response? It comes at the cost of an additional dependency that old perls will have to install from CPAN, and every dependency installed from CPAN has the potential to come at the cost of...
  • Commented on A Static Archive of use.perl.org
    Excellent! The icing on the cake would be if the redirect mapping also included the later static(ish?)-site URL structure: Old: http://use.perl.org/use.perl.org/_Aristotle/journal/33448.html New: https://use-perl.github.io/user/Aristotle/journal/33448/ It would be ideal if the redirector’s 404 logs were accessible, to be able to see if...
  • Commented on A Static Archive of use.perl.org
    I’d prefer not pointing use.perl.org directly at this mirror due to the difference in URL structure. But it would be nice to point the domain at a redirector that 301s old URLs to the URLs on this new mirror, the...
  • Commented on Can't post a comment here -- dunno why
    Previewing doesn’t kill the session. It’s just that the submit action on the preview page somehow fails to find or load the session correctly. But with the form on the article page, submitting works. So all you need to do...
  • Commented on Larry has approved renaming Perl 6 to raku
    These assume that a major release is the time when perhaps we can break backwards-compatability. Et tu, Ovid? Whyyyyy does everyone keep saying that, why? The whole point of Perl 6 was to be where compatibility would be broken. Not...
  • Commented on Signatures vs. Methods
    If you have any interest in interoperating with Perl code written before this new syntax then none of this arity-based dispatch is even on the table. How is this going to be reflected in the package stash? With an arity-mangled...
  • Commented on Why Perl 5 benefits is never talked in Perl Weekly Challenge?
    No need to be sorry. As you’re finding out, blogs.perl.org is not a venue where it’s terribly effective to ask a question like this. But it’s absolutely an appropriate venue to ask it. (On Twitter it may or may not...
  • Commented on Reusing data with YAML Anchors, Aliases and Merge Keys
    I’m not yet sure that the implementation will be trivial Yes, I only meant trivial in the sense that you don’t have to resort to any trickery or low-level wizardry or XS or anything like that to create aliases of...
  • Commented on Reusing data with YAML Anchors, Aliases and Merge Keys
    On newer Perls with refaliasing, it should be trivial to implement scalar aliases. YAML::PP could use that. On older Perls, Perl-based but non-pure-Perl YAML implementations can use Array::RefElem as a lightweight form of the refaliasing feature. Its drawback compared to...
  • Commented on TIL - Object Method: Named Arguments Unpacking
    For a couple of years now I’ve been writing the opening line of my methods as my ( $self, ... ) = ( shift, @_ ); Of course an %args slots right in there. The point to this two-fold. First...
  • Commented on Perl Weekly Challenge: Week 2
    And yes, the contents of the post is repeated twice, but I don't know what to do about it: in the edit window, it appears only once. An article consists of the content of the BODY tab followed by the...
  • Commented on Perl Weekly Challenge: Week 2
    Maybe it's been copied into both BODY and EXTENDED tabs? That’s exactly what happened....
  • Commented on Perl Weekly Challenge: Week 2
    You can use perl -pe '$_+=0' for the leading zeroes in Perl 5 too....
  • Commented on Perl Dependency Checking
    The dependency metadata in a CPAN distribution is independent from the code that actually loads the needed modules at runtime, so the two can diverge, and occasionally they do. But it gets noticed quite quickly, most of the time –...
  • Commented on What's going on here?
    If it were taking `@_[0,1]` as a scalar parameter, it would be printing out `2`. Incorrect. Replace sprintf with scalar and you will see that the result is exactly the same as you see here. That’s because @_[0,1] is a...
  • Commented on The Exception That Rather Proves the Rule
    If you absolutely cannot maintain your scripts (ie want them to live forever unmaintained) It’s not that I can. It goes back to the question you posed: “what does [maintaining such a script to keep it running] gain for the...
  • Commented on The Exception That Rather Proves the Rule
    If you have some argument for why the presented code is preferable to other frameworks, I’m all ears. It’s the one you won’t want to hear. I have some Plack CGI scripts on a machine where I do not have...
  • Commented on The Exception That Rather Proves the Rule
    Hmm. How much of a role does Plack play in that app? It parses the request parameters. That’s it. That’s the entirety of the reason that their codebase doesn’t qualify as raw PSGI. They don’t even use Plack::Response (I often...
Subscribe to feed Recent Actions from Aristotle

Subscribe to feed Responses to Comments from Aristotle

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.