user-pic

Toby Inkster

  • 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?

  • Posted Type::Tiny Tricks #3: One-off Coercions to Toby Inkster

    Here's a quick way to create an attribute that coerces to an integer from any other number:

    ="k…
  • Commented on Type::Tiny Tricks #2: Types Are Objects
    This blog post is about Type::Tiny type constraint objects. In the Type::Tiny framework all types (Int, Str, ArrayRef, FileHandle, etc) are represented by objects. (Though that's not to say that values are.)...
  • Posted Type::Tiny Tricks #2: Types Are Objects to Toby Inkster

    When you use code like this:

    use
  • Commented on The 19th CPAN Day and the 1st
    Something I just noticed... One of those ten new CPAN contributors was Tim Vroom. Although this was his first CPAN contribution, he had previously created something else for the Perl community....
  • Posted Type::Tiny Tricks #1: Quick Intersections to Toby Inkster

    Type::Tiny objects overload the & (bitwise and) operator to build a type constraint intersection. For example:

  • Commented on CPAN Day winner?
    What that screen capture doesn't show is that for most of those distributions he didn't just make a single release. For example, Zilla-Dist-0.0.151 appears on your list because it's the latest release of Zilla-Dist, but INGY actually released Zilla-Dist-0.0.133 at...
  • Posted Type::Tiny 1.000000 Released to Toby Inkster

    It's been almost 17 months, and over 160 releases to get there, but Type-Tiny 1.000000 has been released on CPAN Day 2014.

  • Commented on Creating an MMORPG in Perl
    "Nobody doubts my coding ability, but creating a compelling game? That's a different story entirely" I played Unknown::Values a bit last year, but didn't find it to be a very immersive experience....
  • Commented on Acknowledge your contributors on CPAN Day
    Also, if you have a file called "CREDITS", "AUTHORS", or "THANKS" in your release's root directory, MetaCPAN will consider this to be an a href="https://github.com/CPAN-API/metacpan-web/blob/master/lib/MetaCPAN/Web/Model/API/Release.pm#L320">interesting file and display it on your release page (under the "Other Files" heading). search.cpan.org also...
  • Commented on Don't be afraid to rename your module / dist
    Yes, posting a comment from the "Preview" page is broken. The workaround is to preview, then hit back, (if necessary, edit it some more, preview again, and go back again... until you are satisfied with your comment), and then post...
  • Posted Planet Moose - July 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 Method Privacy in Perl
    That only partly solves the problem. It prevents subclasses from overriding the method when called from inside my class. It doesn't solve the wider problem of making it clear which methods are suitable for subclasses to call/override, and which methods...
  • Commented on Method Privacy in Perl
    There are perfectly valid reasons to have private methods. Say, for example, you have two different public methods that have a lot of code in common. Maybe a print_delivery_address_label() method and a print_billing_address_label() method. The common code could be factored...
  • Commented on Give your module a good SEE ALSO section
    I rarely write a DEPENDENCIES section, but I did for Type::Tiny, and it's more than just a duplication of the right-hand column on metacpan....
  • Posted Method Privacy in Perl to Toby Inkster

    This is a slightly expanded version of a comment I posted a couple of days ago on NEILB's blog.

  • Commented on Give your modules a good SYNOPSIS
    Add this to your pod, just before the SYNOPSIS code: =for test_synopsis use v5.14;...
  • Commented on Let's top git.io
    Yes, I've seen this list before. Although I'm nowhere near as active as kentfredric, I'm more active than a lot of the people on the list. For now, I'll follow kentfredric as my contribution to gaming this list, but it...
  • Commented on How to create an installable web application with config/data/bin stuff?
    Different Linux/Unix flavours keep their files in different places. I'd recommend installing stuff in the standard CPAN places, and rely on people packaging your application for specific distributions (Fedora, Debian, etc) to patch it to put everything in the right...
  • Posted Meta-Meta-Meta Problem Solving to Toby Inkster

    I happen to maintain the dependency, so better to fix it at source. Done. Let's set up Travis testing for this dependency too...

    Oh no, bui…

  • Posted Because Sometimes Lightspeed is Too Slow to Toby Inkster
    Spaceballs: Lightspeed is too slow. We'll have to go right to ludicrous speed.
  • Posted Planet Moose - June 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 Grants Committee 2014 first half
    You mean like this one?...
  • Commented on XS, Enough Said
    There might not be many great XS tutorials, but there's an #xs channel on the Perl IRC server, and I've found it a very helpful resource....
  • Commented on Enter MooseX, Appendix II Last One I Promiss!
    "However I do see that my compatibility Matrix isn't that broad covering only two OSs." Give it time. There are a few dedicated testers who submit results for Linux, Windows, and often FreeBSD within a few minutes of releasing your...
  • Commented on "Functional core & Imperative shell" : OO design, and isolated tests without mocks
    One class can happily pass a Point3D object to a second class. The second class can happily call the Point3D accessors and methods. However, the second class can't (easily) construct objects using the same Point3D definition from the first class....
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.