o
    Ñ­jïE  ã                   @   s„   d Z ddlmZ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mZmZ ddlmZ ddgZG dd„ deƒZG dd„ deƒZd	S )
a  
    pygments.lexers.theorem
    ~~~~~~~~~~~~~~~~~~~~~~~

    Lexers for theorem-proving languages.

    See also :mod:`pygments.lexers.lean`

    :copyright: Copyright 2006-present by the Pygments team, see AUTHORS.
    :license: BSD, see LICENSE for details.
é    )Ú
RegexLexerÚbygroupsÚdefaultÚwords)
ÚTextÚCommentÚOperatorÚKeywordÚNameÚStringÚNumberÚPunctuationÚGenericÚ
Whitespace)Ú	LeanLexerÚ	RocqLexerÚIsabelleLexerc                   @   s†  e Zd ZdZdZdZg d¢ZdgZddgZdZ	d	Z
d
ZdZdZdZdZdZdZdZdZdZdefdejjfdedfdefdejfdeejeejƒfdejdfdejdfeeddd �ejfeeddd �efeeddd �ejfeeddd �efeeddd �ejfeeddd �ejfd!efd"  d# !ed$d$d%… ¡¡e"fd&e› d#e› d'e› �e"fd(efd)e#j$fd*e#j%fd+e#j&fd,e#j'fd-e#j(fd.e)j*fd/e)j*fd0efd1e)j+d2fd3efd4ejjfgdefd5ejfd1e)j+d2fd6e#j$fd7e,d8fgdefd9efd:e"fd;efd)e#j$fd*e#j%fdedfd7e,d8fgd<efded=fd>ed8fd?efgd@e)j+fdAe)j+fd1e)j+d8fgdefd7e,fdBejfdCej-d8fdDed8fe.d8ƒgdEœZ/dFdG„ Z0d$S )Hr   z
    For the Rocq Prover.
    zRocq Proverzhttps://rocq-prover.org/)ÚcoqÚrocqzrocq-proverz*.vz
