Message360540
Tim, idlelib.pyparse has this definition: # Find what looks like the start of a popular statement. _synchre = re.compile(r""" ^ [ \t]* (?: while | else | def | return | assert | break | class | continue | elif | try | except | raise | import | yield ) \b """, re.VERBOSE | re.MULTILINE).search You are credited with adding 'yield' to David Sherer's original list: "Taught IDLE's autoident parser that "yield" is a keyword that begins a stmt." --tim_one (found via git blame) Do you know if there is any reason to not add 'if', 'for', and now 'with'? | |
| Date | User | Action | Args | | 2020-01-23 04:30:00 | terry.reedy | set | recipients: + terry.reedy, tim.peters, cheryl.sabella, miss-islington | | 2020-01-23 04:30:00 | terry.reedy | set | messageid: <1579753800.62.0.0141210730815.issue32989@roundup.psfhosted.org> | | 2020-01-23 04:30:00 | terry.reedy | link | issue32989 messages | | 2020-01-23 04:30:00 | terry.reedy | create | | |