in reply to Segfault with JavaScript in Debian

Greetings all,
Segfault usually indicated attempting to access space in memory that has not been allocated, like in C calling array elements beyond the bounds initially set...
With that in mind I would focus attention on the
methods=>{ bar=>\&Foo::bar, baz=>\&Foo::baz }

portion of your code since from your posting I do not see those subs in your Foo package.
Of course this could be a deeper issue that inheres in the module itself, can't really say for sure.
Just a thought,

-InjunJoel

"I do not feel obliged to believe that the same God who endowed us with sense, reason and intellect has intended us to forego their use." -Galileo