1--TEST-- 2Failure case for static variance: Replace static with self 3--FILE-- 4<?php 5 6class A { 7 public function test(): static {} 8} 9class B extends A { 10 public function test(): self {} 11} 12 13?> 14--EXPECTF-- 15Fatal error: Declaration of B::test(): B must be compatible with A::test(): static in %s on line %d 16