Skip to content

Instantly share code, notes, and snippets.

@kyanny
Created January 29, 2009 06:16
Show Gist options
  • Save kyanny/54408 to your computer and use it in GitHub Desktop.
Save kyanny/54408 to your computer and use it in GitHub Desktop.
#!/usr/local/bin/perl
use strict;
use Devel::Size qw(size);
use Perl6::Say;
use URI;
use URI::Query;
my $url = 'http://nttdocomosucks.example.com/path?too=many&query=string';
my $uri = URI->new($url);
my $size = size($uri);
say $size;
my $qq = URI::Query->new($uri->query);
$size = size($qq);
say $size;
my $qq2 = URI::Query->new('too=many&query=string');
$size = size($qq2);
say $size;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment