#NEWLINE# def goto( self , prec , words ) : #NEWLINE# #INDENT# 'Goes to words preceded by prec;\n        returns False and stays at eof if not found.' #NEWLINE# found = False #NEWLINE# w = '' #NEWLINE# if prec : #NEWLINE# #INDENT# target = prec #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# target = words #NEWLINE# #UNINDENT# while ( ( not self . eof ) and ( not found ) ) : #NEWLINE# #INDENT# ( found , w ) = self . checkpos ( found ) #NEWLINE# if ( not found ) : #NEWLINE# #INDENT# self . next ( ) #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# if prec : #NEWLINE# #INDENT# self . next ( ) #NEWLINE# self . skipnw ( ) #NEWLINE# ( found , w ) = self . checkpos ( words ) #NEWLINE# #UNINDENT# #UNINDENT# #UNINDENT# if found : #NEWLINE# #INDENT# self . words = w #NEWLINE# return True #NEWLINE# #UNINDENT# return False