user-pic

Toby Inkster

  • Posted Object::Util to Toby Inkster

    I've recently released a new module called Object::Util to CPAN. This is a set of handy methods for working with classes and objects in Perl. It is inspired by

  • Commented on Install XML::LibXML without root
    The gist of how to patch XML::LibXML's Makefile.PL can be found in this ticket....
  • Commented on Install XML::LibXML without root
    A while back I created Alien::LibXML that installs a copy of libxml2 into one of your @INC paths. If you can install Perl modules, you can install it. Submitting a patch to XML::LibXML's Makefile.PL to check for Alien::LibXML has been...
  • Commented on Some new MetaCPAN features
    I really like the new version of the dashboard. Some suggestions: The bug counts could be a link to the issue tracker. Rather than using an "X" is those three centre columns, maybe use "R", "L", and "A". This is...
  • Commented on How does <email>@cpan.org work?
    The potential problem with them forwarding all mail unflitered to your primary e-mail address so that you can filter it, is that if you're filtering it yourself, you've lost out on one of the best ways to filter spam: originating...
  • Commented on Single-page POD for a distribution
    All versions of Opera prior to version 15 can do split screen....
  • Commented on Link to public version control system (GitHub or otherwise)
    A big improvement!...
  • Commented on Data::Dumper Debugging
    Yowch! Anyway, the first thing I do on any new Unixy box is: chsh -s `which tcsh` `whoami`...
  • Commented on I hate unpacking sub calls with shift
    Generally speaking I use shift for the invocant of method calls, or arguments I consider to be especially privileged. (If those arguments happened to be at the end of @_, I'd use pop, but that's not often the case.) Other...
  • Commented on Urging users with good test suites to test-drive latest DBIx::Class trial
    You have no access because people have been worried about what might happen if you find a way to harness the power of The Dark(pan) Side....
  • Commented on Quacks who write software make us all look bad
    It is possible that Dr Mato Nagel is a polymath and has doctorates in both medicine and sociology, though in this case I think your explanation is more likely....
  • Commented on Data::Dumper Debugging
    I don't know why bash users still reach for 2>&1 to pipe STDERR. Since version 4 (released five years ago), bash has supported a much simpler syntax borrowed from C shell and Korn shell: command1 |& command2 This combines STDOUT...
  • Commented on Data::Dumper Debugging
    Data::Dump doesn't have an equivalent of local $Data::Dumper::Deparse = 1;. And the $VAR1 = crud in Data::Dumper can be suppressed using local $Data::Dumper::Terse = 1;. Overall, Data::Dump does a better job with whitespace though....
  • Commented on Data::Dumper Debugging
    Perl warnings go to STDERR anyway, so I'm already in the habit of: perl whatever.pl |& less...
  • Posted Planet Moose - August 2014 to Toby Inkster

    Welcome to Planet Moose, a brief write up on what's been happening in the world of Moose in the past month, for the…

  • Commented on Data::Dumper Debugging
    Yes, I like Carp::Reply. It only kicks in when you reach an exception though. I like the idea of dropping into a REPL, poking around, exiting the REPL and resuming execution from there. Useful if you want to, say, poke...
  • Commented on Single-page POD for a distribution
    With multiple pages, you can open them in different browser tabs, or different terminals, and flick back and forth between them pretty easily. I'd actually expect the documentation to be harder to read if you were having to scroll up...
  • Commented on Data::Dumper Debugging
    Data::Printer produces nice output, and I used to use it quite a lot. I got frustrated by a couple of things though. For objects it shows a list of methods they have - awesome, right? However, it fails to show...
  • Commented on Rewriting Pod::Readme
    I've always taken the readme-from-pod route (which many people seem to do), but have recently been thinking that duplicating the information from the pod as a README file is fairly pointless. Instead a smaller README file containing the distribution's abstract,...
  • Posted Data::Dumper Debugging to Toby Inkster

    I've never really used the Perl debugger much (maybe I should learn?) and usually resort to lots of use Data::Dumper; print Dumper($somevar); statements to help me understand what's going wrong with a piece of code.

  • Commented on Link to public version control system (GitHub or otherwise)
    META.json allows two main fields for the repository - a URI for a web link, and also a VCS-specific string which often looks something like a URI. (There's a third field for the repo type - "git", "svn", "hg", etc.)...
  • Commented on Link to public version control system (GitHub or otherwise)
    The reason for the dramatic improvement you see may be a "CPAN Day" blip. Looking at the last 2000 uploads (as of now), 16% of them were uploaded by just one person - a person who happens to be quite...
  • Commented on Link to public version control system (GitHub or otherwise)
    The MetaCPAN dashboard thingy is buggy though. Mine shows dozens of distributions that it claims have no link to version control. An example is LV. This quite clearly includes a version control link in META.json and META.yml, which is clearly...
  • Commented on Introducing IOD file format
    It doesn't seem quite the same. In a traditional INI file: [section] foo=1 bar=2 bar=3 "bar" is an array, but is "foo" a simple string, or is it an array with just one element? The INI parser will probably treat...
  • Commented on Type::Tiny 1.000000 Released
    Ivan, have you read Type::Tiny::Manual::Libraries? That's probably the best starting point for creating a type library....
  • Commented on Please don't use ::Tiny unless it meets the ::Tiny criteria, thanks!
    Answering for Type::Tiny, although the distribution which it is part of is certainly not as tiny as it started out as, the Type::Tiny module itself is still pretty lean. The module itself has no non-core dependencies, and I've even tried...
  • Posted Type::Tiny Tricks #7: Tricks with Dicts to Toby Inkster

    In Perl, hashes are typically used for two sorts of purposes: maps (where the hash key acts as an object identifier) and dictionaries (where the hash key acts like a field name). A quick illustration of what I mean by this:

  • Posted Type::Tiny Tricks #6: Tricks with Tuples to Toby Inkster

    Let's say you want an attribute to accept a pair of numbers - perhaps a geographic co-ordinates [ 50.873, -0.002 ]. You could constrain the attribute as ArrayRef[Num], but that would accept an arrayref containing a single…

  • Posted Type::Tiny Tricks #5: Wrapping Moose/Mouse Type Constraints to Toby Inkster

    So you have this Moo class, and it turns out what you really need for it is the StrictVersionStr type constraint defined in…

  • Posted Type::Tiny Tricks #4: Inlined Type Constraints to Toby Inkster

    If ever you're unsure of how a type constraint has been defined, you can examine the string of Perl code used to implement it. For example, does an ArrayRef[Int] accept an empty arrayref?

Subscribe to feed Recent Actions from Toby Inkster

Subscribe to feed Responses to Comments from Toby Inkster

About blogs.perl.org

blogs.perl.org is a common blogging platform for the Perl community. Written in Perl and offering the modern features you’ve come to expect in blog platforms, the site is run by Dave Cross and Aaron Crane, with a design donated by Six Apart, Ltd.