HEX
Server: LiteSpeed
System: Linux srv146.niagahoster.com 4.18.0-553.30.1.lve.el8.x86_64 #1 SMP Tue Dec 3 01:21:19 UTC 2024 x86_64
User: kodi1989 (1633)
PHP: 8.1.34
Disabled: symlink,shell_exec,exec,popen,system,dl,passthru,escapeshellarg,escapeshellcmd,show_source,pcntl_exec
Upload Files
File: //opt/alt/python37/lib/python3.7/site-packages/pygments/lexers/__pycache__/php.cpython-37.pyc
B

��f�2�@s�dZddlZddlmZmZmZmZmZmZm	Z	m
Z
mZmZddl
mZmZmZmZmZmZmZmZmZmZddlmZmZmZdddgZGd	d�de�ZGd
d�de�ZGdd�de�ZdS)z�
    pygments.lexers.php
    ~~~~~~~~~~~~~~~~~~~

    Lexers for PHP and related languages.

    :copyright: Copyright 2006-2023 by the Pygments team, see AUTHORS.
    :license: BSD, see LICENSE for details.
�N)
�Lexer�
RegexLexer�include�bygroups�default�using�this�words�
do_insertions�line_re)
�Text�Comment�Operator�Keyword�Name�String�Number�Punctuation�Other�Generic)�get_bool_opt�get_list_opt�shebang_matches�ZephirLexer�PsyshConsoleLexer�PhpLexerc@seZdZdZdZdZdgZdgZdddd	gZd
ddgZ	e
je
jBZ
d
efdejfdejfged�dejdfdedfed�gdedfgdedfed�dedfdedfdefdedfdejdfdejfdejfdejfdejfd ej fd!ej!fd"ej"fd#ej#fd$ejfgd%�Z$d&S)'rz�
    For Zephir language source code.

    Zephir is a compiled high level language aimed
    to the creation of C-extensions for PHP.

    .. versionadded:: 2.0
    ZZephirzhttp://zephir-lang.com/Zzephirz*.zep�fetchZechoZisset�empty�bit�bits�stringz\s+z//.*?\nz	/\*.*?\*/�commentsandwhitespacez3/(\\.|[^[/\\\n]|\[(\\.|[^\]\\\n])*])+/([gim]+\b|\B)z#pop�/z\nz	^(?=\s|/)�slashstartsregexzC\+\+|--|~|&&|\?|:|\|\||\\(?=\n)|(<<|>>>?|==?|!=?|->|[-<>+*%&|^/])=?z[{(\[;,]z[})\].]z�(for|in|while|do|break|return|continue|switch|case|default|if|else|loop|require|inline|throw|try|catch|finally|new|delete|typeof|instanceof|void|namespace|use|extends|this|fetch|isset|unset|echo|fetch|likely|unlikely|empty)\bz(var|let|with|function)\bz�(abstract|boolean|bool|char|class|const|double|enum|export|extends|final|native|goto|implements|import|int|string|interface|long|ulong|char|uchar|float|unsigned|private|protected|public|short|static|self|throws|reverse|transient|volatile|readonly)\bz(true|false|null|undefined)\bzm(Array|Boolean|Date|_REQUEST|_COOKIE|_SESSION|_GET|_POST|_SERVER|this|stdClass|range|count|iterator|window)\bz[$a-zA-Z_][\w\\]*z%[0-9][0-9]*\.[0-9]+([eE][0-9]+)?[fd]?z0x[0-9a-fA-F]+z[0-9]+z"(\\\\|\\[^\\]|[^"\\])*"z'(\\\\|\\[^\\]|[^'\\])*')r!r#Zbadregex�rootN)%�__name__�
__module__�__qualname__�__doc__�name�url�aliases�	filenamesZzephir_keywordsZzephir_type�re�DOTALL�	MULTILINE�flagsrr
�Single�	Multilinerr�RegexrrrrZDeclarationZReserved�Constantr�Builtinrr�Float�Hex�Integer�Double�tokens�r;r;�D/opt/alt/python37/lib/python3.7/site-packages/pygments/lexers/php.pyrsJ



