HHVM 4.155 is released! This release marks the end of support of 4.148; 4.149 - 4.154 remain supported, as does the 4.128 LTS release.

Highlights

  • Added HHVM_COMPILER_TIMESTAMP constant to hhi for type checker, which contains the timestamp to build hhvm.
  • Added narrower or pure capability declarations to the following builtin APIs:
    • create_opaque_value and unwrap_opaque_value
    • HH\Lib\Math\to_base
    • hash_*
  • Permitted generic methods to override their own instantiations. e.g. function foo(int):int in a super class can be overridden as function foo<T>(T):T in a subclass.
  • Allowed multiple --single options in hh_client invocations.
  • Added a quickfix for missing awaitable type.
  • Added hover docs for type aliases and contexts.
  • Correctly handle negative and large integers passed to array_fill (See CVE-2022-27809).

Breaking Changes

  • Enum class label expressions now requires defaults capability.
  • Fixed an unsoundness allowing arithmetic expressions to be typed as int when one of the operands is an unsolved type.
  • Moved all PERDIR ini settings to be SYSTEM settings.
  • Deleted the runtime option Eval.EnableZendIniCompat.
  • Removed the following options from HPHPc:
    • --force
    • --gen-stats
    • --sync-dir
    • --target
    • --program
    • --args
    • --include-path
    • --branch
    • --revision
    • --config-dir
  • HPHPc now requires a --output-dir argument:
  • Fixed an unsoundness due to type parameter name clash. e.g. given interface A<T> { function f<T1>(T $a): T1; }, if A is implemented in a class introducing type parameter name clash as class B<T1> extends A<T1> { function f<T1>(T1 $a): T1 { return $a; } }, when upcasting B to A, /*A<int>*/ $a = new B<int>();, it would allow for arbitrary type convention like Str\length($a->f(1));.