Skip to content

Commit

Permalink
update ze83ts.h and 062-stack_object_store_offsetExists.phpt
Browse files Browse the repository at this point in the history
  • Loading branch information
TheTechsTech committed Feb 23, 2023
1 parent ed49bec commit ccfe4d7
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 32 deletions.
52 changes: 26 additions & 26 deletions headers/ze83ts.h
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ typedef struct _zend_file_handle
} handle;
zend_string *filename;
zend_string *opened_path;
zend_uchar type; /* packed zend_stream_type */
uint8_t type; /* packed zend_stream_type */
bool primary_script;
bool in_list; /* added into CG(open_file) */
char *buf;
Expand Down Expand Up @@ -191,8 +191,8 @@ struct _zval_struct
uint32_t type_info;
struct
{
zend_uchar type;
zend_uchar type_flags;
uint8_t type;
uint8_t type_flags;
union
{
uint16_t extra;
Expand Down Expand Up @@ -229,10 +229,10 @@ struct _zend_array
{
struct
{
zend_uchar flags;
zend_uchar _unused;
zend_uchar nIteratorsCount;
zend_uchar _unused2;
uint8_t flags;
uint8_t _unused;
uint8_t nIteratorsCount;
uint8_t _unused2;
} v;
uint32_t flags;
} u;
Expand Down Expand Up @@ -327,7 +327,7 @@ typedef zend_result (*zend_object_cast_t)(zend_object *readobj, zval *retval, in
typedef zend_result (*zend_object_count_elements_t)(zend_object *object, zend_long *count);
typedef zend_result (*zend_object_get_closure_t)(zend_object *obj, zend_class_entry **ce_ptr, zend_function **fptr_ptr, zend_object **obj_ptr, bool check_only);
typedef HashTable *(*zend_object_get_gc_t)(zend_object *object, zval **table, int *n);
typedef zend_result (*zend_object_do_operation_t)(zend_uchar opcode, zval *result, zval *op1, zval *op2);
typedef zend_result (*zend_object_do_operation_t)(uint8_t opcode, zval *result, zval *op1, zval *op2);

struct _zend_object_handlers
{
Expand Down Expand Up @@ -382,8 +382,8 @@ typedef struct _zend_arg_info
typedef struct _zend_internal_function
{
/* Common elements */
zend_uchar type;
zend_uchar arg_flags[3]; /* bitset of arg_info.pass_by_reference */
uint8_t type;
uint8_t arg_flags[3]; /* bitset of arg_info.pass_by_reference */
uint32_t fn_flags;
zend_string *function_name;
zend_class_entry *scope;
Expand Down Expand Up @@ -430,8 +430,8 @@ typedef struct _zend_try_catch_element
struct _zend_op_array
{
/* Common elements */
zend_uchar type;
zend_uchar arg_flags[3]; /* bitset of arg_info.pass_by_reference */
uint8_t type;
uint8_t arg_flags[3]; /* bitset of arg_info.pass_by_reference */
uint32_t fn_flags;
zend_string *function_name;
zend_class_entry *scope;
Expand Down Expand Up @@ -501,8 +501,8 @@ typedef union _znode_op

typedef struct _znode
{ /* used only during compilation */
zend_uchar op_type;
zend_uchar flag;
uint8_t op_type;
uint8_t flag;
union
{
znode_op op;
Expand All @@ -518,21 +518,21 @@ struct _zend_op
znode_op result;
uint32_t extended_value;
uint32_t lineno;
zend_uchar opcode;
zend_uchar op1_type;
zend_uchar op2_type;
zend_uchar result_type;
uint8_t opcode;
uint8_t op1_type;
uint8_t op2_type;
uint8_t result_type;
};

union _zend_function
{
zend_uchar type; /* MUST be the first element of this struct! */
uint8_t type; /* MUST be the first element of this struct! */
uint32_t quick_arg_flags;

struct
{
zend_uchar type; /* never used */
zend_uchar arg_flags[3]; /* bitset of arg_info.pass_by_reference */
uint8_t type; /* never used */
uint8_t arg_flags[3]; /* bitset of arg_info.pass_by_reference */
uint32_t fn_flags;
zend_string *function_name;
zend_class_entry *scope;
Expand Down Expand Up @@ -1092,7 +1092,7 @@ struct _zend_compiler_globals
HashTable *auto_globals;

/* Refer to zend_yytnamerr() in zend_language_parser.y for meaning of values */
zend_uchar parse_error;
uint8_t parse_error;
bool in_compilation;
bool short_tags;

Expand Down Expand Up @@ -1412,7 +1412,7 @@ struct _zend_executor_globals
struct _zend_module_entry *current_module;

bool active;
zend_uchar flags;
uint8_t flags;

zend_long assertions;

Expand Down Expand Up @@ -1622,15 +1622,15 @@ void zend_hash_copy(HashTable *target, HashTable *source, copy_ctor_func_t pCopy
void zend_hash_destroy(HashTable *ht);
void zend_hash_clean(HashTable *ht);

int zend_set_user_opcode_handler(zend_uchar opcode, user_opcode_handler_t handler);
user_opcode_handler_t zend_get_user_opcode_handler(zend_uchar opcode);
int zend_set_user_opcode_handler(uint8_t opcode, user_opcode_handler_t handler);
user_opcode_handler_t zend_get_user_opcode_handler(uint8_t opcode);

void zval_ptr_dtor(zval *zval_ptr);
void zval_internal_ptr_dtor(zval *zvalue);
void zval_add_ref(zval *p);
zval *zend_get_zval_ptr(const zend_op *opline, int op_type, const znode_op *node, const zend_execute_data *execute_data);

zend_uchar zend_get_call_op(const zend_op *init_op, zend_function *fbc);
uint8_t zend_get_call_op(const zend_op *init_op, zend_function *fbc);
void object_init(zval *arg);
zend_result object_init_ex(zval *arg, zend_class_entry *ce);

Expand Down
6 changes: 0 additions & 6 deletions tests/062-stack_object_store_offsetExists.phpt
Original file line number Diff line number Diff line change
Expand Up @@ -21,12 +21,6 @@ class Entry
public function getOffsetExists(): void
{
$id = spl_object_id($this);
if (\IS_PHP83) {
var_dump($id);
var_dump($this->objectStore);
var_dump($this->objectStore->offsetExists($id));
}

var_dump($this->objectStore->offsetExists($id) === true);
var_dump(isset($this->objectStore[$id]) === true);
}
Expand Down

0 comments on commit ccfe4d7

Please sign in to comment.