revert HHVM changes
general cleanup, retro-porting to PHP 5.3