

Not a bug: phpversion('extension_name') returns false - johnx123-up
http://bugs.php.net/40582

======
johnx123-up
When phpinfo() can report correct version, this definitely looks like a big
bug--open for 5 years

~~~
vstm
Well I think it's not that easy. "phpinfo" does not gather the version
information from the extension it just tells the extension to return some
tabular data which is not "interpreted" by PHP. In contrast the "phpversion"
function reads the version-field from the modules "zend_module_entry" struct.

Now if you look at, for example, the bz2 extension:
<https://github.com/php/php-src/blob/master/ext/bz2/bz2.c> You see that
NO_VERSION_YET (NULL) is set in the version field of the struct (line 122).

You can grep for "NO_VERSION_YET" in the "ext"-directory and you'll see some
extensions without version information.

So the problem is in the extensions, and since the extensions deliberately
have no version information the behaviour is no bug.

