1--TEST--
2Test typed properties error condition (type mismatch)
3--FILE--
4<?php
5new class("PHP 7 is better than you, and it knows it ...") {
6    public int $int;
7
8    public function __construct(string $string) {
9        $this->int = $string;
10    }
11};
12?>
13--EXPECTF--
14Fatal error: Uncaught TypeError: Cannot assign string to property class@anonymous::$int of type int in %s:%d
15Stack trace:
16#0 %s(%d): class@anonymous->__construct('PHP 7 is better...')
17#1 {main}
18  thrown in %s on line %d
19