##// END OF EJS Templates
Simplify line info code.
Fernando Perez -
Show More
@@ -118,8 +118,6 b' class LineInfo(object):'
118 118 else:
119 119 self.pre_whitespace = self.pre
120 120
121 self._oinfo = None
122
123 121 def ofind(self, ip):
124 122 """Do a full, attribute-walking lookup of the ifun in the various
125 123 namespaces for the given IPython InteractiveShell instance.
@@ -133,10 +131,7 b' class LineInfo(object):'
133 131 Does cache the results of the call, so can be called multiple times
134 132 without worrying about *further* damaging state.
135 133 """
136 if not self._oinfo:
137 # ip.shell._ofind is actually on the Magic class!
138 self._oinfo = ip._ofind(self.ifun)
139 return self._oinfo
134 return ip._ofind(self.ifun)
140 135
141 136 def __str__(self):
142 137 return "LineInfo [%s|%s|%s|%s]" %(self.pre, self.esc, self.ifun, self.the_rest)
General Comments 0
You need to be logged in to leave comments. Login now