
    ,hz!                         d Z ddlZddlmZmZmZ ddlmZmZm	Z	m
Z
mZmZmZmZ ddgZ G d de      ZeZ G d de      Zy)	z
    pygments.lexers.lean
    ~~~~~~~~~~~~~~~~~~~~

    Lexers for the Lean theorem prover.

    :copyright: Copyright 2006-2025 by the Pygments team, see AUTHORS.
    :license: BSD, see LICENSE for details.
    N)
RegexLexerwordsinclude)CommentOperatorKeywordNameStringNumberGeneric
Whitespace
Lean3Lexer
Lean4Lexerc                      e Zd ZdZdZdZddgZdgZddgZd	Z	d
Z
e
dz   e
z   dz   Zdefdej                  dfdedfdej                   f eddd      ef eddd      ej(                  f eddd      ej*                  f ed      efeefdez   ej0                  fdej4                  fdej4                  fdej4                  fdej6                  dfdej8                  fd ej:                  fd!ej<                  j>                  fg ed"dd      ej@                  f ed#dd      ejB                  fd$ejB                  d%f ed&d'      ef e"d(      gd)ejB                  d*f e"d(      gd+ejF                  fdejF                  d,fd-ejF                  d*fd.ejF                  fgd+ej                  fd-ej                  d*fd.ej                  fgd/ej6                  fd0ejH                  fdej6                  d*fgd1Z%d2 Z&y3)4r   z(
    For the Lean 3 theorem prover.
    Leanz,https://leanprover-community.github.io/lean3leanlean3*.leanztext/x-leanztext/x-lean3z2.0u   (?![λΠΣ])[_a-zA-Zα-ωΑ-Ωϊ-ϻἀ-῾℀-⅏𝒜-𝖟](?:(?![λΠΣ])[_a-zA-Zα-ωΑ-Ωϊ-ϻἀ-῾℀-⅏𝒜-𝖟0-9'ⁿ-₉ₐ-ₜᵢ-ᵪ])*(\.)*\s+/--	docstring/-commentz--.*?$)forallfunPifromhaveshowassumesufficesletifelsetheninwithcalcmatchdo\bprefixsuffixsorryadmit)SortPropType)():{}[]   ⟨   ⟩u   ‹u   ›   ⦃   ⦄:=,``?z0x[A-Za-z0-9]+z0b[01]+\d+"stringz='(?:(\\[\\\"'nt])|(\\x[0-9a-fA-F]{2})|(\\u[0-9a-fA-F]{4})|.)'[~?][a-z][\w\']*:\S)importrenaminghiding	namespacelocalprivate	protectedsectionr   omitrQ   rP   exportopen	attribute)(lemmatheoremdef
definitionexampleaxiomaxiomsconstant	constantsuniverse	universes	inductivecoinductive	structureextendsclassinstanceabbreviationznoncomputable theorynoncomputablemutualmetarU   	parameter
parametersvariable	variablesreserve
precedencepostfixr/   notationinfixinfixlinfixrbeginbyend
set_optionrun_cmd@\[rU   )#eval#check#reduce#exit#print#help)r0   
expression\]#pop[^/-]+#push-/[/-][^\\"]+z9(?:(\\[\\\"'nt])|(\\x[0-9a-fA-F]{2})|(\\u[0-9a-fA-F]{4}))r   rootrU   r   r   rG   c                 P    t        j                  d| t         j                        ryy )Nz^import [a-z]皙?research	MULTILINEtexts    V/var/www/html/Resume-Scraper/venv/lib/python3.12/site-packages/pygments/lexers/lean.pyanalyse_textzLean3Lexer.analyse_text       99%tR\\: ;    N)'__name__
__module____qualname____doc__nameurlaliases	filenames	mimetypesversion_added_name_segment_namer   r
   Docr   Singler   r   r   Errorr6   r   r	   Symbolr   IntegerDoubleCharVariableBuiltinPseudo	NamespaceDeclarationr   	MultilineEscapetokensr    r   r   r   r      s    D
8CwG
I/IM	d  F"]2U:E Z VZZ-GY''   	/ 18	9
 %eEBGMMR+E%H',,W   DMe^V]]+/(V^^$6==(+Mv{{[!4==1DLL''(/
4  	 E	+ -4,=,=	?  0 E1+0 -4,?,?1A2 W((+6   &' L!S*
X G''0L!

 ))*G%%w/G%%v.g''(	
 

#FJJ'fjj!
 'I6==Y&--(
iYFvr   c                      e Zd ZdZdZdZdgZdgZdgZdZ	dZ
e
d	z   e
z   d
z   ZdZdZdZdZdZdefdej&                  dfdedfdej*                  f eedd      ej0                  f eddd      ej4                  f ee      ej8                  j:                  f ee      efe
efdez   ej>                  fde fde jB                  fde jD                  fdejF                  dfdejH                  fd ej8                  j:                  fg eedd      ejJ                  f eedd      efd!ejL                  d"f e'd#      gd$ejL                  d%f e'd#      gd&ejP                  fdejP                  d'fd(ejP                  d%fd)ejP                  fgd&ej&                  fd(ej&                  d%fd)ej&                  fgd*ejF                  fd+ejR                  fdejF                  d%fgd,Z*d- Z+y.)/r   z(
    For the Lean 4 theorem prover.
    Lean4z#https://github.com/leanprover/lean4lean4r   ztext/x-lean4z2.18u   (?![λΠΣ])[_a-zA-Zα-ωΑ-Ωϊ-ϻἀ-῾℀-⅏𝒜-𝖟](?:(?![λΠΣ])[_a-zA-Zα-ωΑ-Ωϊ-ϻἀ-῾℀-⅏𝒜-𝖟0-9'ⁿ-₉ₐ-ₜᵢ-ᵪ!?])*r   r   )6rJ   	unif_hintrK   inlinerL   rV   rm   rW   r[   ra   rc   r_   aliasr   rp   rq   r/   rs   rt   ru   rr   r|   r}   r~   r   rx   rO   usingrM   rf   rQ   rP   rS   ry   rd   rT   rZ   r   opaquerX   macroelabsyntaxmacro_rulesr~   whereabbrevrh   re   rU   z#synthri   scopedrN   )r   r   obtainr   r    r!   r"   r$   r%   r&   r'   rw   r(   r)   r*   r+   nomatchr,   at)r6   r5   r4   )8z!=#&z&&*+-/@!z-.z->.z..z...z::z:>;z;;<z<-=z==>_|z||~z=>z<=z>=z/\z\/u   ∀u   Πu   λu   ↔u   ∧u   ∨u   ≠u   ≤u   ≥   ¬u   ⁻¹u   ⬝u   ▸u   →u   ∃u   ≈   ×u   ⌞u   ⌟u   ≡r>   r?   u   ↦)r7   r8   r9   r:   r;   r<   r=   r@   rA   rB   rC   r   r   r   r   r   z--.*$r-   r.   r1   rD   z
(?<=\.)\d+z(\d+\.\d*)([eE][+-]?[0-9]+)?rE   rF   rG   rH   rI   r{   rU   r   r   r   r   r   r   r   r   z
\\[n"\\\n]r   c                 P    t        j                  d| t         j                        ryy )Nz^import [A-Z]r   r   r   s    r   r   zLean4Lexer.analyse_text   r   r   N),r   r   r   r   r   r   r   r   r   r   r   r   	keywords1	keywords2	keywords3	operatorspunctuationr   r
   r   r   r   r   r   r6   r   r   r	   r   r   r   r   r   Floatr   r   r   r   r   r   r   r   r   r   r   r   r   r   r      si    D
/CiG
I IM	f  F"]2U:EIII
IK
 Z VZZ-GY'w~~&9U597<<H%eEBGMMR9t||223;*D!e^V]]+F#,fll;V^^$6==(+!4==1DLL''(!
& 9U597;L;LM9U597CW((+6L!	
 G''0L!
 ))*G%%w/G%%v.g''(
 

#FJJ'fjj!
 'FMM*&--(
S.F`r   )r   r   pygments.lexerr   r   r   pygments.tokenr   r   r   r	   r
   r   r   r   __all__r   	LeanLexerr   r   r   r   <module>r      sT    
 5 5      
&n nb 	j jr   