]> granicus.if.org Git - python/commitdiff
(py-comint-output-filter-function): Put the pop-to-buffer call inside
authorBarry Warsaw <barry@python.org>
Fri, 26 Apr 2002 15:49:52 +0000 (15:49 +0000)
committerBarry Warsaw <barry@python.org>
Fri, 26 Apr 2002 15:49:52 +0000 (15:49 +0000)
the `when' condition so other non-Python shell comint changes won't
cause random buffers to pop.

Misc/python-mode.el

index aed8df4d85e90ad82a40ca30c9d817c557efab06..9e78579127578bce782e4bfc04a73b55e577ef68 100644 (file)
@@ -1239,11 +1239,11 @@ comint believe the user typed this string so that
   "Watch output for Python prompt and exec next file waiting in queue.
 This function is appropriate for `comint-output-filter-functions'."
   ;; TBD: this should probably use split-string
-  (pop-to-buffer (current-buffer))
   (when (and (or (string-equal string ">>> ")
                 (and (>= (length string) 5)
                      (string-equal (substring string -5) "\n>>> ")))
             py-file-queue)
+    (pop-to-buffer (current-buffer))
     (py-safe (delete-file (car py-file-queue)))
     (setq py-file-queue (cdr py-file-queue))
     (if py-file-queue