text/x-coqztext/x-rocqz1.5r   )cÚSectionÚModuleÚEndÚRequireÚImportÚExportÚIncludeÚVariableÚ	VariablesÚ	ParameterÚ
ParametersÚAxiomÚAxiomsÚ
HypothesisÚ
HypothesesÚNotationÚLocalÚTacticÚReservedÚScopeÚOpenÚCloseÚBindÚDeclareÚDelimitÚ
DefinitionÚExampleÚLetÚLtacÚLtac2ÚFixpointÚ
CoFixpointÚMorphismÚRelationÚImplicitÚ	ArgumentsÚTypesÚ
ContextualÚStrictÚPrenexÚ	ImplicitsÚ	InductiveÚCoInductiveÚRecordÚ	StructureÚVariantÚ	CanonicalÚCoercionÚTheoremÚLemmaÚFactÚRemarkÚ	CorollaryÚPropositionÚPropertyÚGoalÚProofÚRestartÚSaveÚQedÚDefinedÚAbortÚAdmittedÚHintÚResolveÚRewriteÚViewÚSearchÚComputeÚEvalÚShowÚPrintÚPrintingÚAllÚGraphÚProjectionsÚinsideÚoutsideÚCheckÚGlobalÚInstanceÚClassÚExistingÚUniverseÚPolymorphicÚMonomorphicÚContextÚSchemeÚFromÚUndoÚFailÚFunctionÚProgramÚElpiÚExtractÚOpaqueÚTransparentÚUnshelvezNext Obligation)ÚforallÚexistsÚexists2ÚfunÚfixÚcofixÚstructÚmatchÚendÚinÚreturnÚletÚifÚisÚthenÚelseÚforÚofÚnosimplÚwithÚas)ÚTypeÚPropÚSPropÚSet)CÚposeÚsetÚmoveÚcaseÚelimÚapplyÚclearÚhnfÚintroÚintrosÚ
generalizeÚrenameÚpatternÚafterÚdestructÚ	inductionÚusingÚrefineÚ	inversionÚ	injectionÚrewriteÚcongrÚunlockÚcomputeÚringÚfieldÚreplaceÚfoldÚunfoldÚchangeÚ
cutrewriteÚsimplÚhaveÚsuffÚwlogÚsufficesÚwithoutÚlossÚnat_normÚassertÚcutÚtrivialÚrevertÚ
bool_congrÚ	nat_congrÚsymmetryÚtransitivityÚautoÚsplitÚleftÚrightÚautorewriteÚtautoÚsetoid_rewriteÚ	intuitionÚeautoÚeapplyÚeconstructorÚetransitivityÚconstructorÚerewriteÚredÚcbvÚlazyÚ
vm_computeÚnative_computeÚsubst)ÚbyÚnowÚdoneÚexactÚreflexivityrÄ   ÚromegaÚomegaÚliaÚniaÚlraÚnraÚpsatzÚ
assumptionÚsolveÚcontradictionÚdiscriminateÚ
congruenceÚadmit)ÚdoÚlastÚfirstÚtryÚidtacÚrepeat);z!=ú#ú&z&&z\(z\)z\*z\+ú,ú-z-\.z->ú\.z\.\.ú:ú::z:=z:>ú;z;;ú<z<-z<->ú=ú>z>]z>\}z\?z\?\?z\[z\[<z\[>z\[\|ú]Ú_ú`z\{z\{<zlp:\{\{z\|z\|]z\}ú~z=>z/\\z\\/z\{\|z\|\}u   Î»õ   Â¬u   âˆ§u   âˆ¨u   âˆ€u   âˆƒu   â†’u   â†”u   â‰ u   â‰¤u   â‰¥z[!$%&*+\./:<=>?@^|~-]z[!?~]z[=<>@^|&+\*/$%-]ú\s+zfalse|true|\(\)|\[\]ú\(\*Úcommentz'\b(?:[^\W\d][\w\']*\.)+[^\W\d][\w\']*\bz\bEquations\b\??zM\b(Elpi)(\s+)(Program|Query|Accumulate|Command|Typecheck|Db|Export|Tactic)?\bz,\bUnset\b|\bSet(?=[ \t]+[A-Z][a-z][^\n]*?\.)úset-optionsz\b(?:String|Number)\s+Notationúsn-notationú\b©ÚprefixÚsuffixz\b([A-Z][\w\']*)z({})ú|Néÿÿÿÿú(z)?z[^\W\d][\w']*z\d[\d_]*ú0[xX][\da-fA-F][\da-fA-F_]*ú0[oO][0-7][0-7_]*ú0[bB][01][01_]*z(-?\d[\d_]*(.[\d_]*)?([eE][+\-]?\d[\d_]*)z7'(?:(\\[\\\"'ntbr ])|(\\[0-9]{3})|(\\x[0-9a-fA-F]{2}))'z'.'ú'ú"Ústringz[~?][a-z][\w\']*:z\Sz[A-Z]\w*z\d+rï   ú#popz*\b(?:via|mapping|abstract|warning|after)\bz=>|[()\[\]:,]z'\b[^\W\d][\w\']*(?:\.[^\W\d][\w\']*)*\bz([^(*)]+|\*+(?!\)))+ú#pushú\*\)ú[(*)]z[^"]+z""z[A-Z][\w\']*(?=\s*\.)z[A-Z][\w\']*z[a-z][a-z0-9_\']*)Úrootrþ   rÿ   rý   r  Údottedc                 C   s   d| v r
d| v rdS d S d S )NrP   rM   é   © )Útextr  r  úT/var/www/html/CropPilot/venv/lib/python3.10/site-packages/pygments/lexers/theorem.pyÚanalyse_text¾   s   ÿzRocqLexer.analyse_text)1Ú__name__Ú
__module__Ú__qualname__Ú__doc__ÚnameÚurlÚaliasesÚ	filenamesÚ	mimetypesÚversion_addedÚflagsÚ	keywords1Ú	keywords2Ú	keywords3Ú	keywords4Ú	keywords5Ú	keywords6ÚkeyoptsÚ	operatorsÚprefix_symsÚ
infix_symsr   r
   ÚBuiltinÚPseudor   r	   Ú	Namespacer   r   rŒ   r'   ÚformatÚjoinr   r   ÚIntegerÚHexÚOctÚBinÚFloatr   ÚCharÚDoubler   rf   r   Útokensr  r  r  r  r  r      s¤    	




Û(
û÷û
ý
úºPc                   @   sþ  e Zd ZdZdZdZdgZdgZdgZdZ	dZ
d	Zd
ZdZdZdZdZdZdZdZdZdZdZdZdZdZdZdZdZg def‘dedf‘dej df‘d edf‘e!eƒe"f‘e!eƒe"j#f‘e!e
d!d!d"�e$j%f‘e!ed!d!d"�e$j&f‘e!ed!d!d"�e$f‘e!ed!d!d"�e$f‘e!ed!d!d"�e'j(f‘e!ed!d!d"�e'j)f‘e!ed!d!d"�e$j*f‘e!ed!d!d"�e$j*f‘e!ed!d!d"�e'j+f‘e!ed!d!d"�e$f‘e!ed!d!d"�e$f‘e!ed!d!d"�e$f‘e!ed!d!d"�e$f‘e!ed!d!d"�e$f‘e!ed!d!d"�e$f‘e!ed!d!d"�e$f‘e!ed!d!d"�e$j%f‘d#e,j f‘d$e-j&f‘d%e.j/f‘d&e.j0f‘d'e.j1f‘d(ed)f‘d*ej2d+f‘d,e-f‘d-efded.fd/ed0fd1efgd2efdej d.fd ed.fd3ej d0fd4ed0fd#ej fd5efgd6efd#ej fd7efd8efd(ed0fgd9ej2fd#ej fd:ej2fd8ej2fd*ej2d0fgd;œZ3d<S )=r   z+
    For the Isabelle proof assistant.
    ÚIsabellezhttps://isabelle.in.tum.de/Úisabellez*.thyztext/x-isabellez2.0)2ÚandÚassumesÚattachÚavoidsÚbinderÚcheckingÚclass_instanceÚclass_relationÚcode_moduleÚcongsÚconstantÚ
constrainsÚ	datatypesÚdefinesÚfileÚfixesr‡   Ú	functionsÚhintsÚ
identifierrƒ   Úimportsr€   ÚincludesÚinfixÚinfixlÚinfixrr„   ÚkeywordsrÏ   Úmodule_nameÚmonosÚ	morphismsÚno_discs_selsÚnotesÚobtainsÚopenÚoutputÚ
overloadedÚ
parametricÚ
permissiveÚ	pervasiveÚ
rep_compatÚshowsÚ	structureÚ
type_classÚtype_constructorÚ	uncheckedÚunsafeÚwhere)LÚ
ML_commandÚML_valÚ
class_depsÚ	code_depsÚ	code_thmsÚdisplay_draftsÚfind_constsÚfind_theoremsÚfind_unused_assmsÚfull_prfÚhelpÚlocale_depsÚnitpickÚprÚprfÚprint_abbrevsÚprint_antiquotationsÚprint_attributesÚprint_bindsÚ
print_bnfsÚprint_bundlesÚprint_case_translationsÚprint_casesÚprint_clasetÚprint_classesÚprint_codeprocÚprint_codesetupÚprint_coercionsÚprint_commandsÚprint_contextÚprint_defn_rulesÚprint_dependenciesÚprint_factsÚprint_induct_rulesÚprint_inductivesÚprint_interpsÚprint_localeÚprint_localesÚprint_methodsÚprint_optionsÚprint_ordersÚprint_quot_mapsÚprint_quotconstsÚprint_quotientsÚprint_quotientsQ3Úprint_quotmapsQ3Úprint_rulesÚprint_simpsetÚprint_stateÚprint_statementÚprint_syntaxÚprint_theoremsÚprint_theoryÚprint_trans_rulesÚpropÚpwdÚ
quickcheckÚrefuteÚsledgehammerÚ
smt_statusÚsolve_directÚspark_statusÚtermÚthmÚthm_depsÚthy_depsrè   Útry0ÚtypÚunused_thmsÚvalueÚvaluesÚwelcomeÚprint_ML_antiquotationsÚprint_term_bindingsÚvalues_prolog)ÚtheoryÚbeginr   )ÚheaderÚchapter)ÚsectionÚ
subsectionÚsubsubsectionÚsectÚsubsectÚ
subsubsect)ŽÚMLÚML_fileÚabbreviationÚadhoc_overloadingÚaritiesÚ	atom_declÚattribute_setupÚaxiomatizationÚbundleÚcase_of_simpsÚclassÚclassesÚclassrelÚ
codatatypeÚ
code_abortÚ
code_classÚ
code_constÚcode_datatypeÚcode_identifierÚcode_includeÚcode_instanceÚcode_modulenameÚ
code_monadÚcode_printingÚcode_reflectÚcode_reservedÚ	code_typeÚcoinductiveÚcoinductive_setÚconstsÚcontextÚdatatypeÚdatatype_newÚdatatype_new_compatÚdeclarationÚdeclareÚdefault_sortÚdefer_recdefÚ
definitionÚdefsÚdomainÚdomain_isomorphismÚ	domaindefÚequivarianceÚexport_codeÚextractÚextract_typeÚfixrecrz   Ú	fun_casesÚ
hide_classÚ
hide_constÚ	hide_factÚ	hide_typeÚimport_const_mapÚimport_fileÚimport_tptpÚimport_type_mapÚ	inductiveÚinductive_setÚinstantiationÚjudgmentÚlemmasÚlifting_forgetÚlifting_updateÚlocal_setupÚlocaleÚmethod_setupÚnitpick_paramsÚno_adhoc_overloadingÚno_notationÚ	no_syntaxÚno_translationsÚno_type_notationÚnominal_datatypeÚnonterminalÚnotationÚnotepadÚoracleÚoverloadingÚparse_ast_translationÚparse_translationÚpartial_functionÚ	primcorecÚprimrecÚprimrec_newÚprint_ast_translationÚprint_translationÚquickcheck_generatorÚquickcheck_paramsÚrealizabilityÚ	realizersÚrecdefÚrecordÚrefute_paramsÚsetupÚsetup_liftingÚsimproc_setupÚsimps_of_caseÚsledgehammer_paramsÚ	spark_endÚ
spark_openÚspark_open_sivÚspark_open_vcgÚspark_proof_functionsÚspark_typesÚ
statespaceÚsyntaxÚsyntax_declarationr  Útext_rawÚtheoremsÚtranslationsÚtype_notationÚtype_synonymÚtyped_print_translationÚtypedeclÚ
hoarestateÚinstall_C_fileÚinstall_C_typesÚ	wpc_setupÚc_defsÚc_typesÚmemsafeÚ
SML_exportÚSML_fileÚ
SML_importÚapproximateÚbnf_axiomatizationÚ	cartoucheÚdatatype_compatÚfree_constructorsÚfunctorÚnominal_functionÚnominal_terminationÚpermanent_interpretationÚbindsÚdefiningÚsmt2_statusÚterm_cartoucheÚboogie_fileÚtext_cartouche)Úinductive_casesÚinductive_simps)!Úax_specificationÚbnfÚ	code_predÚ	corollaryÚcpodefÚcrunchÚcrunch_ignoreÚenriched_typeÚfunctionÚinstanceÚinterpretationÚlemmaÚlift_definitionÚnominal_inductiveÚnominal_inductive2Únominal_primrecÚpcpodefÚprimcorecursiveÚquotient_definitionÚquotient_typeÚ	recdef_tcÚrep_datatypeÚschematic_corollaryÚschematic_lemmaÚschematic_theoremÚspark_vcÚspecificationÚsubclassÚ	sublocaleÚterminationÚtheoremÚtypedefÚwrap_free_constructors)rÓ   rÕ   Úqed)ÚsorryÚoops)r°   ÚhenceÚ	interpret)ÚnextÚproof)ÚfinallyÚfromr…   Ú
ultimatelyrŠ   )ÚML_prfÚalsoÚincludeÚ	includingr‚   ÚmoreoverÚnoteÚtxtÚtxt_rawÚ	unfoldingr    Úwrite)Úassumer“   Údefr{   Úpresume)ÚguessÚobtainÚshowÚthus)r•   Ú	apply_endÚapply_traceÚbackÚdeferÚprefer)rñ   rð   r  ú)ú[rö   r÷   rô   rí   r  ú+rî   ú!ú?)Ú{Ú}Ú.z..rû   rü   rý   z\\<open>r=  u   \{\*|â€¹r   r  z\\<(\w|\^)*>z'[^\W\d][.\w']*r  r  r	  r  r  rø   Úfactz/[^\s:|\[\]\-()=,+!?{}._][^\s:|\[\]\-()=,+!?{}]*z[^(*)]+r  r  r  r  u   [^{*}\\â€¹â€º]+z	\\<close>u   \*\}|â€ºz[{*}\\]z[^"\\]+z\\"z\\z[^`\\]+z\\`)r  rý   r=  r  r•  N)4r  r  r  r  r  r  r  r  r   r!  Úkeyword_minorÚkeyword_diagÚkeyword_thyÚkeyword_sectionÚkeyword_subsectionÚkeyword_theory_declÚkeyword_theory_scriptÚkeyword_theory_goalÚkeyword_qedÚkeyword_abandon_proofÚkeyword_proof_goalÚkeyword_proof_blockÚkeyword_proof_chainÚkeyword_proof_declÚkeyword_proof_asmÚkeyword_proof_asm_goalÚkeyword_proof_scriptr*  Úproof_operatorsr   r   r   ÚSymbolr   r   ÚWordr	   r.  rŒ   r   ÚHeadingÚ
Subheadingr/  ÚErrorr   r
   r   r3  r4  r5  ÚOtherr9  r  r  r  r  r   Ã   sè    &ÿþ
ýü
úù	÷õóòðïíìêèçæåãâá!ß#Ý%Û'Ù(Ø)×+Õ
,Ô-Ó0ü

ù
û
û
ºN)r  Úpygments.lexerr   r   r   r   Úpygments.tokenr   r   r   r	   r
   r   r   r   r   r   Úpygments.lexers.leanr   Ú__all__r   r   r  r  r  r  Ú<module>   s    0 .