Skip to content

Instantly share code, notes, and snippets.

@rkitover
Created January 25, 2013 04:19
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save rkitover/4631704 to your computer and use it in GitHub Desktop.
Save rkitover/4631704 to your computer and use it in GitHub Desktop.
#!/usr/bin/env perl
{
package UNIVERSAL;
sub new {
my ($class) = @_;
eval "require $class;";
die $@ if $@;
goto $class->can('new');
}
}
package main;
print Mojo::JSON->new->encode({ foo => 'bar' }), "\n";
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment