diff --git a/hphp/runtime/vm/bytecode.cpp b/hphp/runtime/vm/bytecode.cpp index 0fb708003..c95fa46eb 100644 --- a/hphp/runtime/vm/bytecode.cpp +++ b/hphp/runtime/vm/bytecode.cpp @@ -7186,7 +7186,8 @@ void VMExecutionContext::recordCodeCoverage(PC pc) { Unit* unit = getFP()->m_func->unit(); assert(unit != nullptr); if (unit == SystemLib::s_nativeFuncUnit || - unit == SystemLib::s_nativeClassUnit) { + unit == SystemLib::s_nativeClassUnit || + unit == SystemLib::s_hhas_unit) { return; } int line = unit->getLineNumber(pcOff()); diff --git a/hphp/test/slow/code_coverage/hhas_coverage.php b/hphp/test/slow/code_coverage/hhas_coverage.php new file mode 100644 index 000000000..5fe592910 --- /dev/null +++ b/hphp/test/slow/code_coverage/hhas_coverage.php @@ -0,0 +1,9 @@ + + int(1) + [1]=> + int(2) + [2]=> + int(3) +}