doc = func.__doc__
if doc.find (' ->') != -1:
print '_emacs_out', doc.split (' ->')[0]
- elif doc.find ('\n') != -1:
- print '_emacs_out', doc.split ('\n')[0]
+ elif doc.find ('\\n') != -1:
+ print '_emacs_out', doc.split ('\\n')[0]
return None
if inspect.ismethod (func): func = func.im_func
if not inspect.isfunction (func):
(set (make-local-variable 'python-orig-file) nil)
(set (make-local-variable 'python-orig-start-line) nil)
(format "\
-try:
- if globals().has_key(%S): reload(%s)
- else: import %s
-except: None
+if globals().has_key(%S): reload(%s)
+else: import %s
" module module module))
(set (make-local-variable 'python-orig-file) file-name)
(set (make-local-variable 'python-orig-start-line) 1)
(enable-recursive-minibuffers t)
val)
(setq val (read-string (if symbol
- (format "Describe variable (default %s): "
+ (format "Describe symbol (default %s): "
symbol)
"Describe symbol: ")
nil nil symbol))