Skip to content

Commit

Permalink
Move semicolon into TSRMLS_CACHE_EXTERN/DEFINE
Browse files Browse the repository at this point in the history
Also re bug #71575.
  • Loading branch information
nikic committed Mar 3, 2016
1 parent c4b1888 commit 1ac1529
Show file tree
Hide file tree
Showing 62 changed files with 63 additions and 63 deletions.
4 changes: 2 additions & 2 deletions TSRM/TSRM.h
Original file line number Diff line number Diff line change
Expand Up @@ -170,8 +170,8 @@ TSRM_API void *tsrm_get_ls_cache(void);

#define TSRMG_STATIC(id, type, element) (TSRMG_BULK_STATIC(id, type)->element)
#define TSRMG_BULK_STATIC(id, type) ((type) (*((void ***) TSRMLS_CACHE))[TSRM_UNSHUFFLE_RSRC_ID(id)])
#define TSRMLS_CACHE_EXTERN() extern TSRM_TLS void *TSRMLS_CACHE
#define TSRMLS_CACHE_DEFINE() TSRM_TLS void *TSRMLS_CACHE = NULL
#define TSRMLS_CACHE_EXTERN() extern TSRM_TLS void *TSRMLS_CACHE;
#define TSRMLS_CACHE_DEFINE() TSRM_TLS void *TSRMLS_CACHE = NULL;
#if ZEND_DEBUG
#define TSRMLS_CACHE_UPDATE() TSRMLS_CACHE = tsrm_get_ls_cache()
#else
Expand Down
2 changes: 1 addition & 1 deletion TSRM/tsrm_win32.h
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ typedef struct {

#ifdef ZTS
# define TWG(v) TSRMG_STATIC(win32_globals_id, tsrm_win32_globals *, v)
TSRMLS_CACHE_EXTERN();
TSRMLS_CACHE_EXTERN()
#else
# define TWG(v) (win32_globals.v)
#endif
Expand Down
2 changes: 1 addition & 1 deletion Zend/zend.c
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,7 @@ static HashTable *global_class_table = NULL;
static HashTable *global_constants_table = NULL;
static HashTable *global_auto_globals_table = NULL;
static HashTable *global_persistent_list = NULL;
ZEND_TSRMLS_CACHE_DEFINE();
ZEND_TSRMLS_CACHE_DEFINE()
#endif

ZEND_API zend_utility_values zend_uv;
Expand Down
2 changes: 1 addition & 1 deletion Zend/zend.h
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@
#define ZEND_TSRMLS_CACHE
#endif

ZEND_TSRMLS_CACHE_EXTERN();
ZEND_TSRMLS_CACHE_EXTERN()

#ifdef HAVE_NORETURN
# ifdef ZEND_NORETURN_ALIAS
Expand Down
2 changes: 1 addition & 1 deletion ext/bcmath/bcmath.c
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,7 @@ zend_module_entry bcmath_module_entry = {

#ifdef COMPILE_DL_BCMATH
#ifdef ZTS
ZEND_TSRMLS_CACHE_DEFINE();
ZEND_TSRMLS_CACHE_DEFINE()
#endif
ZEND_GET_MODULE(bcmath)
#endif
Expand Down
2 changes: 1 addition & 1 deletion ext/bcmath/php_bcmath.h
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ ZEND_BEGIN_MODULE_GLOBALS(bcmath)
ZEND_END_MODULE_GLOBALS(bcmath)

#if defined(ZTS) && defined(COMPILE_DL_BCMATH)
ZEND_TSRMLS_CACHE_EXTERN();
ZEND_TSRMLS_CACHE_EXTERN()
#endif

ZEND_EXTERN_MODULE_GLOBALS(bcmath)
Expand Down
2 changes: 1 addition & 1 deletion ext/com_dotnet/com_extension.c
Original file line number Diff line number Diff line change
Expand Up @@ -255,7 +255,7 @@ zend_module_entry com_dotnet_module_entry = {

#ifdef COMPILE_DL_COM_DOTNET
#ifdef ZTS
ZEND_TSRMLS_CACHE_DEFINE();
ZEND_TSRMLS_CACHE_DEFINE()
#endif
ZEND_GET_MODULE(com_dotnet)
#endif
Expand Down
2 changes: 1 addition & 1 deletion ext/com_dotnet/php_com_dotnet.h
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ ZEND_BEGIN_MODULE_GLOBALS(com_dotnet)
ZEND_END_MODULE_GLOBALS(com_dotnet)

#if defined(ZTS) && defined(COMPILE_DL_COM_DOTNET)
ZEND_TSRMLS_CACHE_EXTERN();
ZEND_TSRMLS_CACHE_EXTERN()
#endif

extern ZEND_DECLARE_MODULE_GLOBALS(com_dotnet);
Expand Down
2 changes: 1 addition & 1 deletion ext/exif/exif.c
Original file line number Diff line number Diff line change
Expand Up @@ -155,7 +155,7 @@ ZEND_DECLARE_MODULE_GLOBALS(exif)
#define EXIF_G(v) ZEND_MODULE_GLOBALS_ACCESSOR(exif, v)

#if defined(ZTS) && defined(COMPILE_DL_EXIF)
ZEND_TSRMLS_CACHE_DEFINE();
ZEND_TSRMLS_CACHE_DEFINE()
#endif

/* {{{ PHP_INI
Expand Down
2 changes: 1 addition & 1 deletion ext/filter/filter.c
Original file line number Diff line number Diff line change
Expand Up @@ -152,7 +152,7 @@ zend_module_entry filter_module_entry = {

#ifdef COMPILE_DL_FILTER
#ifdef ZTS
ZEND_TSRMLS_CACHE_DEFINE();
ZEND_TSRMLS_CACHE_DEFINE()
#endif
ZEND_GET_MODULE(filter)
#endif
Expand Down
2 changes: 1 addition & 1 deletion ext/filter/php_filter.h
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ ZEND_BEGIN_MODULE_GLOBALS(filter)
ZEND_END_MODULE_GLOBALS(filter)

#if defined(COMPILE_DL_FILTER) && defined(ZTS)
ZEND_TSRMLS_CACHE_EXTERN();
ZEND_TSRMLS_CACHE_EXTERN()
#endif

#define IF_G(v) ZEND_MODULE_GLOBALS_ACCESSOR(filter, v)
Expand Down
2 changes: 1 addition & 1 deletion ext/gmp/gmp.c
Original file line number Diff line number Diff line change
Expand Up @@ -215,7 +215,7 @@ zend_module_entry gmp_module_entry = {

#ifdef COMPILE_DL_GMP
#ifdef ZTS
ZEND_TSRMLS_CACHE_DEFINE();
ZEND_TSRMLS_CACHE_DEFINE()
#endif
ZEND_GET_MODULE(gmp)
#endif
Expand Down
2 changes: 1 addition & 1 deletion ext/gmp/php_gmp.h
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ ZEND_END_MODULE_GLOBALS(gmp)
#define GMPG(v) ZEND_MODULE_GLOBALS_ACCESSOR(gmp, v)

#if defined(ZTS) && defined(COMPILE_DL_GMP)
ZEND_TSRMLS_CACHE_EXTERN();
ZEND_TSRMLS_CACHE_EXTERN()
#endif

#else
Expand Down
2 changes: 1 addition & 1 deletion ext/iconv/iconv.c
Original file line number Diff line number Diff line change
Expand Up @@ -165,7 +165,7 @@ zend_module_entry iconv_module_entry = {

#ifdef COMPILE_DL_ICONV
#ifdef ZTS
ZEND_TSRMLS_CACHE_DEFINE();
ZEND_TSRMLS_CACHE_DEFINE()
#endif
ZEND_GET_MODULE(iconv)
#endif
Expand Down
2 changes: 1 addition & 1 deletion ext/iconv/php_iconv.h
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ ZEND_END_MODULE_GLOBALS(iconv)
#define ICONVG(v) ZEND_MODULE_GLOBALS_ACCESSOR(iconv, v)

#if defined(ZTS) && defined(COMPILE_DL_ICONV)
ZEND_TSRMLS_CACHE_EXTERN();
ZEND_TSRMLS_CACHE_EXTERN()
#endif

#ifdef HAVE_IBM_ICONV
Expand Down
2 changes: 1 addition & 1 deletion ext/interbase/interbase.c
Original file line number Diff line number Diff line change
Expand Up @@ -461,7 +461,7 @@ zend_module_entry ibase_module_entry = {

#ifdef COMPILE_DL_INTERBASE
#ifdef ZTS
ZEND_TSRMLS_CACHE_DEFINE();
ZEND_TSRMLS_CACHE_DEFINE()
#endif
ZEND_GET_MODULE(ibase)
#endif
Expand Down
2 changes: 1 addition & 1 deletion ext/interbase/php_ibase_includes.h
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,7 @@ enum php_interbase_option {
#define IBG(v) ZEND_MODULE_GLOBALS_ACCESSOR(ibase, v)

#if defined(ZTS) && defined(COMPILE_DL_INTERBASE)
ZEND_TSRMLS_CACHE_EXTERN();
ZEND_TSRMLS_CACHE_EXTERN()
#endif

#define BLOB_ID_LEN 18
Expand Down
2 changes: 1 addition & 1 deletion ext/intl/php_intl.c
Original file line number Diff line number Diff line change
Expand Up @@ -892,7 +892,7 @@ zend_module_entry intl_module_entry = {

#ifdef COMPILE_DL_INTL
#ifdef ZTS
ZEND_TSRMLS_CACHE_DEFINE();
ZEND_TSRMLS_CACHE_DEFINE()
#endif
ZEND_GET_MODULE( intl )
#endif
Expand Down
2 changes: 1 addition & 1 deletion ext/intl/php_intl.h
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ ZEND_BEGIN_MODULE_GLOBALS(intl)
ZEND_END_MODULE_GLOBALS(intl)

#if defined(ZTS) && defined(COMPILE_DL_INTL)
ZEND_TSRMLS_CACHE_EXTERN();
ZEND_TSRMLS_CACHE_EXTERN()
#endif

ZEND_EXTERN_MODULE_GLOBALS(intl)
Expand Down
2 changes: 1 addition & 1 deletion ext/json/json.c
Original file line number Diff line number Diff line change
Expand Up @@ -175,7 +175,7 @@ zend_module_entry json_module_entry = {

#ifdef COMPILE_DL_JSON
#ifdef ZTS
ZEND_TSRMLS_CACHE_DEFINE();
ZEND_TSRMLS_CACHE_DEFINE()
#endif
ZEND_GET_MODULE(json)
#endif
Expand Down
2 changes: 1 addition & 1 deletion ext/json/php_json.h
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ PHP_JSON_API ZEND_EXTERN_MODULE_GLOBALS(json)
#define JSON_G(v) ZEND_MODULE_GLOBALS_ACCESSOR(json, v)

#if defined(ZTS) && defined(COMPILE_DL_JSON)
ZEND_TSRMLS_CACHE_EXTERN();
ZEND_TSRMLS_CACHE_EXTERN()
#endif

PHP_JSON_API void php_json_encode(smart_str *buf, zval *val, int options);
Expand Down
2 changes: 1 addition & 1 deletion ext/libxml/libxml.c
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ static zend_class_entry *libxmlerror_class_entry;
/* {{{ dynamically loadable module stuff */
#ifdef COMPILE_DL_LIBXML
#ifdef ZTS
ZEND_TSRMLS_CACHE_DEFINE();
ZEND_TSRMLS_CACHE_DEFINE()
#endif
ZEND_GET_MODULE(libxml)
#endif /* COMPILE_DL_LIBXML */
Expand Down
2 changes: 1 addition & 1 deletion ext/libxml/php_libxml.h
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@ PHP_LIBXML_API void php_libxml_shutdown(void);
#define LIBXML(v) ZEND_MODULE_GLOBALS_ACCESSOR(libxml, v)

#if defined(ZTS) && defined(COMPILE_DL_LIBXML)
ZEND_TSRMLS_CACHE_EXTERN();
ZEND_TSRMLS_CACHE_EXTERN()
#endif

#else /* HAVE_LIBXML */
Expand Down
2 changes: 1 addition & 1 deletion ext/mbstring/mbstring.c
Original file line number Diff line number Diff line change
Expand Up @@ -591,7 +591,7 @@ static sapi_post_entry php_post_entries[] = {

#ifdef COMPILE_DL_MBSTRING
#ifdef ZTS
ZEND_TSRMLS_CACHE_DEFINE();
ZEND_TSRMLS_CACHE_DEFINE()
#endif
ZEND_GET_MODULE(mbstring)
#endif
Expand Down
2 changes: 1 addition & 1 deletion ext/mbstring/mbstring.h
Original file line number Diff line number Diff line change
Expand Up @@ -205,7 +205,7 @@ struct mb_overload_def {
#define MBSTRG(v) ZEND_MODULE_GLOBALS_ACCESSOR(mbstring, v)

#if defined(ZTS) && defined(COMPILE_DL_MBSTRING)
ZEND_TSRMLS_CACHE_EXTERN();
ZEND_TSRMLS_CACHE_EXTERN()
#endif

#else /* HAVE_MBSTRING */
Expand Down
2 changes: 1 addition & 1 deletion ext/mcrypt/mcrypt.c
Original file line number Diff line number Diff line change
Expand Up @@ -273,7 +273,7 @@ zend_module_entry mcrypt_module_entry = {

#ifdef COMPILE_DL_MCRYPT
#ifdef ZTS
ZEND_TSRMLS_CACHE_DEFINE();
ZEND_TSRMLS_CACHE_DEFINE()
#endif
ZEND_GET_MODULE(mcrypt)
#endif
Expand Down
2 changes: 1 addition & 1 deletion ext/mysqli/mysqli.c
Original file line number Diff line number Diff line change
Expand Up @@ -1031,7 +1031,7 @@ zend_module_entry mysqli_module_entry = {

#ifdef COMPILE_DL_MYSQLI
#ifdef ZTS
ZEND_TSRMLS_CACHE_DEFINE();
ZEND_TSRMLS_CACHE_DEFINE()
#endif
ZEND_GET_MODULE(mysqli)
#endif
Expand Down
2 changes: 1 addition & 1 deletion ext/mysqli/php_mysqli_structs.h
Original file line number Diff line number Diff line change
Expand Up @@ -345,7 +345,7 @@ ZEND_END_MODULE_GLOBALS(mysqli)
#define MyG(v) ZEND_MODULE_GLOBALS_ACCESSOR(mysqli, v)

#if defined(ZTS) && defined(COMPILE_DL_MYSQLI)
ZEND_TSRMLS_CACHE_EXTERN();
ZEND_TSRMLS_CACHE_EXTERN()
#endif

#define my_estrdup(x) (x) ? estrdup(x) : NULL
Expand Down
2 changes: 1 addition & 1 deletion ext/mysqlnd/mysqlnd.h
Original file line number Diff line number Diff line change
Expand Up @@ -284,7 +284,7 @@ PHPAPI ZEND_EXTERN_MODULE_GLOBALS(mysqlnd)
#define MYSQLND_G(v) ZEND_MODULE_GLOBALS_ACCESSOR(mysqlnd, v)

#if defined(ZTS) && defined(COMPILE_DL_MYSQLND)
ZEND_TSRMLS_CACHE_EXTERN();
ZEND_TSRMLS_CACHE_EXTERN()
#endif


Expand Down
2 changes: 1 addition & 1 deletion ext/mysqlnd/php_mysqlnd.c
Original file line number Diff line number Diff line change
Expand Up @@ -361,7 +361,7 @@ zend_module_entry mysqlnd_module_entry = {
/* {{{ COMPILE_DL_MYSQLND */
#ifdef COMPILE_DL_MYSQLND
#ifdef ZTS
ZEND_TSRMLS_CACHE_DEFINE();
ZEND_TSRMLS_CACHE_DEFINE()
#endif
ZEND_GET_MODULE(mysqlnd)
#endif
Expand Down
2 changes: 1 addition & 1 deletion ext/odbc/php_odbc.c
Original file line number Diff line number Diff line change
Expand Up @@ -412,7 +412,7 @@ zend_module_entry odbc_module_entry = {

#ifdef COMPILE_DL_ODBC
#ifdef ZTS
ZEND_TSRMLS_CACHE_DEFINE();
ZEND_TSRMLS_CACHE_DEFINE()
#endif
ZEND_GET_MODULE(odbc)
#endif
Expand Down
2 changes: 1 addition & 1 deletion ext/odbc/php_odbc_includes.h
Original file line number Diff line number Diff line change
Expand Up @@ -308,7 +308,7 @@ PHP_ODBC_API ZEND_EXTERN_MODULE_GLOBALS(odbc)
#define ODBCG(v) ZEND_MODULE_GLOBALS_ACCESSOR(odbc, v)

#if defined(ZTS) && defined(COMPILE_DL_ODBC)
ZEND_TSRMLS_CACHE_EXTERN();
ZEND_TSRMLS_CACHE_EXTERN()
#endif

#endif /* HAVE_UODBC */
Expand Down
2 changes: 1 addition & 1 deletion ext/opcache/ZendAccelerator.c
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ zend_accel_globals accel_globals;
#else
int accel_globals_id;
#if defined(COMPILE_DL_OPCACHE)
ZEND_TSRMLS_CACHE_DEFINE();
ZEND_TSRMLS_CACHE_DEFINE()
#endif
#endif

Expand Down
2 changes: 1 addition & 1 deletion ext/opcache/ZendAccelerator.h
Original file line number Diff line number Diff line change
Expand Up @@ -308,7 +308,7 @@ extern zend_accel_shared_globals *accel_shared_globals;
# define ZCG(v) ZEND_TSRMG(accel_globals_id, zend_accel_globals *, v)
extern int accel_globals_id;
# ifdef COMPILE_DL_OPCACHE
ZEND_TSRMLS_CACHE_EXTERN();
ZEND_TSRMLS_CACHE_EXTERN()
# endif
#else
# define ZCG(v) (accel_globals.v)
Expand Down
2 changes: 1 addition & 1 deletion ext/pdo_mysql/pdo_mysql.c
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@

#ifdef COMPILE_DL_PDO_MYSQL
#ifdef ZTS
ZEND_TSRMLS_CACHE_DEFINE();
ZEND_TSRMLS_CACHE_DEFINE()
#endif
ZEND_GET_MODULE(pdo_mysql)
#endif
Expand Down
2 changes: 1 addition & 1 deletion ext/pdo_mysql/php_pdo_mysql_int.h
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ ZEND_EXTERN_MODULE_GLOBALS(pdo_mysql)
#define PDO_MYSQL_G(v) ZEND_MODULE_GLOBALS_ACCESSOR(pdo_mysql, v)

#if defined(ZTS) && defined(COMPILE_DL_PDO_MYSQL)
ZEND_TSRMLS_CACHE_EXTERN();
ZEND_TSRMLS_CACHE_EXTERN()
#endif


Expand Down
2 changes: 1 addition & 1 deletion ext/pgsql/pgsql.c
Original file line number Diff line number Diff line change
Expand Up @@ -773,7 +773,7 @@ zend_module_entry pgsql_module_entry = {

#ifdef COMPILE_DL_PGSQL
#ifdef ZTS
ZEND_TSRMLS_CACHE_DEFINE();
ZEND_TSRMLS_CACHE_DEFINE()
#endif
ZEND_GET_MODULE(pgsql)
#endif
Expand Down
2 changes: 1 addition & 1 deletion ext/pgsql/php_pgsql.h
Original file line number Diff line number Diff line change
Expand Up @@ -326,7 +326,7 @@ ZEND_EXTERN_MODULE_GLOBALS(pgsql)
# define PGG(v) ZEND_MODULE_GLOBALS_ACCESSOR(pgsql, v)

#if defined(ZTS) && defined(COMPILE_DL_PGSQL)
ZEND_TSRMLS_CACHE_EXTERN();
ZEND_TSRMLS_CACHE_EXTERN()
#endif

#endif
Expand Down
2 changes: 1 addition & 1 deletion ext/phar/phar.c
Original file line number Diff line number Diff line change
Expand Up @@ -3229,7 +3229,7 @@ int phar_flush(phar_archive_data *phar, char *user_stub, zend_long len, int conv

#ifdef COMPILE_DL_PHAR
#ifdef ZTS
ZEND_TSRMLS_CACHE_DEFINE();
ZEND_TSRMLS_CACHE_DEFINE()
#endif
ZEND_GET_MODULE(phar)
#endif
Expand Down
2 changes: 1 addition & 1 deletion ext/phar/phar_internal.h
Original file line number Diff line number Diff line change
Expand Up @@ -198,7 +198,7 @@ ZEND_EXTERN_MODULE_GLOBALS(phar)
#define PHAR_G(v) ZEND_MODULE_GLOBALS_ACCESSOR(phar, v)

#if defined(ZTS) && defined(COMPILE_DL_PHAR)
ZEND_TSRMLS_CACHE_EXTERN();
ZEND_TSRMLS_CACHE_EXTERN()
#endif

#ifndef php_uint16
Expand Down
2 changes: 1 addition & 1 deletion ext/session/php_session.h
Original file line number Diff line number Diff line change
Expand Up @@ -220,7 +220,7 @@ extern zend_module_entry session_module_entry;
#ifdef ZTS
#define PS(v) ZEND_TSRMG(ps_globals_id, php_ps_globals *, v)
#ifdef COMPILE_DL_SESSION
ZEND_TSRMLS_CACHE_EXTERN();
ZEND_TSRMLS_CACHE_EXTERN()
#endif
#else
#define PS(v) (ps_globals.v)
Expand Down
2 changes: 1 addition & 1 deletion ext/session/session.c
Original file line number Diff line number Diff line change
Expand Up @@ -3099,7 +3099,7 @@ zend_module_entry session_module_entry = {

#ifdef COMPILE_DL_SESSION
#ifdef ZTS
ZEND_TSRMLS_CACHE_DEFINE();
ZEND_TSRMLS_CACHE_DEFINE()
#endif
ZEND_GET_MODULE(session)
#endif
Expand Down
2 changes: 1 addition & 1 deletion ext/skeleton/php_skeleton.h
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ ZEND_END_MODULE_GLOBALS(extname)
#define EXTNAME_G(v) ZEND_MODULE_GLOBALS_ACCESSOR(extname, v)

#if defined(ZTS) && defined(COMPILE_DL_EXTNAME)
ZEND_TSRMLS_CACHE_EXTERN();
ZEND_TSRMLS_CACHE_EXTERN()
#endif

#endif /* PHP_EXTNAME_H */
Expand Down
2 changes: 1 addition & 1 deletion ext/skeleton/skeleton.c
Original file line number Diff line number Diff line change
Expand Up @@ -153,7 +153,7 @@ zend_module_entry extname_module_entry = {

#ifdef COMPILE_DL_EXTNAME
#ifdef ZTS
ZEND_TSRMLS_CACHE_DEFINE();
ZEND_TSRMLS_CACHE_DEFINE()
#endif
ZEND_GET_MODULE(extname)
#endif
Expand Down
Loading

0 comments on commit 1ac1529

Please sign in to comment.