فهرست منبع

org-babel-python: Silent bug fix.

The code worked because the unintended extra parentheses didn't cause problems.
Dan Davison 15 سال پیش
والد
کامیت
3ec02a953d
1فایلهای تغییر یافته به همراه1 افزوده شده و 1 حذف شده
  1. 1 1
      contrib/babel/lisp/langs/org-babel-python.el

+ 1 - 1
contrib/babel/lisp/langs/org-babel-python.el

@@ -161,7 +161,7 @@ last statement in BODY, as elisp."
 		    (mapconcat
 		     (lambda (line) (format "\t%s" line))
 		     (butlast lines) "\n")
-		    (format "\n\treturn %s" (last lines))))
+		    (format "\n\treturn %s" (car (last lines)))))
 		 tmp-file))
                ;; (message "buffer=%s" (buffer-string)) ;; debugging
                (shell-command-on-region (point-min) (point-max) "python"))