More HHVM compatibility fixes