Open zabous opened 1 year ago
Is this the best way to solve this problem? Would it be better to modify the library to not use dynamic properties?
Are you sure that it is possible without changing usage?
- $server->inst = new MyHandler;
- $server->method1 = function(param1, param2,
PHP 8.2 introduces a new attribute in the global namespace named #[AllowDynamicProperties]. Classes declared with this attribute signals PHP to not emit any deprecation notices when setting dynamic properties on objects of that class.