[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] Changes to emacs/lisp/eshell/em-glob.el [emacs-unicode-2]
From: |
Miles Bader |
Subject: |
[Emacs-diffs] Changes to emacs/lisp/eshell/em-glob.el [emacs-unicode-2] |
Date: |
Mon, 28 Jun 2004 04:51:32 -0400 |
Index: emacs/lisp/eshell/em-glob.el
diff -c emacs/lisp/eshell/em-glob.el:1.10.4.1
emacs/lisp/eshell/em-glob.el:1.10.4.2
*** emacs/lisp/eshell/em-glob.el:1.10.4.1 Fri Apr 16 12:50:15 2004
--- emacs/lisp/eshell/em-glob.el Mon Jun 28 07:29:41 2004
***************
*** 122,131 ****
:type '(repeat (cons character (choice regexp function)))
:group 'eshell-glob)
- ;;; Internal Variables:
-
- (defvar eshell-glob-chars-regexp nil)
-
;;; Functions:
(defun eshell-glob-initialize ()
--- 122,127 ----
***************
*** 134,141 ****
(when (boundp 'eshell-special-chars-outside-quoting)
(set (make-local-variable 'eshell-special-chars-outside-quoting)
(append eshell-glob-chars-list eshell-special-chars-outside-quoting)))
- (set (make-local-variable 'eshell-glob-chars-regexp)
- (format "[%s]+" (apply 'string eshell-glob-chars-list)))
(add-hook 'eshell-parse-argument-hook 'eshell-parse-glob-chars t t)
(add-hook 'eshell-pre-rewrite-command-hook
'eshell-no-command-globbing nil t))
--- 130,135 ----
***************
*** 184,189 ****
--- 178,185 ----
(buffer-substring-no-properties (1- (point)) (1+ end))
(goto-char (1+ end))))))))))
+ (defvar eshell-glob-chars-regexp nil)
+
(defun eshell-glob-regexp (pattern)
"Convert glob-pattern PATTERN to a regular expression.
The basic syntax is:
***************
*** 204,211 ****
resulting regular expression."
(let ((matched-in-pattern 0) ; How much of PATTERN handled
regexp)
! (while (string-match eshell-glob-chars-regexp
! pattern matched-in-pattern)
(let* ((op-begin (match-beginning 0))
(op-char (aref pattern op-begin)))
(setq regexp
--- 200,210 ----
resulting regular expression."
(let ((matched-in-pattern 0) ; How much of PATTERN handled
regexp)
! (while (string-match
! (or eshell-glob-chars-regexp
! (set (make-local-variable 'eshell-glob-chars-regexp)
! (format "[%s]+" (apply 'string eshell-glob-chars-list))))
! pattern matched-in-pattern)
(let* ((op-begin (match-beginning 0))
(op-char (aref pattern op-begin)))
(setq regexp
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Emacs-diffs] Changes to emacs/lisp/eshell/em-glob.el [emacs-unicode-2],
Miles Bader <=