1--TEST-- 2ZE2 class type hinting non existing class 3--FILE-- 4<?php 5 6class Foo { 7 function a(NonExisting $foo) {} 8} 9 10$o = new Foo; 11$o->a($o); 12?> 13--EXPECTF-- 14Fatal error: Uncaught TypeError: Argument 1 passed to Foo::a() must be an instance of NonExisting, instance of Foo given, called in %s on line %d and defined in %s:%d 15Stack trace: 16#0 %s(%d): Foo->a(Object(Foo)) 17#1 {main} 18 thrown in %s on line %d 19