Lonely Lion

Chris McAvoy likes kites

Perl Dispatch Tables

without comments

SCTHUMBZZZ.jpg” alt=”Higher-Order Perl: Transforming Programs with Programs” />

I started reading Higher Order Perl again this morning. I forgot how versatile Perl can be, and how easy it is to write poor code. Chapter one, on recursion and writing functions that allow for reentry, made me want to re-do two projects I recently finished at work. Sadly, I fell for the trap of using a big list of global variables in both projects. I really should have written them a bit more functionally. I guess it’s good though, as it gives me a potential target for future refactoring.

Chapter two, on dispatch tables, fired off a bunch of ideas for a future someday / maybe sort of project that I have on a back burner. I’m desperate to write a domain specific language for something. Dispatch tables, and HOP’s specific examples to illustrate them, fit into that idea pretty well.

So, all in all, in about 45 minutes of train reading, HOP proved to be a great read.

Written by Chris

September 22nd, 2005 at 4:39 pm

Posted in Perl

Switch to our mobile site