MCPcopy Index your code
hub / github.com/python/cpython / report_error

Method report_error

Lib/idlelib/searchengine.py:92–100  ·  view source on GitHub ↗
(self, pat, msg, col=None)

Source from the content-addressed store, hash-verified

90 return prog
91
92 def report_error(self, pat, msg, col=None):
93 # Derived class could override this with something fancier
94 msg = "Error: " + str(msg)
95 if pat:
96 msg = msg + "\nPattern: " + str(pat)
97 if col is not None:
98 msg = msg + "\nOffset: " + str(col)
99 messagebox.showerror("Regular expression error",
100 msg, master=self.root)
101
102 def search_text(self, text, prog=None, ok=0):
103 '''Return (lineno, matchobj) or None for forward/backward search.

Callers 3

getprogMethod · 0.95
_replace_expandMethod · 0.80
test_report_errorMethod · 0.80

Calls 2

strFunction · 0.85
showerrorMethod · 0.45

Tested by 1

test_report_errorMethod · 0.64