mirror of
https://github.com/php/php-src.git
synced 2025-08-15 21:48:51 +02:00
ext/opcache: C++ compatibility
This commit is contained in:
parent
a83cc9d397
commit
373f236673
5 changed files with 20 additions and 0 deletions
|
@ -69,9 +69,13 @@
|
|||
# error "Unknown ZEND_MAP_PTR_KIND"
|
||||
#endif
|
||||
|
||||
BEGIN_EXTERN_C()
|
||||
|
||||
ZEND_API void zend_map_ptr_reset(void);
|
||||
ZEND_API void *zend_map_ptr_new(void);
|
||||
ZEND_API void zend_map_ptr_extend(size_t last);
|
||||
ZEND_API void zend_alloc_ce_cache(zend_string *type_name);
|
||||
|
||||
END_EXTERN_C()
|
||||
|
||||
#endif /* ZEND_MAP_PTR_H */
|
||||
|
|
|
@ -311,6 +311,8 @@ extern zend_accel_globals accel_globals;
|
|||
|
||||
extern char *zps_api_failure_reason;
|
||||
|
||||
BEGIN_EXTERN_C()
|
||||
|
||||
void accel_shutdown(void);
|
||||
zend_result accel_activate(INIT_FUNC_ARGS);
|
||||
zend_result accel_post_deactivate(void);
|
||||
|
@ -333,6 +335,8 @@ zend_string* ZEND_FASTCALL accel_new_interned_string(zend_string *str);
|
|||
|
||||
uint32_t zend_accel_get_class_name_map_ptr(zend_string *type_name);
|
||||
|
||||
END_EXTERN_C()
|
||||
|
||||
/* memory write protection */
|
||||
#define SHM_PROTECT() \
|
||||
do { \
|
||||
|
|
|
@ -60,6 +60,8 @@ typedef struct _zend_accel_hash {
|
|||
uint32_t num_direct_entries;
|
||||
} zend_accel_hash;
|
||||
|
||||
BEGIN_EXTERN_C()
|
||||
|
||||
void zend_accel_hash_init(zend_accel_hash *accel_hash, uint32_t hash_size);
|
||||
void zend_accel_hash_clean(zend_accel_hash *accel_hash);
|
||||
|
||||
|
@ -90,4 +92,6 @@ static inline bool zend_accel_hash_is_full(zend_accel_hash *accel_hash)
|
|||
}
|
||||
}
|
||||
|
||||
END_EXTERN_C()
|
||||
|
||||
#endif /* ZEND_ACCELERATOR_HASH_H */
|
||||
|
|
|
@ -25,6 +25,8 @@
|
|||
#include "zend.h"
|
||||
#include "ZendAccelerator.h"
|
||||
|
||||
BEGIN_EXTERN_C()
|
||||
|
||||
zend_persistent_script* create_persistent_script(void);
|
||||
void free_persistent_script(zend_persistent_script *persistent_script, int destroy_elements);
|
||||
|
||||
|
@ -42,4 +44,6 @@ unsigned int zend_adler32(unsigned int checksum, unsigned char *buf, uint32_t le
|
|||
|
||||
unsigned int zend_accel_script_checksum(zend_persistent_script *persistent_script);
|
||||
|
||||
END_EXTERN_C()
|
||||
|
||||
#endif /* ZEND_ACCELERATOR_UTIL_FUNCS_H */
|
||||
|
|
|
@ -125,6 +125,8 @@ extern zend_smm_shared_globals *smm_shared_globals;
|
|||
|
||||
#define SHARED_ALLOC_REATTACHED (SUCCESS+1)
|
||||
|
||||
BEGIN_EXTERN_C()
|
||||
|
||||
int zend_shared_alloc_startup(size_t requested_size, size_t reserved_size);
|
||||
void zend_shared_alloc_shutdown(void);
|
||||
|
||||
|
@ -200,4 +202,6 @@ void zend_shared_alloc_lock_win32(void);
|
|||
void zend_shared_alloc_unlock_win32(void);
|
||||
#endif
|
||||
|
||||
END_EXTERN_C()
|
||||
|
||||
#endif /* ZEND_SHARED_ALLOC_H */
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue