/opt/imh/python3.13/lib/python3.13/idlelib/__pycache__
NameSizeModeActions
autocomplete.cpython-313.pyc112580644editdlrm
autocomplete_w.cpython-313.pyc240340644editdlrm
autoexpand.cpython-313.pyc46870644editdlrm
browser.cpython-313.pyc135040644editdlrm
calltip.cpython-313.pyc85010644editdlrm
calltip_w.cpython-313.pyc103840644editdlrm
codecontext.cpython-313.pyc133780644editdlrm
colorizer.cpython-313.pyc179650644editdlrm
config.cpython-313.pyc409880644editdlrm
configdialog.cpython-313.pyc1207390644editdlrm
config_key.cpython-313.pyc197410644editdlrm
debugger.cpython-313.pyc285150644editdlrm
debugger_r.cpython-313.pyc188930644editdlrm
debugobj.cpython-313.pyc77410644editdlrm
debugobj_r.cpython-313.pyc26220644editdlrm
delegator.cpython-313.pyc17980644editdlrm
dynoption.cpython-313.pyc32610644editdlrm
editor.cpython-313.pyc876170644editdlrm
filelist.cpython-313.pyc58410644editdlrm
format.cpython-313.pyc205710644editdlrm
grep.cpython-313.pyc110150644editdlrm
help.cpython-313.pyc163120644editdlrm
help_about.cpython-313.pyc124840644editdlrm
history.cpython-313.pyc52110644editdlrm
hyperparser.cpython-313.pyc124820644editdlrm
idle.cpython-313.pyc6260644editdlrm
iomenu.cpython-313.pyc219320644editdlrm
macosx.cpython-313.pyc97700644editdlrm
mainmenu.cpython-313.pyc35560644editdlrm
multicall.cpython-313.pyc222460644editdlrm
outwin.cpython-313.pyc77130644editdlrm
parenmatch.cpython-313.pyc95720644editdlrm
pathbrowser.cpython-313.pyc57830644editdlrm
percolator.cpython-313.pyc70480644editdlrm
pyparse.cpython-313.pyc180300644editdlrm
pyshell.cpython-313.pyc832030644editdlrm
query.cpython-313.pyc195630644editdlrm
redirector.cpython-313.pyc87590644editdlrm
replace.cpython-313.pyc140350644editdlrm
rpc.cpython-313.pyc301130644editdlrm
run.cpython-313.pyc302240644editdlrm
runscript.cpython-313.pyc111660644editdlrm
scrolledlist.cpython-313.pyc91570644editdlrm
search.cpython-313.pyc79280644editdlrm
searchbase.cpython-313.pyc119560644editdlrm
searchengine.cpython-313.pyc100770644editdlrm
sidebar.cpython-313.pyc288730644editdlrm
squeezer.cpython-313.pyc143530644editdlrm
stackviewer.cpython-313.pyc73580644editdlrm
statusbar.cpython-313.pyc29620644editdlrm
textview.cpython-313.pyc97720644editdlrm
tooltip.cpython-313.pyc96060644editdlrm
tree.cpython-313.pyc286560644editdlrm
undo.cpython-313.pyc187030644editdlrm
util.cpython-313.pyc13510644editdlrm
window.cpython-313.pyc49590644editdlrm
zoomheight.cpython-313.pyc45280644editdlrm
zzdummy.cpython-313.pyc32830644editdlrm
__init__.cpython-313.pyc5340644editdlrm
__main__.cpython-313.pyc3490644editdlrm
Edit: /opt/imh/python3.13/lib/python3.13/idlelib/__pycache__/pyparse.cpython-313.pyc (18030B)
eMFSrSSKr\"S5urrrrr\R"S\R\R-5Rr \R"S\R5Rr\R"S\R\R-5Rr\R"S\R5Rr\R"S\R5Rr\R"S \R5Rr"S S \5r\R-\"S 5S 5r\R1SS55 \R1SS55 \R1SS55 "SS5r\S:XaSSKJr \"SSS9 gg)aDefine partial Python code Parser used by editor and hyperparser. Instances of ParseMap are used with str.translate. The following bound search and match functions are defined: _synchre - start of popular statement; _junkre - whitespace or comment line; _match_stringre: string, possibly without closer; _itemre - line that may have bracket structure start; _closere - line that must be followed by dedent. _chew_ordinaryre - non-special characters. Nz ^ [ \t]* (?: while | else | def | return | assert | break | class | continue | elif | try | except | raise | import | yield ) \b z' [ \t]* (?: \# \S .* )? \n aK \""" [^"\\]* (?: (?: \\. | "(?!"") ) [^"\\]* )* (?: \""" )? | " [^"\\\n]* (?: \\. [^"\\\n]* )* "? | ''' [^'\\]* (?: (?: \\. | '(?!'') ) [^'\\]* )* (?: ''' )? | ' [^'\\\n]* (?: \\. [^'\\\n]* )* '? zM [ \t]* [^\s#\\] # if we match, m.end()-1 is the interesting char z_ \s* (?: return | break | continue | raise | pass ) \b z [^[\](){}#'"\\]+ c\rSrSrSrSrSrg)ParseMapfaTDict subclass that maps anything not in dict to 'x'. This is designed to be used with str.translate in study1. Anything not specifically mapped otherwise becomes 'x'. Example: replace everything except whitespace with 'x'. >>> keepwhite = ParseMap((ord(c), ord(c)) for c in ' \t\n\r') >>> "a + b\tc\nd".translate(keepwhite) 'x x x\tx\nx' cg)Nx)selfkeys 5/opt/imh/python3.13/lib/python3.13/idlelib/pyparse.py __missing__ParseMap.__missing__rsr N)__name__ __module__ __qualname____firstlineno____doc__r __static_attributes__r rr rrfs  rrrc#N# UHn[U5[S54v M g7f)(Nord.0cs r rx /Ac!fc#h #%z({[c#N# UHn[U5[S54v M g7f))Nrrs r rryrr z)}]c#N# UHn[U5[U54v M g7fNrrs r rrzs 2z!c!fc!f zr z"'\ #ch\rSrSrSrSrSrSrSrSr Sr S r S r S r S rS rSrSrSrg)Parser}cXlX lgr$) indentwidthtabwidth)r r)r*s r __init__Parser.__init__s & rcR[U5S:Xd USS:XdeXlSUlg)Nr )lencode study_level)r ss r set_codeParser.set_codes*1v{aetm++ rc\URSp2[U5n[S5HvnURSSU5nUS:a O\URSSU5S-n[ X&U5nU(a-U"UR 55(dUR 5n OUnMx Uc?[ U5nU(a+U"UR 55(dUR 5nU$US-n[ X&5=n(a5UR 5upU"U5(dUn[ X&5=n(aM5U$)a Return index of a good place to begin parsing, as close to the end of the string as possible. This will be the start of some popular stmt like "if" or "def". Return None if none found: the caller should pass more prior context then, if possible, or if not (the entire program text up until the point of interest has already been tried) pass 0 to set_lo(). This will be reliable iff given a reliable is_char_in_string() function, meaning that when it says "no", it's absolutely guaranteed that the char is not in a string. Nrz: rr/)r1r0rangerfind_synchrestartspan) r is_char_in_stringr1poslimittriesimr3s r find_good_parse_startParser.find_good_parse_startsIItc D 1XE 5!U+A1u 4A&*A%(A*177955ggiE ;A*177955ggiJ !GD$$a$668DA$Q''D$$a$ rcvUS:XdURUS- S:XdeUS:aURUSUlgg)zgThrow away the start of the string. Intended to be called with the result of find_good_parse_start(). rr7r/N)r1)r los r set_lo Parser.set_losA Qw$))BqD/T111 6 "#DI rcURS:agSUlURnUR[5nUR SS5nUR SS5nUR SS5nUR SS5nUR SS5n[ nS =p4S /=UlnURnS [U5pXx:GakXn US-nU S:XaMU S:XaUS-nUS :XaU"U5 M2U S :XaUS-nM?U S :XaU(aUS- nMSU S :XdU S :XaU n XS- US-U S-:XaU S-n Un [U 5S- n X|-nXx:amXn US-nU S:XaMXS- X|-U :XaX|-nO`U S:XaUS-nU S :XaUS :XaU"U5 O@MJU S:XaXx:deXS:XaUS-nUS-nMkXx:aMmUS- U :Xa[nO[nGMU S:XaURSU5nUS :deGM9U S:XdeXx:deXS:XaUS-nUS-U:Xa[nUS-nXx:aGMkU[:waU[:wa US :a[nX lU[ :HUSU:H:XdeUSU:wa U"U5 gg)zFind the line numbers of non-continuation lines. As quickly as humanly possible , find the line numbers (0- based) of the non-continuation lines. Creates self.{goodlines, continuation}. r7Nxxxxxxxxxxxxxxxz xr/rrr""'\#r.)r2r1 translatetransreplaceC_NONE goodlinesappendr0C_STRING_FIRST_LINEC_STRING_NEXT_LINESfind C_BACKSLASH C_BRACKET continuation) r r1r_levellnorX push_goodrAnchquotefirstlnows r _study1Parser._study1s   q  yy~~e$||J,||FC(||D#&||D#&||E4( &'S($$ #d)1eB!ASyTzAgA:cNSy Sy!AIESyB#I!AaC=EAI-!AIEJNCeB!ASy aC}-CTz!Ag6$z )#! Tz u u7d?"%'CaC 3e@aH,(; ': SyIIdA&Av v: :5L5w$AgQ3!8#.L!Aket / / 33 $L(&IbMS,@AAA R=C  cN rc:UR5 UR$r$)rhr_r s r get_continuation_typeParser.get_continuation_typeKs    rcURS:agUR5 SUlURURp![ U5S- n[ U5nU(a^U(deUn[ X#S- X#5HnUR SSUS- 5S-nM [X5(aUS- nOO U(aM^US:Xa US:XdeUnUWsUlUl Sn/nURn US4/n XE:Ga[XU5n U (aHU R5n U S- nX4:aXS;aUS- nX4:a XS;aMX4:aXnU nXE:aGOcXn U S;a-U "U5 U RU[ U545 U nUS-nMU S ;a/U(aUS U nUS-nU RU[ U545 MU S :XdU S :XaZU RU[ U5S-45 U n[XU5R5nU RU[ U545 GM3U S :Xa[U RU[ U5S-45 URSXE5S-nUS:deU RU[ U545 GMU S:XdeUS-nXE:deXS:waXU-nUS-nXE:aGMXplU(aUS OSUl[#U 5Ulg)a study1 was sufficient to determine the continuation status, but doing more requires looking at every character. study2 does this for the last interesting statement in the block. Creates: self.stmt_start, stmt_end slice indices of last interesting stmt self.stmt_bracketing the bracketing structure of the last interesting stmt; for example, for the statement "say(boo) or die", stmt_bracketing will be ((0, 0), (0, 1), (2, 0), (2, 1), (4, 0)). Strings and comments are treated as brackets, for the matter. self.lastch last interesting character before optional trailing comment self.lastopenbracketpos if continuation is C_BRACKET, index of last open bracket rPNr7r/r ([{)]}r.rNrOrSrR)r2rhr1rXr0r8r9_junkre stmt_startstmt_endrY_chew_ordinaryreend_match_stringrer\lastchlastopenbracketpostuplestmt_bracketing)r r1rXrApqnothingrystack push_stack bracketingrBnewprds r _study2Parser._study2Os&   q  ))T^^i  NQ  IH1A Q3>JJtQ!,q0?   aCa 66M6A)*A&\\ !fX e !,Auuw1HfG!3!AfG!36!WF6BU{1 !!1c%j/2aCU{b aC!!1c%j/2SyB#I!!1c%jl"34#DQ/335!!1c%j/2Sy!!1c%jl"34IIdA)A-1u u!!1c%j/2: :!A5L5w$1g!A{eB /4%)$$Z0rcUR5 UR[:XdeURnURn[ U5nUR SSU5S-=pEUS-nX:aE[X!5nU(aUR5S- nSnOCURSU5S-=pQX:aMEU=pX!S;aUS-nX!S;aMURn[ X%URUR55U-$)z`Return number of spaces the next line should be indented. Line continuation must be C_BRACKET. r/rr7 ) rr_r^rzr1r0r9_itemrerwr\r) expandtabsr*)r jr1rcorigirArBextras r compute_bracket_indentParser.compute_bracket_indents   I---  # #yy IJJtQ*Q.. aCe AEEGaK $*Q..eMA'U"aC'U"$$E4!9'' 67%??rcPUR5 URnUSUS- $)zReturn number of physical lines in last stmt. The statement doesn't have to be an interesting statement. This is intended to be called when continuation is C_BACKSLASH. r.)rhrX)r rXs r get_num_lines_in_stmtParser.get_num_lines_in_stmts) NN }y},,rcUR5 UR[:XdeURnURnXS;aUS-nXS;aMUnUR SU5S-nS=pVX$:aXnUS;a US-nUS-nOvUS;aU(aUS- nUS-nO^US:XdUS:Xa[ XU5R5nO7US :XaO7US:Xa%US :XaUS:Xd XS- S ;aXS-S :waSnO US-nX$:aMU(a US-n[R"S XU5S LnU(dUnXS;aUS-nXS;aM[XRURUR55S-$)zReturn number of spaces the next line should be indented. Line continuation must be C_BACKSLASH. Also assume that the new line is the first one following the initial line of the stmt. rr7r/rrqrrrNrOrS=z=<>!z\s*\\Nrp) rr_r]r1rtr\rxrwrematchr0rr*)r r1rAstartposendposfoundr`rds r compute_backslash_indentParser.compute_backslash_indents   K///yy OOg!Ag4*Q.jBU{ aCu!AIEaCsbCi#DV488:s!c FdQ3iv5!9#aC+j. !AHHXtf~6$>EA'(aC'(4*55%)]]45789 9rcUR5 URURp!UnURnX2:aXCS;aUS-nX2:a XCS;aMXAU$)zPReturn the leading whitespace on the initial line of the last interesting stmt. rr7)rrtrur1)r rArcrr1s r get_base_indent_stringParser.get_base_indent_string,s[  1 yye5(AAe5(ayrc@UR5 URS:H$)z-79r " @ $rr&__main__)mainzidlelib.idle_test.test_pyparserP) verbosity)rrr8rWr]rZr[r^compileVERBOSE MULTILINEsearchr:rrsDOTALLrxrrrvdictrfromkeysrUupdater&runittestrr rr rs  $)8!)i ::&ZZ",,' &!'' . **ZZ   ** ZZ"))! #U!* **ZZ  :: ZZ  ::ZZ t " %*c* / // / // 2z 22K$K$\ z )Q7r