Filter-Macro reviews

cpanratings
 

RSS | Module Info | Add a review of Filter-Macro

Filter-Macro (0.11) *****

I took a look at the source code for this module, and it's not really the type of thing most of us would want to have to troubleshoot ourselves. (Think 10 lines of Audrey Tang code).

That being said, it works as advertised.

I have a directory full of about 40 test files and wanted to eliminate a bunch of the code at the top of each one. Think:

use strict;
use warnings;
use Test::More;
use Test::Exception;
use Perl6::Say;
use JSON;
etc...

I also have a piece which does a bit of filename munching to automatically figure out which module the test should be testing. I stuck this in the macro too.

Since the files I tried this on were test files, it was trivial to see if the Filter::Macro module worked correctly, which it did. Not every test file needed every one of the modules included by the macro, but since they're tests they don't affect the performance of the real application, so this seemed like a good use of the Filter::Macro module.

Yes, Filter::Macro is a source filter, but it uses Filter::Simple::Compile, which does apparently awesome things which are, unfortunately, beyond my comprehension.

--Gordon McCreight

1 hidden unhelpful review