{"author_name":"gfx","provider_url":"https://hatena.blog","blog_url":"https://gfx.hatenadiary.org/","width":"100%","url":"https://gfx.hatenadiary.org/entry/20090329/1238306848","image_url":null,"categories":["Perl","APVM"],"type":"rich","provider_name":"Hatena Blog","title":"Pure Perl\u306b\u3088\u308bPerl5 Virtual Machine\u306e\u5b9f\u88c5","published":"2009-03-29 15:07:28","author_url":"https://blog.hatena.ne.jp/gfx/","version":"1.0","blog_title":"Islands in the byte stream (legacy)","description":"Perl VM\u306e\u6c17\u6301\u3061\u3092\u77e5\u308b\u306b\u306f\u3001PurePerl\u3067\u5b9f\u88c5\u3057\u3066\u307f\u308b\u3068\u3088\u3044\u3002\u30b3\u30fc\u30c9\u4f8b\uff08PerlVM.pm\u306e\u30b3\u30fc\u30c9\u306f\u8a18\u4e8b\u306e\u672b\u5c3e\u306b\u3042\u308b\uff09\uff1a #!perl -w use strict; use PerlVM; my $x = shift || 42; PerlVM::call_sv(sub{ print \"Hello,\", \" world!\", \"\\n\"; if($x){ print $x, \" is true\\n\"; } else{ print $x, \" is false\\n\"; } }); __END__ \u5b9f\u884c\u7d50\u679c\uff1a $ perl hello.pl Hello, world! 42 is true\u2026","html":"<iframe src=\"https://hatenablog-parts.com/embed?url=https%3A%2F%2Fgfx.hatenadiary.org%2Fentry%2F20090329%2F1238306848\" title=\"Pure Perl\u306b\u3088\u308bPerl5 Virtual Machine\u306e\u5b9f\u88c5 - Islands in the byte stream (legacy)\" class=\"embed-card embed-blogcard\" scrolling=\"no\" frameborder=\"0\" style=\"display: block; width: 100%; height: 190px; max-width: 500px; margin: 10px 0px;\"></iframe>","height":"190"}