c@s.eZdZdZdZdZdgZdd�Zdd�Zd	S)
ru5
    For PsySH console output, such as:

    .. sourcecode:: psysh

        >>> $greeting = function($name): string {
        ...     return "Hello, {$name}";
        ... };
        => Closure($name): string {#2371 …3}
        >>> $greeting('World')
        => "Hello, World"

    .. versionadded:: 2.7
    zPsySH console session for PHPzhttps://psysh.org/ZpsyshcKsd|d<tj|f|�dS)NT�startinline)r�__init__)�self�optionsr;r;r<r>kszPsyshConsoleLexer.__init__c	cstf|j�}d}g}x�t�|�D]�}|��}|�d�s@|�d�rv|�t|�dtj	|dd�fgf�||dd�7}q |�
�dkr�|�t|�dtj	dfgf�||dd�7}q |r�t||�|��EdHd}g}|�
�tj|fVq W|�rt||�|��EdHdS)N�z>>> z... r�z...�)rr@r�finditer�group�
startswith�append�lenrZPrompt�rstripr
�get_tokens_unprocessed�startZOutput)r?�textZphplexerZcurcodeZ
insertions�match�liner;r;r<rJos,

z(PsyshConsoleLexer.get_tokens_unprocessedN)	r%r&r'r(r)r*r+r>rJr;r;r;r<rXsc$@s�eZdZdZdZdZddddgZdd	d
gZdgZdZ	d
Z
ejej
BejBZdejdfdefdefgdejdfde
deeeejeejee�fdefdedfdejfdejfdejfdejfdejfde
deeeej�fdefd efd!efd"eeee�fd#eee�d$fd%eee�fd&eeeee�d'fd(e	deeeej�fd)efd*ejfe d+�d,ej!d-fd.e	ej!fe	ejfd/e"j#fd0e"j#fd1e"j$fd2e"j%fd3e"j&fd4e"j'fd5ejfd6ej(fd7ej)d8fg!d9ej!dfe d�ge*d:d;d<�ej+j,fge*d=d;d<�ejfge	ej-dfge d>�e	ej+dfe.d�gd7ej)dfd?ej)fd@ej/fdAe
dBe
dCej0fdDeej0e1e2dEdF�ej0�fdGeej0e1e2dEdF�ej0�fdHeej0ej!ej0�fdIej)fgdJedfdKedLfe	ej3fe d�gdMedfe d�gdN�
Z4dOdP�Z5dQdR�Z6dSdT�Z7dUS)Vra;
    For PHP source code.
    For PHP embedded in HTML, use the `HtmlPhpLexer`.

    Additional options accepted:

    `startinline`
        If given and ``True`` the lexer starts highlighting with
        php code (i.e.: no starting ``<?php`` required).  The default
        is ``False``.
    `funcnamehighlighting`
        If given and ``True``, highlight builtin function names
        (default: ``True``).
    `disabledmodules`
        If given, must be a list of module names whose function names
        should not be highlighted. By default all modules are highlighted
        except the special ``'unknown'`` module that includes functions
        that are known to php but are undocumented.

        To get a list of allowed modules have a look into the
        `_php_builtins` module:

        .. sourcecode:: pycon

            >>> from pygments.lexers._php_builtins import MODULES
            >>> MODULES.keys()
            ['PHP Options/Info', 'Zip', 'dba', ...]

        In fact the names of those modules match the module names from
        the php documentation.
    ZPHPzhttps://www.php.net/�phpZphp3Zphp4Zphp5z*.phpz
