#!/usr/bin/perl -w
# $Id: bench_twig_extract,v 1.2 2003/09/19 18:52:26 mrodrigu Exp $
use strict;
use simple_benchmark; # to get memory size
use XML::Twig;

use Getopt::Long;

my( $in_file);
GetOptions( 'in_file=s' =>\$in_file); 
$in_file ||= 'test.xml';

XML::Twig->new( twig_roots => { message => sub { print $_->text, "\n"; } })
         ->parsefile( $in_file);


