]> git.eshelyaron.com Git - emacs.git/commitdiff
* progmodes/tcl.el (inferior-tcl): Use pop-to-buffer.
authorJesper Harder <harder@ifa.au.dk>
Wed, 22 Sep 2004 17:31:03 +0000 (17:31 +0000)
committerJesper Harder <harder@ifa.au.dk>
Wed, 22 Sep 2004 17:31:03 +0000 (17:31 +0000)
lisp/ChangeLog
lisp/progmodes/tcl.el

index 39a2f3eb9feee1af0cbed93aba8aed871c18bd2d..3c8cbbdf1af2c8f01a4c0779edebaed134a87648 100644 (file)
@@ -1,3 +1,7 @@
+2004-09-20  Jesper Harder  <harder@ifa.au.dk>
+
+       * progmodes/tcl.el (inferior-tcl): Use pop-to-buffer.
+
 2004-09-21  Luc Teirlinck  <teirllm@auburn.edu>
 
        * subr.el (after-change-major-mode-hook): Doc fix.
index ac370cc10307ae9ebbd75d6b1faffeedaa45d9db..6965dea9fc107d0e2b6d28105f9fd9a02b2df200 100644 (file)
@@ -1,6 +1,6 @@
 ;;; tcl.el --- Tcl code editing commands for Emacs
 
-;; Copyright (C) 1994,98,1999,2000,01,02,2003  Free Software Foundation, Inc.
+;; Copyright (C) 1994,98,1999,2000,01,02,2003,2004  Free Software Foundation, Inc.
 
 ;; Maintainer: FSF
 ;; Author: Tom Tromey <tromey@redhat.com>
@@ -1104,15 +1104,13 @@ See documentation for function `inferior-tcl-mode' for more information."
    (list (if current-prefix-arg
             (read-string "Run Tcl: " tcl-application)
           tcl-application)))
-  (if (not (comint-check-proc "*inferior-tcl*"))
-      (progn
-       (set-buffer (apply (function make-comint) "inferior-tcl" cmd nil
-                          tcl-command-switches))
-       (inferior-tcl-mode)))
-  (make-local-variable 'tcl-application)
-  (setq tcl-application cmd)
+  (unless (comint-check-proc "*inferior-tcl*")
+    (set-buffer (apply (function make-comint) "inferior-tcl" cmd nil
+                      tcl-command-switches))
+    (inferior-tcl-mode))
+  (set (make-local-variable 'tcl-application) cmd)
   (setq inferior-tcl-buffer "*inferior-tcl*")
-  (switch-to-buffer "*inferior-tcl*"))
+  (pop-to-buffer "*inferior-tcl*"))
 
 (defalias 'run-tcl 'inferior-tcl)