*.php[345]z*.incz
text/x-phpz1(?:[\\_a-z]|[^\x00-\x7f])(?:[\\\w]|[^\x00-\x7f])*z+(?:[_a-z]|[^\x00-\x7f])(?:\w|[^\x00-\x7f])*z	<\?(php)?z[^<]+�<z\?>z#popz(<<<)([\'"]?)(z)(\2\n.*?\n\s*)(\3)(;?)(\n)z\s+z#\[�	attributez#.*?\nz//.*?\nz/\*\*/z/\*\*.*?\*/z	/\*.*?\*/z
(->|::)(\s*)(�)z[~!%^&*+=|:.<>/@-]+z\?z
[\[\]{}();,]+z(new)(\s+)(class)\bz(class)(\s+)�	classnamez(function)(\s*)(?=\()z(function)(\s+)(&?)(\s*)�functionnamez
(const)(\s+)(a(and|E_PARSE|old_function|E_ERROR|or|as|E_WARNING|parent|eval|PHP_OS|break|exit|case|extends|PHP_VERSION|cfunction|FALSE|print|for|require|continue|foreach|require_once|declare|return|default|static|do|switch|die|stdClass|echo|else|TRUE|elseif|var|empty|if|xor|enddeclare|include|virtual|endfor|include_once|while|endforeach|global|endif|list|endswitch|new|endwhile|not|array|E_ALL|NULL|final|php_user_filter|interface|implements|public|private|protected|abstract|clone|try|catch|throw|this|use|namespace|trait|yield|finally|match)\bz(true|false|null)\b�magicconstantsz\$\{�variablevariablez\$+z"(\d+\.\d*|\d*\.\d+)(e[+-]?[0-9]+)?z\d+e[+-]?[0-9]+z0[0-7]+z0x[a-f0-9]+z\d+z0b[01]+z'([^'\\]*(?:\\.[^'\\]*)*)'z`([^`\\]*(?:\\.[^`\\]*)*)`�"r z\})Z__constructZ
__destructZ__callZ__callStaticZ__get�__setZ__issetZ__unsetZ__sleepZ__wakeupZ
__toStringZ__invokeZ__set_stateZ__cloneZ__debugInfoz\b)�suffix)Z__LINE__Z__FILE__Z__DIR__Z__FUNCTION__Z	__CLASS__Z	__TRAIT__Z
__METHOD__Z
__NAMESPACE__�
magicfuncsz	[^{$"\\]+z'\\([nrt"$\\]|[0-7]{1,3}|x[0-9a-f]{1,2})z\$z(\[\S+?\]|->z)?z(\{\$\{)(.*?)(\}\})T)�_startinlinez(\{)(\$.*?)(\})z(\$\{)(\S+)(\})z[${\\]z\]z\(�attributeparamsz\))
r$rOrVrZrUrSrTr rQr\cKs�t|dd�|_t|ddg�|_t|dd�|_d|kr@|�d�|_t�|_|jr�dd	lm	}x*|�
�D]\}}||jkrd|j�|�qdWtj
|f|�dS)
N�funcnamehighlightingT�disabledmodules�unknownr=Fr[r)�MODULES)rr]rr^r=�pop�set�
_functionsZpygments.lexers._php_builtinsr`�items�updaterr>)r?r@r`�key�valuer;r;r<r>)s
zPhpLexer.__init__ccshdg}|jr|�d�xLt�|||�D]:\}}}|tjkrT||jkrT|tj|fVq&|||fVq&WdS)Nr$rO)r=rGrrJrrrcr5)r?rL�stack�index�tokenrgr;r;r<rJ=s


zPhpLexer.get_tokens_unprocessedcCs*t|d�rdSd}t�d|�r&|d7}|S)NrOTgz
<\?(?!xml)g333333�?)rr-�search)rL�rvr;r;r<�analyse_textIs
zPhpLexer.analyse_textN)8r%r&r'r(r)r*r+r,�	mimetypesZ_ident_innerZ_ident_nonsr-�
IGNORECASEr.r/r0r
ZPreprocrrrZ	Delimiterrrr1r2ZDocrr�	Attributerr4r�Variablerr6�Octr7r8ZBinZBacktickr9r	ZFunctionZMagicZClassrZEscapeZInterpolrrZ	Decoratorr:r>rJrmr;r;r;r<r�s�












) r(r-Zpygments.lexerrrrrrrrr	r
rZpygments.tokenrr
rrrrrrrrZ
pygments.utilrrr�__all__rrrr;r;r;r<�<module>	s00
B1