WordPress/Sniff.php
protected function get_array_access_key( $stackPtr ) {

		$keys = $this->get_array_access_keys( $stackPtr, false );

		if ( isset( $keys[0] ) ) {
			return $keys[0];
		}

		return false;
	}
protected function get_array_access_key( $stackPtr ) {

		$keys = $this->get_array_access_keys( $stackPtr, false );

		if ( isset( $keys[0] ) ) {
			return $keys[0];
		}

		return false;
	}
Get the index key of an array variable.

E.g., "bar" in $foo['bar'].

@since 0.5.0
@since 2.1.0 Now uses get_array_access_keys() under the hood.

@param int $stackPtr The index of the token in the stack.

@return string|false The array index key whose value is being accessed.