1--TEST-- 2Bug #76869 (Incorrect bypassing protected method accessibilty check) 3--FILE-- 4<?php 5class A { 6 private function f() { 7 return "A"; 8 } 9} 10class B extends A { 11 protected function f() { 12 return "B"; 13 } 14} 15$b = new B(); 16try { 17 var_dump($b->f()); 18} catch (Throwable $e) { 19 echo "Exception: ", $e->getMessage(), "\n"; 20} 21?> 22--EXPECT-- 23Exception: Call to protected method B::f() from context '' 24