xref: /php-src/tests/classes/class_final.phpt (revision 663536d7)
1--TEST--
2ZE2 A final class cannot be inherited
3--FILE--
4<?php
5
6final class base {
7    function show() {
8        echo "base\n";
9    }
10}
11
12$t = new base();
13
14class derived extends base {
15}
16
17echo "Done\n"; // shouldn't be displayed
18?>
19--EXPECTF--
20Fatal error: Class derived cannot extend final class base in %s on line %d
21