略微加速

PHP官方手册 - 互联网笔记

PHP - Manual: FETCH_IS

2024-12-25

FETCH_IS

PHP code

<?php
/*
 * Fetch the value from variable which is to be used to test if it is set or not, through isset()/isempty().
 * opcode number: 89
 */
echo isset($_SESSION['userid']);
echo isset(
$_SESSION['userid'][1]);
echo isset(
$_SESSION->prop->prop);
?>

PHP opcodes

Function name: (null)

Compiled variables: none

line#op fetchextreturn operands
60 FETCH_IS   $0 '_SESSION'
 1 ZEND_ISSET_ISEMPTY_DIM_OBJ  1~1 $0,'userid'
 2 ECHO     ~1
73 FETCH_IS   $2 '_SESSION'
 4 FETCH_DIM_IS   $3 $2,'userid'
 5 ZEND_ISSET_ISEMPTY_DIM_OBJ  1~4 $3,1
 6 ECHO     ~4
87 FETCH_IS   $5 '_SESSION'
 8 FETCH_OBJ_IS   $6 $5,'prop'
 9 ZEND_ISSET_ISEMPTY_PROP_OBJ   ~7 $6,'prop'
 10 ECHO     ~7
911 RETURN     1
add a note add a note

User Contributed Notes

There are no user contributed notes for this page.

官方地址:https://www.php.net/manual/en/internals2.opcodes.fetch-is.php

北京半月雨文化科技有限公司.版权所有 京ICP备12026184号-3