|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
[2017-03-22 19:38 UTC] yukiwongky at gmail dot com
Description: ------------ This only happens in Mac (I've tested it on Sierra and Al Capital, but I'm not sure if older Mac OS versions have this problem. But Windows and Linux (Ubuntu and CentOS) don't seem to have this problem. I have two extensions and they have a few common function names. When I use these extensions in Windows or Linux, the order in which I put them in php.ini doesn't matter. However, when I use the extensions on Mac, the function that is in the first loaded extension is always called. For example, I have extension A and B. When I'm using API's from B, I would expect the function in B to be called. However, if I loaded A before B in php.ini, the function of the same name in A is called. For now I have managed to have a workaround for it by changing the function names / putting them into their own namespace. However, I am concerned that what if some other extension that's not created by me also have the same function names as the ones in my extensions and some user load that extension before mine. Expected result: ---------------- I expect to see the order of which I load the extensions do not affect which function of the common name is called. Actual result: -------------- The function of the extension that is loaded first is executed. PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Tue Oct 28 14:00:01 2025 UTC |
The examples I found in the sqlsrv and pdo_sqlsrv extensions are: sqlsrv_error_const* get_error_message(unsigned int sqlsrv_error_code); struct stmt_option_ss_scrollable : public stmt_option_functor { virtual void operator()( sqlsrv_stmt* stmt, stmt_option const* /*opt*/, zval* value_z TSRMLS_DC ); };