<?php
class 🥃whisky
{
    public    
string     $name;
    private   
int        $age;
    public    
Distillery $distillery;
    private   ?
Bottler   $bottler;
}

$whisky = new 🥃whisky;
$whisky->distillery "Lagavullin";
?>

TypeError: Typed property 🥃whisky::$distillery must be an instance of Distillery, string used



Type validation is checked when writing