Allow properties to be defined on interface

From: Date: Thu, 28 Mar 2024 15:03:11 +0000
Subject: Allow properties to be defined on interface
Groups: php.internals 
Request: Send a blank email to internals+get-122792@lists.php.net to get a copy of this message
Hi internals, With read-only properties, we no longer need to define getter methods when we can take advantage of them. However, there is still one problem here from a convenience standpoint. That is if we use an interface, we still need to define a getter method. This was mentioned by @sakurairo in X Therefore, I propose to allow public properties to be defined on the interface (It does not matter whether it is read-only or not). I would like to hear your feedback. Also, if a similar discussion has taken place before, I would appreciate it if you could let me know. Regards. Saki

« previous php.internals (#122792) next »