[php-src] Issue #20974: Request to add support for `Trait` in the extension layer

[email protected] (matyhtf)
Newsgroups php.bugs
Message-ID <hhQjAj5WNcf6Yvg39hwTT9IxEOEz9YL8X7rw6eD8zC8@main.internal.php.net>
Issue: https://github.com/php/php-src/issues/20974
Author: matyhtf

### Description

Request to add a new ZendAPI: `zend_class_use_traits` that will allow internals classes in the extension to use Traits.

```c
static zend_class_entry *register_class_TestClass(zend_class_entry *class_entry_TestClassInterface) {
	zend_class_entry ce, *class_entry;

	INIT_CLASS_ENTRY(ce, "TestClass", class_TestClass_methods);
	class_entry = zend_register_internal_class_ex(&ce, NULL);

	zend_class_use_traits(class_entry, 2, class_entry_TraitA, class_entry_TraitB);
}
```
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.