diff options
| author | Jay Belanger | 2009-11-02 02:59:23 +0000 |
|---|---|---|
| committer | Jay Belanger | 2009-11-02 02:59:23 +0000 |
| commit | 6292c59952a47bdf315223db70e31c9e4e11fbdc (patch) | |
| tree | 1f3f5b431a714dded21d3378ee68dc2e7dd56a05 | |
| parent | 0f063651e220bcb450d760e9e365a05acf1aed30 (diff) | |
| download | emacs-6292c59952a47bdf315223db70e31c9e4e11fbdc.tar.gz emacs-6292c59952a47bdf315223db70e31c9e4e11fbdc.zip | |
(calc-date-notation): Check to see if the format is whitespace
instead of only the empty string.
| -rw-r--r-- | lisp/ChangeLog | 5 | ||||
| -rw-r--r-- | lisp/calc/calc-forms.el | 2 |
2 files changed, 6 insertions, 1 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 88b6a6ab98d..f8c718a424b 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog | |||
| @@ -1,3 +1,8 @@ | |||
| 1 | 2009-11-02 Jay Belanger <jay.p.belanger@gmail.com> | ||
| 2 | |||
| 3 | * calc/calc-forms.el (calc-date-notation): Allow a "blank string" | ||
| 4 | to be made up of whitespace. | ||
| 5 | |||
| 1 | 2009-11-02 Chong Yidong <cyd@stupidchicken.com> | 6 | 2009-11-02 Chong Yidong <cyd@stupidchicken.com> |
| 2 | 7 | ||
| 3 | * minibuffer.el (read-file-name): Don't use file dialogs for | 8 | * minibuffer.el (read-file-name): Don't use file dialogs for |
diff --git a/lisp/calc/calc-forms.el b/lisp/calc/calc-forms.el index 99a8b949c42..0845fb151ab 100644 --- a/lisp/calc/calc-forms.el +++ b/lisp/calc/calc-forms.el | |||
| @@ -81,7 +81,7 @@ | |||
| 81 | (defun calc-date-notation (fmt arg) | 81 | (defun calc-date-notation (fmt arg) |
| 82 | (interactive "sDate format (e.g., M/D/YY h:mm:ss): \nP") | 82 | (interactive "sDate format (e.g., M/D/YY h:mm:ss): \nP") |
| 83 | (calc-wrapper | 83 | (calc-wrapper |
| 84 | (if (equal fmt "") | 84 | (if (string-match-p "\\`\\s-*\\'" fmt) |
| 85 | (setq fmt "1")) | 85 | (setq fmt "1")) |
| 86 | (if (string-match "\\` *[0-9] *\\'" fmt) | 86 | (if (string-match "\\` *[0-9] *\\'" fmt) |
| 87 | (setq fmt (nth (string-to-number fmt) calc-standard-date-formats))) | 87 | (setq fmt (nth (string-to-number fmt) calc-standard-date-formats))) |