lisachenko / z-engine

:zap: PHP Engine Direct API
MIT License
448 stars 22 forks source link

Add automatic self-registration via Composer #21

Open lisachenko opened 4 years ago

lisachenko commented 4 years ago

Autoload can be used for automatic Core initialization, thus simplify usage of this library. Unfortunately, Composer doesn't support automatic preload right now, so only CLI mode can be used for auto-registration right now.

lisachenko commented 4 years ago

Preloading breaks all the things ( Because composer autoloader calls the Core::init() before preload initialization.

lisachenko commented 4 years ago

This issue is also affected by the bug https://bugs.php.net/bug.php?id=78918 which prevents code to be preloaded.