[Pydev-cvs] org.python.pydev/PySrc/ThirdParty/brm/bike/query common.py,1.1,1.2
Brought to you by:
fabioz
From: Fabio Z. <fa...@us...> - 2004-09-16 15:32:55
|
Update of /cvsroot/pydev/org.python.pydev/PySrc/ThirdParty/brm/bike/query In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv25869/PySrc/ThirdParty/brm/bike/query Modified Files: common.py Log Message: Making refactoring. Index: common.py =================================================================== RCS file: /cvsroot/pydev/org.python.pydev/PySrc/ThirdParty/brm/bike/query/common.py,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** common.py 14 Sep 2004 17:42:08 -0000 1.1 --- common.py 16 Sep 2004 15:32:44 -0000 1.2 *************** *** 55,59 **** if line.find(targetname) != -1: doctoredline = makeLineParseable(line) ! ast = compiler.parse(doctoredline) scope = getScopeForLine(sourcenode, lineno) matchFinder.reset(line) --- 55,63 ---- if line.find(targetname) != -1: doctoredline = makeLineParseable(line) ! try: ! ast = compiler.parse(doctoredline) ! except : ! print >> log.warning , 'Error parsing: %s' % doctoredline ! raise scope = getScopeForLine(sourcenode, lineno) matchFinder.reset(line) *************** *** 197,201 **** if word == "*": return # won't be able to find this ! posInWords = self.words.index(word) idx = self.positions[posInWords] self.words = self.words[posInWords+1:] --- 201,215 ---- if word == "*": return # won't be able to find this ! try: ! posInWords = self.words.index(word) ! except ValueError: ! print >> log.warning , 'ValueError raised (communicate to bicycle repair man plugin).' ! print >> log.warning , 'code that raised error (commom.py): posInWords = self.words.index(word)' ! try: ! print >> log.warning , 'WORD: %s'%word ! except TypeError: ! print >> log.warning , 'Unable to get word.' ! print >> log.warning , 'SELF.WORDS: %s'%self.words ! return idx = self.positions[posInWords] self.words = self.words[posInWords+1:] |