1--TEST--
2Test typed properties unset __get magical magic
3--FILE--
4<?php
5class Foo {
6	public int $bar;
7
8	public function __get($name) {
9		return "violate";
10	}
11}
12
13$foo = new Foo;
14
15$foo->bar = "1"; # ok
16
17unset($foo->bar); # ok
18
19var_dump($foo->bar); # not okay, __get is nasty
20?>
21--EXPECTF--
22Fatal error: Uncaught TypeError: Typed property Foo::$bar must be int, string used in %s:16
23Stack trace:
24#0 {main}
25  thrown in %s on line 16
26