diff options
| author | Kenichi Handa | 2012-10-07 21:58:14 +0900 |
|---|---|---|
| committer | Kenichi Handa | 2012-10-07 21:58:14 +0900 |
| commit | dade5fca51ce2ed10fdace1cfcf78287599154a1 (patch) | |
| tree | 299c84e1ce2c5a95237b41781113790626d259c5 /lisp | |
| parent | 6aa75fb62f6cdc4164d935ef14d57feec5ed6e0a (diff) | |
| parent | 78d876b90e52400b7bbb086ca1a471d3d20d0e98 (diff) | |
| download | emacs-dade5fca51ce2ed10fdace1cfcf78287599154a1.tar.gz emacs-dade5fca51ce2ed10fdace1cfcf78287599154a1.zip | |
merge trunk
Diffstat (limited to 'lisp')
49 files changed, 1427 insertions, 140 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog index bc8840819a3..b2cc65a0ca3 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog | |||
| @@ -3,6 +3,115 @@ | |||
| 3 | * international/mule-conf.el (compound-text-with-extensions): Add | 3 | * international/mule-conf.el (compound-text-with-extensions): Add |
| 4 | :mime-charset property as x-ctext. | 4 | :mime-charset property as x-ctext. |
| 5 | 5 | ||
| 6 | 2012-10-07 Stefan Merten <smerten@oekonux.de> | ||
| 7 | |||
| 8 | * textmodes/rst.el (rst-new-adornment-down, rst-indent-field) | ||
| 9 | (rst-indent-literal-normal, rst-indent-literal-minimized) | ||
| 10 | (rst-indent-comment): Correct :version tag. | ||
| 11 | |||
| 12 | 2012-10-07 Glenn Morris <rgm@gnu.org> | ||
| 13 | |||
| 14 | * mail/rmailmm.el (rmail-mime-process-multipart): | ||
| 15 | Do not confuse a multipart message with an epilogue | ||
| 16 | with a "truncated" one; fixes 2011-06-27 change. (Bug#10101) | ||
| 17 | |||
| 18 | 2012-10-07 Fabián Ezequiel Gallina <fgallina@cuca> | ||
| 19 | |||
| 20 | Fix shell output retrieval and comint-prompt-regexp init. | ||
| 21 | * progmodes/python.el (inferior-python-mode): | ||
| 22 | (python-shell-make-comint): Fix initialization of | ||
| 23 | comint-prompt-regexp from copied file local variables. | ||
| 24 | (python-shell-fetched-lines): Remove var. | ||
| 25 | (python-shell-output-filter-in-progress): Rename from | ||
| 26 | python-shell-fetch-lines-in-progress. | ||
| 27 | (python-shell-output-filter-buffer): Rename from | ||
| 28 | python-shell-fetch-lines-string. | ||
| 29 | (python-shell-fetch-lines-filter): Delete function. | ||
| 30 | (python-shell-output-filter): New function. | ||
| 31 | (python-shell-send-string-no-output): Use them. | ||
| 32 | |||
| 33 | 2012-10-07 Glenn Morris <rgm@gnu.org> | ||
| 34 | |||
| 35 | * hi-lock.el (hi-lock-process-phrase): | ||
| 36 | Try to make it less fragile. (Bug#7161) | ||
| 37 | |||
| 38 | * hi-lock.el (hi-lock-face-phrase-buffer): Doc fix. | ||
| 39 | |||
| 40 | 2012-10-06 Glenn Morris <rgm@gnu.org> | ||
| 41 | |||
| 42 | * ehelp.el (electric-help-mode): Use help-mode rather than | ||
| 43 | non-existent mode `help'. | ||
| 44 | (electric-help-map): Use button-buffer-map. (Bug#10917) | ||
| 45 | |||
| 46 | * textmodes/reftex-vars.el (reftex-create-bibtex-header) | ||
| 47 | (reftex-create-bibtex-footer): Fix custom types. | ||
| 48 | |||
| 49 | * progmodes/sh-script.el (sh-indent-after-continuation): | ||
| 50 | Add explicit :group. | ||
| 51 | |||
| 52 | * textmodes/rst.el (rst-preferred-decorations) | ||
| 53 | (rst-shift-basic-offset): Clarify obsolescence versions. | ||
| 54 | |||
| 55 | * profiler.el (profiler): Add missing group :version tag. | ||
| 56 | * avoid.el (mouse-avoidance-banish-position): | ||
| 57 | * proced.el (proced-renice-command): | ||
| 58 | * calc/calc.el (calc-ensure-consistent-units): | ||
| 59 | * calendar/icalendar.el (icalendar-import-format-uid): | ||
| 60 | * net/tramp.el (tramp-save-ad-hoc-proxies): | ||
| 61 | * progmodes/bug-reference.el (bug-reference-bug-regexp): | ||
| 62 | * progmodes/flymake.el (flymake-error-bitmap) | ||
| 63 | (flymake-warning-bitmap, flymake-fringe-indicator-position): | ||
| 64 | * progmodes/sh-script.el (sh-indent-after-continuation): | ||
| 65 | * progmodes/verilog-mode.el (verilog-auto-template-warn-unused) | ||
| 66 | (verilog-before-save-font-hook, verilog-after-save-font-hook): | ||
| 67 | * progmodes/vhdl-mode.el (vhdl-makefile-default-targets) | ||
| 68 | (vhdl-array-index-record-field-in-sensitivity-list) | ||
| 69 | (vhdl-indent-comment-like-next-code-line): | ||
| 70 | * textmodes/reftex-vars.el (reftex-ref-style-alist) | ||
| 71 | (reftex-ref-macro-prompt, reftex-ref-style-default-list) | ||
| 72 | (reftex-cite-key-separator, reftex-create-bibtex-header) | ||
| 73 | (reftex-create-bibtex-footer): | ||
| 74 | * textmodes/rst.el (rst-new-adornment-down, rst-indent-field) | ||
| 75 | (rst-indent-literal-normal, rst-indent-literal-minimized) | ||
| 76 | (rst-indent-comment): Add missing custom :version tags. | ||
| 77 | |||
| 78 | * calendar/timeclock.el (timeclock-modeline-display): | ||
| 79 | Add missing obsolete alias for renamed user option. | ||
| 80 | |||
| 81 | * strokes.el (strokes-modeline-string): | ||
| 82 | * emulation/crisp.el (crisp-mode-modeline-string): | ||
| 83 | * eshell/esh-mode.el (eshell-status-in-modeline): | ||
| 84 | Aliases to defcustoms must come before the defcustom. | ||
| 85 | |||
| 86 | * calendar/cal-tex.el (cal-tex-diary, cal-tex-cursor-week) | ||
| 87 | (cal-tex-cursor-week2, cal-tex-cursor-week-iso) | ||
| 88 | (cal-tex-cursor-week-monday): Doc fixes. | ||
| 89 | (cal-tex-cursor-week2-summary): Doc fix. | ||
| 90 | Rename from cal-tex-cursor-week-at-a-glance. | ||
| 91 | |||
| 92 | * calendar/cal-menu.el (cal-menu-context-mouse-menu): | ||
| 93 | Tweak week descriptions. Add cal-tex-cursor-week2-summary. | ||
| 94 | |||
| 95 | * calendar/calendar.el (calendar-mode-map): | ||
| 96 | Add cal-tex-cursor-week2-summary. | ||
| 97 | |||
| 98 | 2012-10-06 Stefan Monnier <monnier@iro.umontreal.ca> | ||
| 99 | |||
| 100 | * emacs-lisp/cl-macs.el (cl-defstruct): Improve docstring. | ||
| 101 | |||
| 102 | * subr.el (read-passwd-map): New var. | ||
| 103 | (read-passwd): Use `read-string' again. | ||
| 104 | * minibuffer.el (delete-minibuffer-contents): Make it interactive. | ||
| 105 | |||
| 106 | 2012-10-06 Jambunathan K <kjambunathan@gmail.com> | ||
| 107 | |||
| 108 | * register.el (append-to-register, prepend-to-register): | ||
| 109 | Deactivate mark, as does `copy-to-register' (bug#12389). | ||
| 110 | |||
| 111 | 2012-10-06 Chong Yidong <cyd@gnu.org> | ||
| 112 | |||
| 113 | * files.el (auto-mode-alist): Add .by and .wy (Semantic grammars). | ||
| 114 | |||
| 6 | 2012-10-06 Ikumi Keita <ikumi@ikumi.que.jp> (tiny change) | 115 | 2012-10-06 Ikumi Keita <ikumi@ikumi.que.jp> (tiny change) |
| 7 | 116 | ||
| 8 | * international/characters.el: Fix simple mistake ((car chars) -> | 117 | * international/characters.el: Fix simple mistake ((car chars) -> |
| @@ -69,7 +178,7 @@ | |||
| 69 | (python-fill-decorator-function, python-fill-paren-function): | 178 | (python-fill-decorator-function, python-fill-paren-function): |
| 70 | Remove :safe for defcustoms. | 179 | Remove :safe for defcustoms. |
| 71 | (python-fill-string-style): New defcustom | 180 | (python-fill-string-style): New defcustom |
| 72 | (python-fill-paragraph-function): Enhanced context detection. | 181 | (python-fill-paragraph-function): Enhance context detection. |
| 73 | (python-fill-string): Honor python-fill-string-style settings. | 182 | (python-fill-string): Honor python-fill-string-style settings. |
| 74 | 183 | ||
| 75 | 2012-10-04 Martin Rudalics <rudalics@gmx.at> | 184 | 2012-10-04 Martin Rudalics <rudalics@gmx.at> |
| @@ -101,8 +210,8 @@ | |||
| 101 | 210 | ||
| 102 | 2012-10-02 Chong Yidong <cyd@gnu.org> | 211 | 2012-10-02 Chong Yidong <cyd@gnu.org> |
| 103 | 212 | ||
| 104 | * progmodes/hideif.el (hif-lookup, hif-defined): Handle | 213 | * progmodes/hideif.el (hif-lookup, hif-defined): |
| 105 | semantic-c-takeover-hideif. | 214 | Handle semantic-c-takeover-hideif. |
| 106 | 215 | ||
| 107 | 2012-10-02 Paul Eggert <eggert@cs.ucla.edu> | 216 | 2012-10-02 Paul Eggert <eggert@cs.ucla.edu> |
| 108 | 217 | ||
| @@ -118,8 +227,8 @@ | |||
| 118 | 227 | ||
| 119 | 2012-10-02 Sergio Durigan Junior <sergiodj@riseup.net> (tiny change) | 228 | 2012-10-02 Sergio Durigan Junior <sergiodj@riseup.net> (tiny change) |
| 120 | 229 | ||
| 121 | * net/eudcb-bbdb.el (eudc-bbdb-format-record-as-result): Fix | 230 | * net/eudcb-bbdb.el (eudc-bbdb-format-record-as-result): |
| 122 | querying BBDB for entries without a last name (Bug#11580). | 231 | Fix querying BBDB for entries without a last name (Bug#11580). |
| 123 | 232 | ||
| 124 | 2012-10-02 Chong Yidong <cyd@gnu.org> | 233 | 2012-10-02 Chong Yidong <cyd@gnu.org> |
| 125 | 234 | ||
| @@ -1566,12 +1675,12 @@ | |||
| 1566 | 2012-09-08 Jambunathan K <kjambunathan@gmail.com> | 1675 | 2012-09-08 Jambunathan K <kjambunathan@gmail.com> |
| 1567 | 1676 | ||
| 1568 | * register.el (register): New group. | 1677 | * register.el (register): New group. |
| 1569 | (register-separator): New user option. | 1678 | (separator-register): New user option. |
| 1570 | (increment-register): Route it to `append-to-register', if | 1679 | (increment-register): Route it to `append-to-register', if |
| 1571 | register contains text. Implication is that `C-x r +' can now be | 1680 | register contains text. Implication is that `C-x r +' can now be |
| 1572 | used for appending to a text register (bug#12217). | 1681 | used for appending to a text register (bug#12217). |
| 1573 | (append-to-register, prepend-to-register): Add separator based on | 1682 | (append-to-register, prepend-to-register): Add separator based on |
| 1574 | `register-separator. | 1683 | `separator-register'. |
| 1575 | 1684 | ||
| 1576 | 2012-09-08 Alan Mackenzie <acm@muc.de> | 1685 | 2012-09-08 Alan Mackenzie <acm@muc.de> |
| 1577 | 1686 | ||
diff --git a/lisp/ChangeLog.15 b/lisp/ChangeLog.15 index 65a7baf44c4..83657a98bfd 100644 --- a/lisp/ChangeLog.15 +++ b/lisp/ChangeLog.15 | |||
| @@ -10962,7 +10962,7 @@ | |||
| 10962 | 10962 | ||
| 10963 | * Version 23.2 released. | 10963 | * Version 23.2 released. |
| 10964 | 10964 | ||
| 10965 | 2010-05-07 Deniz Dogan <deniz.a.m.dogan@gmail.com> (tiny change) | 10965 | 2010-05-07 Deniz Dogan <deniz.a.m.dogan@gmail.com> |
| 10966 | Stefan Monnier <monnier@iro.umontreal.ca> | 10966 | Stefan Monnier <monnier@iro.umontreal.ca> |
| 10967 | 10967 | ||
| 10968 | Highlight vendor specific properties. | 10968 | Highlight vendor specific properties. |
| @@ -15541,7 +15541,7 @@ | |||
| 15541 | * window.el (move-to-window-line-last-op): Remove. | 15541 | * window.el (move-to-window-line-last-op): Remove. |
| 15542 | (move-to-window-line-top-bottom): Reuse recenter-last-op instead. | 15542 | (move-to-window-line-top-bottom): Reuse recenter-last-op instead. |
| 15543 | 15543 | ||
| 15544 | 2009-11-23 Deniz Dogan <deniz.a.m.dogan@gmail.com> (tiny change) | 15544 | 2009-11-23 Deniz Dogan <deniz.a.m.dogan@gmail.com> |
| 15545 | 15545 | ||
| 15546 | Make M-r mirror the new cycling behavior of C-l. | 15546 | Make M-r mirror the new cycling behavior of C-l. |
| 15547 | * window.el (move-to-window-line-last-op): New var. | 15547 | * window.el (move-to-window-line-last-op): New var. |
diff --git a/lisp/avoid.el b/lisp/avoid.el index 2fa6ef39e70..7f4b78bf5e0 100644 --- a/lisp/avoid.el +++ b/lisp/avoid.el | |||
| @@ -128,6 +128,7 @@ SIDE-POS: Distance from right or left edge of frame or window. | |||
| 128 | TOP-OR-BOTTOM: banish the mouse to top or bottom of frame or window. | 128 | TOP-OR-BOTTOM: banish the mouse to top or bottom of frame or window. |
| 129 | TOP-OR-BOTTOM-POS: Distance from top or bottom edge of frame or window." | 129 | TOP-OR-BOTTOM-POS: Distance from top or bottom edge of frame or window." |
| 130 | :group 'avoid | 130 | :group 'avoid |
| 131 | :version "24.3" | ||
| 131 | :type '(alist :key-type symbol :value-type symbol) | 132 | :type '(alist :key-type symbol :value-type symbol) |
| 132 | :options '(frame-or-window side (side-pos integer) | 133 | :options '(frame-or-window side (side-pos integer) |
| 133 | top-or-bottom (top-or-bottom-pos integer))) | 134 | top-or-bottom (top-or-bottom-pos integer))) |
diff --git a/lisp/calc/calc.el b/lisp/calc/calc.el index 25f591a3945..f1643b10a76 100644 --- a/lisp/calc/calc.el +++ b/lisp/calc/calc.el | |||
| @@ -423,6 +423,7 @@ in normal mode." | |||
| 423 | "If non-nil, make sure new units are consistent with current units | 423 | "If non-nil, make sure new units are consistent with current units |
| 424 | when converting units." | 424 | when converting units." |
| 425 | :group 'calc | 425 | :group 'calc |
| 426 | :version "24.3" | ||
| 426 | :type 'boolean) | 427 | :type 'boolean) |
| 427 | 428 | ||
| 428 | (defcustom calc-undo-length | 429 | (defcustom calc-undo-length |
diff --git a/lisp/calendar/cal-menu.el b/lisp/calendar/cal-menu.el index d4546125f3e..52c82b661e8 100644 --- a/lisp/calendar/cal-menu.el +++ b/lisp/calendar/cal-menu.el | |||
| @@ -237,10 +237,11 @@ is non-nil." | |||
| 237 | ;; These did not work if called without calendar window selected. | 237 | ;; These did not work if called without calendar window selected. |
| 238 | ("Prepare LaTeX buffer" | 238 | ("Prepare LaTeX buffer" |
| 239 | ["Daily (1 page)" cal-tex-cursor-day] | 239 | ["Daily (1 page)" cal-tex-cursor-day] |
| 240 | ["Weekly (1 page)" cal-tex-cursor-week] | 240 | ["Weekly (1 page, with hours)" cal-tex-cursor-week] |
| 241 | ["Weekly (2 pages)" cal-tex-cursor-week2] | 241 | ["Weekly (2 pages, with hours)" cal-tex-cursor-week2] |
| 242 | ["Weekly (other style; 1 page)" cal-tex-cursor-week-iso] | 242 | ["Weekly (1 page, no hours)" cal-tex-cursor-week-iso] |
| 243 | ["Weekly (yet another style; 1 page)" cal-tex-cursor-week-monday] | 243 | ["Weekly (1 page, with hours, different style)" cal-tex-cursor-week-monday] |
| 244 | ["Weekly (2 pages, no hours)" cal-tex-cursor-week2-summary] | ||
| 244 | ["Monthly" cal-tex-cursor-month] | 245 | ["Monthly" cal-tex-cursor-month] |
| 245 | ["Monthly (landscape)" cal-tex-cursor-month-landscape] | 246 | ["Monthly (landscape)" cal-tex-cursor-month-landscape] |
| 246 | ["Yearly" cal-tex-cursor-year] | 247 | ["Yearly" cal-tex-cursor-year] |
diff --git a/lisp/calendar/cal-tex.el b/lisp/calendar/cal-tex.el index 325ac3e8146..e4c2765940a 100644 --- a/lisp/calendar/cal-tex.el +++ b/lisp/calendar/cal-tex.el | |||
| @@ -37,6 +37,7 @@ | |||
| 37 | ;; cal-tex-cursor-month | 37 | ;; cal-tex-cursor-month |
| 38 | ;; cal-tex-cursor-week | 38 | ;; cal-tex-cursor-week |
| 39 | ;; cal-tex-cursor-week2 | 39 | ;; cal-tex-cursor-week2 |
| 40 | ;; cal-tex-cursor-week2-summary | ||
| 40 | ;; cal-tex-cursor-week-iso | 41 | ;; cal-tex-cursor-week-iso |
| 41 | ;; cal-tex-cursor-week-monday | 42 | ;; cal-tex-cursor-week-monday |
| 42 | ;; cal-tex-cursor-filofax-2week | 43 | ;; cal-tex-cursor-filofax-2week |
| @@ -82,8 +83,6 @@ Setting this to nil may speed up calendar generation." | |||
| 82 | 83 | ||
| 83 | (defcustom cal-tex-diary nil | 84 | (defcustom cal-tex-diary nil |
| 84 | "Non-nil means diary entries are printed in LaTeX calendars that support it. | 85 | "Non-nil means diary entries are printed in LaTeX calendars that support it. |
| 85 | At present, this only affects the monthly, filofax, and iso-week | ||
| 86 | calendars (i.e. not the yearly, plain weekly, or daily calendars). | ||
| 87 | Setting this to nil may speed up calendar generation." | 86 | Setting this to nil may speed up calendar generation." |
| 88 | :type 'boolean | 87 | :type 'boolean |
| 89 | :group 'calendar-tex) | 88 | :group 'calendar-tex) |
| @@ -717,11 +716,15 @@ this is only an upper bound." | |||
| 717 | ;; TODO respect cal-tex-daily-start,end (see cal-tex-week-hours). | 716 | ;; TODO respect cal-tex-daily-start,end (see cal-tex-week-hours). |
| 718 | ;;;###cal-autoload | 717 | ;;;###cal-autoload |
| 719 | (defun cal-tex-cursor-week (&optional n event) | 718 | (defun cal-tex-cursor-week (&optional n event) |
| 720 | "Make a LaTeX calendar buffer for a two-page one-week calendar. | 719 | "Make a one page LaTeX calendar for one week, showing hours of the day. |
| 721 | It applies to the week that point is in. The optional prefix | 720 | There are two columns; with 8-12am in the first and 1-5pm in the second. |
| 722 | argument N specifies number of weeks (default 1). The calendar | 721 | It shows holidays if `cal-tex-holidays' is non-nil. |
| 723 | shows holidays if `cal-tex-holidays' is non-nil (note that diary | 722 | It does not show diary entries. |
| 724 | entries are not shown). The calendar shows the hours 8-12am, 1-5pm." | 723 | |
| 724 | The optional prefix argument N specifies a number of weeks (default 1). | ||
| 725 | |||
| 726 | By default, the calendar is for the week at point; the optional | ||
| 727 | argument EVENT specifies a different buffer position." | ||
| 725 | (interactive (list (prefix-numeric-value current-prefix-arg) | 728 | (interactive (list (prefix-numeric-value current-prefix-arg) |
| 726 | last-nonmenu-event)) | 729 | last-nonmenu-event)) |
| 727 | (or n (setq n 1)) | 730 | (or n (setq n 1)) |
| @@ -768,12 +771,15 @@ entries are not shown). The calendar shows the hours 8-12am, 1-5pm." | |||
| 768 | ;; TODO respect cal-tex-daily-start,end (see cal-tex-week-hours). | 771 | ;; TODO respect cal-tex-daily-start,end (see cal-tex-week-hours). |
| 769 | ;;;###cal-autoload | 772 | ;;;###cal-autoload |
| 770 | (defun cal-tex-cursor-week2 (&optional n event) | 773 | (defun cal-tex-cursor-week2 (&optional n event) |
| 771 | "Make a LaTeX calendar buffer for a two-page one-week calendar. | 774 | "Make a two page LaTeX calendar for one week, showing hours of the day. |
| 772 | It applies to the week that point is in. Optional prefix | 775 | There are two columns; with 8-12am in the first and 1-5pm in the second. |
| 773 | argument N specifies number of weeks (default 1). The calendar | 776 | It shows holidays if `cal-tex-holidays' is non-nil. |
| 774 | shows holidays if `cal-tex-holidays' is non-nil (note that diary | 777 | It does not show diary entries. |
| 775 | entries are not shown). The calendar shows the hours 8-12am, 1-5pm. | 778 | |
| 776 | Optional EVENT indicates a buffer position to use instead of point." | 779 | The optional prefix argument N specifies a number of weeks (default 1). |
| 780 | |||
| 781 | By default, the calendar is for the week at point; the optional | ||
| 782 | argument EVENT specifies a different buffer position." | ||
| 777 | (interactive (list (prefix-numeric-value current-prefix-arg) | 783 | (interactive (list (prefix-numeric-value current-prefix-arg) |
| 778 | last-nonmenu-event)) | 784 | last-nonmenu-event)) |
| 779 | (or n (setq n 1)) | 785 | (or n (setq n 1)) |
| @@ -848,12 +854,15 @@ Optional EVENT indicates a buffer position to use instead of point." | |||
| 848 | 854 | ||
| 849 | ;;;###cal-autoload | 855 | ;;;###cal-autoload |
| 850 | (defun cal-tex-cursor-week-iso (&optional n event) | 856 | (defun cal-tex-cursor-week-iso (&optional n event) |
| 851 | "Make a LaTeX calendar buffer for a one page ISO-style weekly calendar. | 857 | "Make a one page LaTeX calendar for one week, in the ISO-style. |
| 852 | Optional prefix argument N specifies number of weeks (default 1). | 858 | It does not show hours of the day. |
| 853 | The calendar shows holiday and diary entries if | 859 | It shows holidays if `cal-tex-holidays' is non-nil. |
| 854 | `cal-tex-holidays' and `cal-tex-diary', respectively, are non-nil. | 860 | It shows diary entries if `cal-tex-diary' is non-nil. |
| 855 | It does not show hours of the day. Optional EVENT indicates a buffer | 861 | |
| 856 | position to use instead of point." | 862 | The optional prefix argument N specifies a number of weeks (default 1). |
| 863 | |||
| 864 | By default, the calendar is for the week at point; the optional | ||
| 865 | argument EVENT specifies a different buffer position." | ||
| 857 | (interactive (list (prefix-numeric-value current-prefix-arg) | 866 | (interactive (list (prefix-numeric-value current-prefix-arg) |
| 858 | last-nonmenu-event)) | 867 | last-nonmenu-event)) |
| 859 | (or n (setq n 1)) | 868 | (or n (setq n 1)) |
| @@ -976,13 +985,16 @@ shown are hard-coded to 8-12, 13-17." | |||
| 976 | ;; TODO respect cal-tex-daily-start,end (see cal-tex-weekly4-box). | 985 | ;; TODO respect cal-tex-daily-start,end (see cal-tex-weekly4-box). |
| 977 | ;;;###cal-autoload | 986 | ;;;###cal-autoload |
| 978 | (defun cal-tex-cursor-week-monday (&optional n event) | 987 | (defun cal-tex-cursor-week-monday (&optional n event) |
| 979 | "Make a LaTeX calendar buffer for a two-page one-week calendar. | 988 | "Make a one page LaTeX calendar for one week, showing hours of the day. |
| 980 | It applies to the week that point is in, and starts on Monday. | 989 | There are two columns; with M-W in the first and T-S in the second. |
| 981 | Optional prefix argument N specifies number of weeks (default 1). | 990 | It shows the hours 8-12am and 1-5pm. |
| 982 | The calendar shows holidays if `cal-tex-holidays' is | 991 | It shows holidays if `cal-tex-holidays' is non-nil. |
| 983 | non-nil (note that diary entries are not shown). The calendar shows | 992 | It does not show diary entries. |
| 984 | the hours 8-12am, 1-5pm. Optional EVENT indicates a buffer position | 993 | |
| 985 | to use instead of point." | 994 | The optional prefix argument N specifies a number of weeks (default 1). |
| 995 | |||
| 996 | By default, the calendar is for the week at point; the optional | ||
| 997 | argument EVENT specifies a different buffer position." | ||
| 986 | (interactive (list (prefix-numeric-value current-prefix-arg) | 998 | (interactive (list (prefix-numeric-value current-prefix-arg) |
| 987 | last-nonmenu-event)) | 999 | last-nonmenu-event)) |
| 988 | (or n (setq n 1)) | 1000 | (or n (setq n 1)) |
| @@ -1203,13 +1215,16 @@ shown are hard-coded to 8-12, 13-17." | |||
| 1203 | (run-hooks 'cal-tex-hook))) | 1215 | (run-hooks 'cal-tex-hook))) |
| 1204 | 1216 | ||
| 1205 | ;;;###cal-autoload | 1217 | ;;;###cal-autoload |
| 1206 | (defun cal-tex-cursor-week-at-a-glance (&optional n event) | 1218 | (defun cal-tex-cursor-week2-summary (&optional n event) |
| 1207 | "One-week-at-a-glance full page calendar for week indicated by cursor. | 1219 | "Make a two page LaTeX calendar for one week, with optional diary entries. |
| 1208 | Optional prefix argument N specifies number of weeks (default 1), | 1220 | It does not show hours of the day. |
| 1209 | starting on Mondays. The calendar shows holiday and diary entries | 1221 | It shows holidays if `cal-tex-holidays' is non-nil. |
| 1210 | if `cal-tex-holidays' and `cal-tex-diary', respectively, are non-nil. | 1222 | It shows diary entries if `cal-tex-diary' is non-nil. |
| 1211 | It does not show hours of the day. Optional EVENT indicates a buffer | 1223 | |
| 1212 | position to use instead of point." | 1224 | The optional prefix argument N specifies a number of weeks (default 1). |
| 1225 | |||
| 1226 | By default, the calendar is for the week at point; the optional | ||
| 1227 | argument EVENT specifies a different buffer position." | ||
| 1213 | (interactive (list (prefix-numeric-value current-prefix-arg) | 1228 | (interactive (list (prefix-numeric-value current-prefix-arg) |
| 1214 | last-nonmenu-event)) | 1229 | last-nonmenu-event)) |
| 1215 | (cal-tex-weekly-common n event)) | 1230 | (cal-tex-weekly-common n event)) |
diff --git a/lisp/calendar/calendar.el b/lisp/calendar/calendar.el index 6f8311f4c55..96a5725ef69 100644 --- a/lisp/calendar/calendar.el +++ b/lisp/calendar/calendar.el | |||
| @@ -1683,8 +1683,9 @@ line." | |||
| 1683 | (define-key map "td" 'cal-tex-cursor-day) | 1683 | (define-key map "td" 'cal-tex-cursor-day) |
| 1684 | (define-key map "tw1" 'cal-tex-cursor-week) | 1684 | (define-key map "tw1" 'cal-tex-cursor-week) |
| 1685 | (define-key map "tw2" 'cal-tex-cursor-week2) | 1685 | (define-key map "tw2" 'cal-tex-cursor-week2) |
| 1686 | (define-key map "tw3" 'cal-tex-cursor-week-iso) | 1686 | (define-key map "tw3" 'cal-tex-cursor-week-iso) ; FIXME twi ? |
| 1687 | (define-key map "tw4" 'cal-tex-cursor-week-monday) | 1687 | (define-key map "tw4" 'cal-tex-cursor-week-monday) ; twm ? |
| 1688 | (define-key map "twW" 'cal-tex-cursor-week2-summary) | ||
| 1688 | (define-key map "tfd" 'cal-tex-cursor-filofax-daily) | 1689 | (define-key map "tfd" 'cal-tex-cursor-filofax-daily) |
| 1689 | (define-key map "tfw" 'cal-tex-cursor-filofax-2week) | 1690 | (define-key map "tfw" 'cal-tex-cursor-filofax-2week) |
| 1690 | (define-key map "tfW" 'cal-tex-cursor-filofax-week) | 1691 | (define-key map "tfW" 'cal-tex-cursor-filofax-week) |
diff --git a/lisp/calendar/icalendar.el b/lisp/calendar/icalendar.el index 39b83d4c831..27e7261263e 100644 --- a/lisp/calendar/icalendar.el +++ b/lisp/calendar/icalendar.el | |||
| @@ -186,6 +186,7 @@ the URL." | |||
| 186 | This applies only if the UID is not empty! `%s' is replaced by | 186 | This applies only if the UID is not empty! `%s' is replaced by |
| 187 | the UID." | 187 | the UID." |
| 188 | :type 'string | 188 | :type 'string |
| 189 | :version "24.3" | ||
| 189 | :group 'icalendar) | 190 | :group 'icalendar) |
| 190 | 191 | ||
| 191 | (defcustom icalendar-import-format-status | 192 | (defcustom icalendar-import-format-status |
diff --git a/lisp/calendar/timeclock.el b/lisp/calendar/timeclock.el index 3151ce145de..7e7a737549f 100644 --- a/lisp/calendar/timeclock.el +++ b/lisp/calendar/timeclock.el | |||
| @@ -321,6 +321,9 @@ display (non-nil means on)." | |||
| 321 | (force-mode-line-update) | 321 | (force-mode-line-update) |
| 322 | (setq timeclock-mode-line-display on-p))) | 322 | (setq timeclock-mode-line-display on-p))) |
| 323 | 323 | ||
| 324 | (define-obsolete-variable-alias 'timeclock-modeline-display | ||
| 325 | 'timeclock-mode-line-display "24.3") | ||
| 326 | |||
| 324 | ;; This has to be here so that the function definition of | 327 | ;; This has to be here so that the function definition of |
| 325 | ;; `timeclock-mode-line-display' is known to the "set" function. | 328 | ;; `timeclock-mode-line-display' is known to the "set" function. |
| 326 | (defcustom timeclock-mode-line-display nil | 329 | (defcustom timeclock-mode-line-display nil |
diff --git a/lisp/cedet/ChangeLog b/lisp/cedet/ChangeLog index e066368d011..ff5b603833d 100644 --- a/lisp/cedet/ChangeLog +++ b/lisp/cedet/ChangeLog | |||
| @@ -1,3 +1,18 @@ | |||
| 1 | 2012-10-06 Glenn Morris <rgm@gnu.org> | ||
| 2 | |||
| 3 | * semantic/complete.el (semantic-displayor-tooltip-max-tags): Doc fix. | ||
| 4 | |||
| 5 | * semantic/complete.el (semantic-displayor-tooltip-mode) | ||
| 6 | (semantic-displayor-tooltip-initial-max-tags) | ||
| 7 | (semantic-displayor-tooltip-max-tags): Add missing custom :version tags. | ||
| 8 | * ede/linux.el (project-linux): Add missing group :version tag. | ||
| 9 | |||
| 10 | 2012-10-06 Chong Yidong <cyd@gnu.org> | ||
| 11 | |||
| 12 | * semantic/bovine/grammar.el: | ||
| 13 | * semantic/wisent/grammar.el: Move from admin/grammars. Add | ||
| 14 | autoloads for bovine-grammar-mode and wisent-grammar-mode. | ||
| 15 | |||
| 1 | 2012-10-02 Chong Yidong <cyd@gnu.org> | 16 | 2012-10-02 Chong Yidong <cyd@gnu.org> |
| 2 | 17 | ||
| 3 | * srecode.el, ede.el: Restore Version header. | 18 | * srecode.el, ede.el: Restore Version header. |
diff --git a/lisp/cedet/ede/linux.el b/lisp/cedet/ede/linux.el index 7cd066f8b3b..5c708039ec4 100644 --- a/lisp/cedet/ede/linux.el +++ b/lisp/cedet/ede/linux.el | |||
| @@ -44,7 +44,7 @@ | |||
| 44 | "File and tag browser frame." | 44 | "File and tag browser frame." |
| 45 | :group 'tools | 45 | :group 'tools |
| 46 | :group 'ede | 46 | :group 'ede |
| 47 | ) | 47 | :version "24.3") |
| 48 | 48 | ||
| 49 | (defcustom project-linux-compile-target-command (concat ede-make-command " -k -C %s SUBDIRS=%s") | 49 | (defcustom project-linux-compile-target-command (concat ede-make-command " -k -C %s SUBDIRS=%s") |
| 50 | "*Default command used to compile a target." | 50 | "*Default command used to compile a target." |
diff --git a/lisp/cedet/semantic/bovine/grammar.el b/lisp/cedet/semantic/bovine/grammar.el new file mode 100644 index 00000000000..cc27c5b0646 --- /dev/null +++ b/lisp/cedet/semantic/bovine/grammar.el | |||
| @@ -0,0 +1,506 @@ | |||
| 1 | ;;; semantic/bovine/grammar.el --- Bovine's input grammar mode | ||
| 2 | ;; | ||
| 3 | ;; Copyright (C) 2002-2012 Free Software Foundation, Inc. | ||
| 4 | ;; | ||
| 5 | ;; Author: David Ponce <david@dponce.com> | ||
| 6 | ;; Maintainer: David Ponce <david@dponce.com> | ||
| 7 | ;; Created: 26 Aug 2002 | ||
| 8 | ;; Keywords: syntax | ||
| 9 | |||
| 10 | ;; This file is part of GNU Emacs. | ||
| 11 | |||
| 12 | ;; GNU Emacs is free software: you can redistribute it and/or modify | ||
| 13 | ;; it under the terms of the GNU General Public License as published by | ||
| 14 | ;; the Free Software Foundation, either version 3 of the License, or | ||
| 15 | ;; (at your option) any later version. | ||
| 16 | |||
| 17 | ;; GNU Emacs is distributed in the hope that it will be useful, | ||
| 18 | ;; but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
| 19 | ;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
| 20 | ;; GNU General Public License for more details. | ||
| 21 | |||
| 22 | ;; You should have received a copy of the GNU General Public License | ||
| 23 | ;; along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. | ||
| 24 | |||
| 25 | ;;; Commentary: | ||
| 26 | ;; | ||
| 27 | ;; Major mode for editing Bovine's input grammar (.by) files. | ||
| 28 | |||
| 29 | ;;; History: | ||
| 30 | |||
| 31 | ;;; Code: | ||
| 32 | (require 'semantic) | ||
| 33 | (require 'semantic/grammar) | ||
| 34 | (require 'semantic/find) | ||
| 35 | (require 'semantic/lex) | ||
| 36 | (require 'semantic/wisent) | ||
| 37 | (require 'semantic/bovine) | ||
| 38 | |||
| 39 | (defun bovine-grammar-EXPAND (bounds nonterm) | ||
| 40 | "Expand call to EXPAND grammar macro. | ||
| 41 | Return the form to parse from within a nonterminal between BOUNDS. | ||
| 42 | NONTERM is the nonterminal symbol to start with." | ||
| 43 | `(semantic-bovinate-from-nonterminal | ||
| 44 | (car ,bounds) (cdr ,bounds) ',nonterm)) | ||
| 45 | |||
| 46 | (defun bovine-grammar-EXPANDFULL (bounds nonterm) | ||
| 47 | "Expand call to EXPANDFULL grammar macro. | ||
| 48 | Return the form to recursively parse the area between BOUNDS. | ||
| 49 | NONTERM is the nonterminal symbol to start with." | ||
| 50 | `(semantic-parse-region | ||
| 51 | (car ,bounds) (cdr ,bounds) ',nonterm 1)) | ||
| 52 | |||
| 53 | (defun bovine-grammar-TAG (name class &rest attributes) | ||
| 54 | "Expand call to TAG grammar macro. | ||
| 55 | Return the form to create a generic semantic tag. | ||
| 56 | See the function `semantic-tag' for the meaning of arguments NAME, | ||
| 57 | CLASS and ATTRIBUTES." | ||
| 58 | `(semantic-tag ,name ,class ,@attributes)) | ||
| 59 | |||
| 60 | (defun bovine-grammar-VARIABLE-TAG (name type default-value &rest attributes) | ||
| 61 | "Expand call to VARIABLE-TAG grammar macro. | ||
| 62 | Return the form to create a semantic tag of class variable. | ||
| 63 | See the function `semantic-tag-new-variable' for the meaning of | ||
| 64 | arguments NAME, TYPE, DEFAULT-VALUE and ATTRIBUTES." | ||
| 65 | `(semantic-tag-new-variable ,name ,type ,default-value ,@attributes)) | ||
| 66 | |||
| 67 | (defun bovine-grammar-FUNCTION-TAG (name type arg-list &rest attributes) | ||
| 68 | "Expand call to FUNCTION-TAG grammar macro. | ||
| 69 | Return the form to create a semantic tag of class function. | ||
| 70 | See the function `semantic-tag-new-function' for the meaning of | ||
| 71 | arguments NAME, TYPE, ARG-LIST and ATTRIBUTES." | ||
| 72 | `(semantic-tag-new-function ,name ,type ,arg-list ,@attributes)) | ||
| 73 | |||
| 74 | (defun bovine-grammar-TYPE-TAG (name type members parents &rest attributes) | ||
| 75 | "Expand call to TYPE-TAG grammar macro. | ||
| 76 | Return the form to create a semantic tag of class type. | ||
| 77 | See the function `semantic-tag-new-type' for the meaning of arguments | ||
| 78 | NAME, TYPE, MEMBERS, PARENTS and ATTRIBUTES." | ||
| 79 | `(semantic-tag-new-type ,name ,type ,members ,parents ,@attributes)) | ||
| 80 | |||
| 81 | (defun bovine-grammar-INCLUDE-TAG (name system-flag &rest attributes) | ||
| 82 | "Expand call to INCLUDE-TAG grammar macro. | ||
| 83 | Return the form to create a semantic tag of class include. | ||
| 84 | See the function `semantic-tag-new-include' for the meaning of | ||
| 85 | arguments NAME, SYSTEM-FLAG and ATTRIBUTES." | ||
| 86 | `(semantic-tag-new-include ,name ,system-flag ,@attributes)) | ||
| 87 | |||
| 88 | (defun bovine-grammar-PACKAGE-TAG (name detail &rest attributes) | ||
| 89 | "Expand call to PACKAGE-TAG grammar macro. | ||
| 90 | Return the form to create a semantic tag of class package. | ||
| 91 | See the function `semantic-tag-new-package' for the meaning of | ||
| 92 | arguments NAME, DETAIL and ATTRIBUTES." | ||
| 93 | `(semantic-tag-new-package ,name ,detail ,@attributes)) | ||
| 94 | |||
| 95 | (defun bovine-grammar-CODE-TAG (name detail &rest attributes) | ||
| 96 | "Expand call to CODE-TAG grammar macro. | ||
| 97 | Return the form to create a semantic tag of class code. | ||
| 98 | See the function `semantic-tag-new-code' for the meaning of arguments | ||
| 99 | NAME, DETAIL and ATTRIBUTES." | ||
| 100 | `(semantic-tag-new-code ,name ,detail ,@attributes)) | ||
| 101 | |||
| 102 | (defun bovine-grammar-ALIAS-TAG (name aliasclass definition &rest attributes) | ||
| 103 | "Expand call to ALIAS-TAG grammar macro. | ||
| 104 | Return the form to create a semantic tag of class alias. | ||
| 105 | See the function `semantic-tag-new-alias' for the meaning of arguments | ||
| 106 | NAME, ALIASCLASS, DEFINITION and ATTRIBUTES." | ||
| 107 | `(semantic-tag-new-alias ,name ,aliasclass ,definition ,@attributes)) | ||
| 108 | |||
| 109 | ;; Cache of macro definitions currently in use. | ||
| 110 | (defvar bovine--grammar-macros nil) | ||
| 111 | |||
| 112 | (defun bovine-grammar-expand-form (form quotemode &optional inplace) | ||
| 113 | "Expand FORM into a new one suitable to the bovine parser. | ||
| 114 | FORM is a list in which we are substituting. | ||
| 115 | Argument QUOTEMODE is non-nil if we are in backquote mode. | ||
| 116 | When non-nil, optional argument INPLACE indicates that FORM is being | ||
| 117 | expanded from elsewhere." | ||
| 118 | (when (eq (car form) 'quote) | ||
| 119 | (setq form (cdr form)) | ||
| 120 | (cond | ||
| 121 | ((and (= (length form) 1) (listp (car form))) | ||
| 122 | (insert "\n(append") | ||
| 123 | (bovine-grammar-expand-form (car form) quotemode nil) | ||
| 124 | (insert ")") | ||
| 125 | (setq form nil inplace nil) | ||
| 126 | ) | ||
| 127 | ((and (= (length form) 1) (symbolp (car form))) | ||
| 128 | (insert "\n'" (symbol-name (car form))) | ||
| 129 | (setq form nil inplace nil) | ||
| 130 | ) | ||
| 131 | (t | ||
| 132 | (insert "\n(list") | ||
| 133 | (setq inplace t) | ||
| 134 | ))) | ||
| 135 | (let ((macro (assq (car form) bovine--grammar-macros)) | ||
| 136 | inlist first n q x) | ||
| 137 | (if macro | ||
| 138 | (bovine-grammar-expand-form | ||
| 139 | (apply (cdr macro) (cdr form)) | ||
| 140 | quotemode t) | ||
| 141 | (if inplace (insert "\n(")) | ||
| 142 | (while form | ||
| 143 | (setq first (car form) | ||
| 144 | form (cdr form)) | ||
| 145 | ;; Hack for dealing with new reading of unquotes outside of | ||
| 146 | ;; backquote (introduced in 2010-12-06T16:37:26Z!monnier@iro.umontreal.ca). | ||
| 147 | (when (and (>= emacs-major-version 24) | ||
| 148 | (listp first) | ||
| 149 | (or (equal (car first) '\,) | ||
| 150 | (equal (car first) '\,@))) | ||
| 151 | (if (listp (cadr first)) | ||
| 152 | (setq form (append (cdr first) form) | ||
| 153 | first (car first)) | ||
| 154 | (setq first (intern (concat (symbol-name (car first)) | ||
| 155 | (symbol-name (cadr first))))))) | ||
| 156 | (cond | ||
| 157 | ((eq first nil) | ||
| 158 | (when (and (not inlist) (not inplace)) | ||
| 159 | (insert "\n(list") | ||
| 160 | (setq inlist t)) | ||
| 161 | (insert " nil") | ||
| 162 | ) | ||
| 163 | ((listp first) | ||
| 164 | ;;(let ((fn (and (symbolp (caar form)) (fboundp (caar form))))) | ||
| 165 | (when (and (not inlist) (not inplace)) | ||
| 166 | (insert "\n(list") | ||
| 167 | (setq inlist t)) | ||
| 168 | ;;(if (and inplace (not fn) (not (eq (caar form) 'EXPAND))) | ||
| 169 | ;; (insert " (append")) | ||
| 170 | (bovine-grammar-expand-form | ||
| 171 | first quotemode t) ;;(and fn (not (eq fn 'quote)))) | ||
| 172 | ;;(if (and inplace (not fn) (not (eq (caar form) 'EXPAND))) | ||
| 173 | ;; (insert ")")) | ||
| 174 | ;;) | ||
| 175 | ) | ||
| 176 | ((symbolp first) | ||
| 177 | (setq n (symbol-name first) ;the name | ||
| 178 | q quotemode ;implied quote flag | ||
| 179 | x nil) ;expand flag | ||
| 180 | (if (eq (aref n 0) ?,) | ||
| 181 | (if quotemode | ||
| 182 | ;; backquote mode needs the @ | ||
| 183 | (if (eq (aref n 1) ?@) | ||
| 184 | (setq n (substring n 2) | ||
| 185 | q nil | ||
| 186 | x t) | ||
| 187 | ;; non backquote mode behaves normally. | ||
| 188 | (setq n (substring n 1) | ||
| 189 | q nil)) | ||
| 190 | (setq n (substring n 1) | ||
| 191 | x t))) | ||
| 192 | (if (string= n "") | ||
| 193 | (progn | ||
| 194 | ;; We expand only the next item in place (a list?) | ||
| 195 | ;; A regular inline-list... | ||
| 196 | (bovine-grammar-expand-form (car form) quotemode t) | ||
| 197 | (setq form (cdr form))) | ||
| 198 | (if (and (eq (aref n 0) ?$) | ||
| 199 | ;; Don't expand $ tokens in implied quote mode. | ||
| 200 | ;; This acts like quoting in other symbols. | ||
| 201 | (not q)) | ||
| 202 | (progn | ||
| 203 | (cond | ||
| 204 | ((and (not x) (not inlist) (not inplace)) | ||
| 205 | (insert "\n(list")) | ||
| 206 | ((and x inlist (not inplace)) | ||
| 207 | (insert ")") | ||
| 208 | (setq inlist nil))) | ||
| 209 | (insert "\n(nth " (int-to-string | ||
| 210 | (1- (string-to-number | ||
| 211 | (substring n 1)))) | ||
| 212 | " vals)") | ||
| 213 | (and (not x) (not inplace) | ||
| 214 | (setq inlist t))) | ||
| 215 | |||
| 216 | (when (and (not inlist) (not inplace)) | ||
| 217 | (insert "\n(list") | ||
| 218 | (setq inlist t)) | ||
| 219 | (or (char-equal (char-before) ?\() | ||
| 220 | (insert " ")) | ||
| 221 | (insert (if (or inplace (eq first t)) | ||
| 222 | "" "'") | ||
| 223 | n))) ;; " " | ||
| 224 | ) | ||
| 225 | (t | ||
| 226 | (when (and (not inlist) (not inplace)) | ||
| 227 | (insert "\n(list") | ||
| 228 | (setq inlist t)) | ||
| 229 | (insert (format "\n%S" first)) | ||
| 230 | ) | ||
| 231 | )) | ||
| 232 | (if inlist (insert ")")) | ||
| 233 | (if inplace (insert ")"))) | ||
| 234 | )) | ||
| 235 | |||
| 236 | (defun bovine-grammar-expand-action (textform quotemode) | ||
| 237 | "Expand semantic action string TEXTFORM into Lisp code. | ||
| 238 | QUOTEMODE is the mode in which quoted symbols are slurred." | ||
| 239 | (if (string= "" textform) | ||
| 240 | nil | ||
| 241 | (let ((sexp (read textform))) | ||
| 242 | ;; We converted the lambda string into a list. Now write it | ||
| 243 | ;; out as the bovine lambda expression, and do macro-like | ||
| 244 | ;; conversion upon it. | ||
| 245 | (insert "\n") | ||
| 246 | (cond | ||
| 247 | ((eq (car sexp) 'EXPAND) | ||
| 248 | (insert ",(lambda (vals start end)") | ||
| 249 | ;; The EXPAND macro definition is mandatory | ||
| 250 | (bovine-grammar-expand-form | ||
| 251 | (apply (cdr (assq 'EXPAND bovine--grammar-macros)) (cdr sexp)) | ||
| 252 | quotemode t) | ||
| 253 | ) | ||
| 254 | ((and (listp (car sexp)) (eq (caar sexp) 'EVAL)) | ||
| 255 | ;; The user wants to evaluate the following args. | ||
| 256 | ;; Use a simpler expander | ||
| 257 | ) | ||
| 258 | (t | ||
| 259 | (insert ",(semantic-lambda") | ||
| 260 | (bovine-grammar-expand-form sexp quotemode) | ||
| 261 | )) | ||
| 262 | (insert ")\n"))) | ||
| 263 | ) | ||
| 264 | |||
| 265 | (defun bovine-grammar-parsetable-builder () | ||
| 266 | "Return the parser table expression as a string value. | ||
| 267 | The format of a bovine parser table is: | ||
| 268 | |||
| 269 | ( ( NONTERMINAL-SYMBOL1 MATCH-LIST1 ) | ||
| 270 | ( NONTERMINAL-SYMBOL2 MATCH-LIST2 ) | ||
| 271 | ... | ||
| 272 | ( NONTERMINAL-SYMBOLn MATCH-LISTn ) | ||
| 273 | |||
| 274 | Where each NONTERMINAL-SYMBOL is an artificial symbol which can appear | ||
| 275 | in any child state. As a starting place, one of the NONTERMINAL-SYMBOLS | ||
| 276 | must be `bovine-toplevel'. | ||
| 277 | |||
| 278 | A MATCH-LIST is a list of possible matches of the form: | ||
| 279 | |||
| 280 | ( STATE-LIST1 | ||
| 281 | STATE-LIST2 | ||
| 282 | ... | ||
| 283 | STATE-LISTN ) | ||
| 284 | |||
| 285 | where STATE-LIST is of the form: | ||
| 286 | ( TYPE1 [ \"VALUE1\" ] TYPE2 [ \"VALUE2\" ] ... LAMBDA ) | ||
| 287 | |||
| 288 | where TYPE is one of the returned types of the token stream. | ||
| 289 | VALUE is a value, or range of values to match against. For | ||
| 290 | example, a SYMBOL might need to match \"foo\". Some TYPES will not | ||
| 291 | have matching criteria. | ||
| 292 | |||
| 293 | LAMBDA is a lambda expression which is evalled with the text of the | ||
| 294 | type when it is found. It is passed the list of all buffer text | ||
| 295 | elements found since the last lambda expression. It should return a | ||
| 296 | semantic element (see below.) | ||
| 297 | |||
| 298 | For consistency between languages, try to use common return values | ||
| 299 | from your parser. Please reference the chapter \"Writing Parsers\" in | ||
| 300 | the \"Language Support Developer's Guide -\" in the semantic texinfo | ||
| 301 | manual." | ||
| 302 | (let* ((start (semantic-grammar-start)) | ||
| 303 | (scopestart (semantic-grammar-scopestart)) | ||
| 304 | (quotemode (semantic-grammar-quotemode)) | ||
| 305 | (tags (semantic-find-tags-by-class | ||
| 306 | 'token (current-buffer))) | ||
| 307 | (nterms (semantic-find-tags-by-class | ||
| 308 | 'nonterminal (current-buffer))) | ||
| 309 | ;; Setup the cache of macro definitions. | ||
| 310 | (bovine--grammar-macros (semantic-grammar-macros)) | ||
| 311 | nterm rules items item actn prec tag type regex) | ||
| 312 | |||
| 313 | ;; Check some trivial things | ||
| 314 | (cond | ||
| 315 | ((null nterms) | ||
| 316 | (error "Bad input grammar")) | ||
| 317 | (start | ||
| 318 | (if (cdr start) | ||
| 319 | (message "Extra start symbols %S ignored" (cdr start))) | ||
| 320 | (setq start (symbol-name (car start))) | ||
| 321 | (unless (semantic-find-first-tag-by-name start nterms) | ||
| 322 | (error "start symbol `%s' has no rule" start))) | ||
| 323 | (t | ||
| 324 | ;; Default to the first grammar rule. | ||
| 325 | (setq start (semantic-tag-name (car nterms))))) | ||
| 326 | (when scopestart | ||
| 327 | (setq scopestart (symbol-name scopestart)) | ||
| 328 | (unless (semantic-find-first-tag-by-name scopestart nterms) | ||
| 329 | (error "scopestart symbol `%s' has no rule" scopestart))) | ||
| 330 | |||
| 331 | ;; Generate the grammar Lisp form. | ||
| 332 | (with-temp-buffer | ||
| 333 | (erase-buffer) | ||
| 334 | (insert "`(") | ||
| 335 | ;; Insert the start/scopestart rules | ||
| 336 | (insert "\n(bovine-toplevel \n(" | ||
| 337 | start | ||
| 338 | ")\n) ;; end bovine-toplevel\n") | ||
| 339 | (when scopestart | ||
| 340 | (insert "\n(bovine-inner-scope \n(" | ||
| 341 | scopestart | ||
| 342 | ")\n) ;; end bovine-inner-scope\n")) | ||
| 343 | ;; Process each nonterminal | ||
| 344 | (while nterms | ||
| 345 | (setq nterm (car nterms) | ||
| 346 | ;; We can't use the override form because the current buffer | ||
| 347 | ;; is not the originator of the tag. | ||
| 348 | rules (semantic-tag-components-semantic-grammar-mode nterm) | ||
| 349 | nterm (semantic-tag-name nterm) | ||
| 350 | nterms (cdr nterms)) | ||
| 351 | (when (member nterm '("bovine-toplevel" "bovine-inner-scope")) | ||
| 352 | (error "`%s' is a reserved internal name" nterm)) | ||
| 353 | (insert "\n(" nterm) | ||
| 354 | ;; Process each rule | ||
| 355 | (while rules | ||
| 356 | (setq items (semantic-tag-get-attribute (car rules) :value) | ||
| 357 | prec (semantic-tag-get-attribute (car rules) :prec) | ||
| 358 | actn (semantic-tag-get-attribute (car rules) :expr) | ||
| 359 | rules (cdr rules)) | ||
| 360 | ;; Process each item | ||
| 361 | (insert "\n(") | ||
| 362 | (if (null items) | ||
| 363 | ;; EMPTY rule | ||
| 364 | (insert ";;EMPTY" (if actn "" "\n")) | ||
| 365 | ;; Expand items | ||
| 366 | (while items | ||
| 367 | (setq item (car items) | ||
| 368 | items (cdr items)) | ||
| 369 | (if (consp item) ;; mid-rule action | ||
| 370 | (message "Mid-rule action %S ignored" item) | ||
| 371 | (or (char-equal (char-before) ?\() | ||
| 372 | (insert "\n")) | ||
| 373 | (cond | ||
| 374 | ((member item '("bovine-toplevel" "bovine-inner-scope")) | ||
| 375 | (error "`%s' is a reserved internal name" item)) | ||
| 376 | ;; Replace ITEM by its %token definition. | ||
| 377 | ;; If a '%token TYPE ITEM [REGEX]' definition exists | ||
| 378 | ;; in the grammar, ITEM is replaced by TYPE [REGEX]. | ||
| 379 | ((setq tag (semantic-find-first-tag-by-name | ||
| 380 | item tags) | ||
| 381 | type (semantic-tag-get-attribute tag :type)) | ||
| 382 | (insert type) | ||
| 383 | (if (setq regex (semantic-tag-get-attribute tag :value)) | ||
| 384 | (insert (format "\n%S" regex)))) | ||
| 385 | ;; Don't change ITEM | ||
| 386 | (t | ||
| 387 | (insert (semantic-grammar-item-text item))) | ||
| 388 | )))) | ||
| 389 | (if prec | ||
| 390 | (message "%%prec %S ignored" prec)) | ||
| 391 | (if actn | ||
| 392 | (bovine-grammar-expand-action actn quotemode)) | ||
| 393 | (insert ")")) | ||
| 394 | (insert "\n) ;; end " nterm "\n")) | ||
| 395 | (insert ")\n") | ||
| 396 | (buffer-string)))) | ||
| 397 | |||
| 398 | (defun bovine-grammar-setupcode-builder () | ||
| 399 | "Return the text of the setup code." | ||
| 400 | (format | ||
| 401 | "(setq semantic--parse-table %s\n\ | ||
| 402 | semantic-debug-parser-source %S\n\ | ||
| 403 | semantic-debug-parser-class 'semantic-bovine-debug-parser | ||
| 404 | semantic-flex-keywords-obarray %s\n\ | ||
| 405 | %s)" | ||
| 406 | (semantic-grammar-parsetable) | ||
| 407 | (buffer-name) | ||
| 408 | (semantic-grammar-keywordtable) | ||
| 409 | (let ((mode (semantic-grammar-languagemode))) | ||
| 410 | ;; Is there more than one major mode? | ||
| 411 | (if (and (listp mode) (> (length mode) 1)) | ||
| 412 | (format "semantic-equivalent-major-modes '%S\n" mode) | ||
| 413 | "")))) | ||
| 414 | |||
| 415 | (defvar bovine-grammar-menu | ||
| 416 | '("BY Grammar") | ||
| 417 | "BY mode specific grammar menu. | ||
| 418 | Menu items are appended to the common grammar menu.") | ||
| 419 | |||
| 420 | ;;;###autoload | ||
| 421 | (define-derived-mode bovine-grammar-mode semantic-grammar-mode "BY" | ||
| 422 | "Major mode for editing Bovine grammars." | ||
| 423 | (semantic-grammar-setup-menu bovine-grammar-menu) | ||
| 424 | (semantic-install-function-overrides | ||
| 425 | '((grammar-parsetable-builder . bovine-grammar-parsetable-builder) | ||
| 426 | (grammar-setupcode-builder . bovine-grammar-setupcode-builder)))) | ||
| 427 | |||
| 428 | (add-to-list 'auto-mode-alist '("\\.by\\'" . bovine-grammar-mode)) | ||
| 429 | |||
| 430 | (defvar-mode-local bovine-grammar-mode semantic-grammar-macros | ||
| 431 | '( | ||
| 432 | (ASSOC . semantic-grammar-ASSOC) | ||
| 433 | (EXPAND . bovine-grammar-EXPAND) | ||
| 434 | (EXPANDFULL . bovine-grammar-EXPANDFULL) | ||
| 435 | (TAG . bovine-grammar-TAG) | ||
| 436 | (VARIABLE-TAG . bovine-grammar-VARIABLE-TAG) | ||
| 437 | (FUNCTION-TAG . bovine-grammar-FUNCTION-TAG) | ||
| 438 | (TYPE-TAG . bovine-grammar-TYPE-TAG) | ||
| 439 | (INCLUDE-TAG . bovine-grammar-INCLUDE-TAG) | ||
| 440 | (PACKAGE-TAG . bovine-grammar-PACKAGE-TAG) | ||
| 441 | (CODE-TAG . bovine-grammar-CODE-TAG) | ||
| 442 | (ALIAS-TAG . bovine-grammar-ALIAS-TAG) | ||
| 443 | ) | ||
| 444 | "Semantic grammar macros used in bovine grammars.") | ||
| 445 | |||
| 446 | (defun bovine-make-parsers () | ||
| 447 | "Generate Emacs' built-in Bovine-based parser files." | ||
| 448 | (interactive) | ||
| 449 | (semantic-mode 1) | ||
| 450 | ;; Loop through each .by file in current directory, and run | ||
| 451 | ;; `semantic-grammar-batch-build-one-package' to build the grammar. | ||
| 452 | (dolist (f (directory-files default-directory nil "\\.by\\'")) | ||
| 453 | (let ((packagename | ||
| 454 | (condition-case err | ||
| 455 | (with-current-buffer (find-file-noselect f) | ||
| 456 | (semantic-grammar-create-package)) | ||
| 457 | (error (message "%s" (error-message-string err)) nil))) | ||
| 458 | lang filename) | ||
| 459 | (when (and packagename | ||
| 460 | (string-match "^.*/\\(.*\\)-by\\.el\\'" packagename)) | ||
| 461 | (setq lang (match-string 1 packagename)) | ||
| 462 | (setq filename (concat lang "-by.el")) | ||
| 463 | (with-temp-buffer | ||
| 464 | (insert-file-contents filename) | ||
| 465 | (setq buffer-file-name (expand-file-name filename)) | ||
| 466 | ;; Fix copyright header: | ||
| 467 | (goto-char (point-min)) | ||
| 468 | (re-search-forward "^;; Author:") | ||
| 469 | (setq copyright-end (match-beginning 0)) | ||
| 470 | (re-search-forward "^;;; Code:\n") | ||
| 471 | (delete-region copyright-end (match-end 0)) | ||
| 472 | (goto-char copyright-end) | ||
| 473 | (insert ";; This file is part of GNU Emacs. | ||
| 474 | |||
| 475 | ;; GNU Emacs is free software: you can redistribute it and/or modify | ||
| 476 | ;; it under the terms of the GNU General Public License as published by | ||
| 477 | ;; the Free Software Foundation, either version 3 of the License, or | ||
| 478 | ;; (at your option) any later version. | ||
| 479 | |||
| 480 | ;; GNU Emacs is distributed in the hope that it will be useful, | ||
| 481 | ;; but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
| 482 | ;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
| 483 | ;; GNU General Public License for more details. | ||
| 484 | |||
| 485 | ;; You should have received a copy of the GNU General Public License | ||
| 486 | ;; along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. | ||
| 487 | |||
| 488 | ;;; Commentary: | ||
| 489 | ;; | ||
| 490 | ;; This file was generated from admin/grammars/" | ||
| 491 | lang ".by. | ||
| 492 | |||
| 493 | ;;; Code: | ||
| 494 | ") | ||
| 495 | (goto-char (point-min)) | ||
| 496 | (delete-region (point-min) (line-end-position)) | ||
| 497 | (insert ";;; " packagename | ||
| 498 | " --- Generated parser support file") | ||
| 499 | (delete-trailing-whitespace) | ||
| 500 | (re-search-forward ";;; \\(.*\\) ends here") | ||
| 501 | (replace-match packagename nil nil nil 1) | ||
| 502 | (save-buffer)))))) | ||
| 503 | |||
| 504 | (provide 'semantic/bovine/grammar) | ||
| 505 | |||
| 506 | ;;; semantic/bovine/grammar.el ends here | ||
diff --git a/lisp/cedet/semantic/complete.el b/lisp/cedet/semantic/complete.el index 61760dd3fe8..9c2da9faefa 100644 --- a/lisp/cedet/semantic/complete.el +++ b/lisp/cedet/semantic/complete.el | |||
| @@ -1564,6 +1564,7 @@ Verbose: Always show all completions available. | |||
| 1564 | The absolute maximum number of completions for all mode is | 1564 | The absolute maximum number of completions for all mode is |
| 1565 | determined through `semantic-displayor-tooltip-max-tags'." | 1565 | determined through `semantic-displayor-tooltip-max-tags'." |
| 1566 | :group 'semantic | 1566 | :group 'semantic |
| 1567 | :version "24.3" | ||
| 1567 | :type '(choice (const :tag "Standard" standard) | 1568 | :type '(choice (const :tag "Standard" standard) |
| 1568 | (const :tag "Quiet" quiet) | 1569 | (const :tag "Quiet" quiet) |
| 1569 | (const :tag "Verbose" verbose))) | 1570 | (const :tag "Verbose" verbose))) |
| @@ -1573,24 +1574,25 @@ determined through `semantic-displayor-tooltip-max-tags'." | |||
| 1573 | "Maximum number of tags to be displayed initially. | 1574 | "Maximum number of tags to be displayed initially. |
| 1574 | See doc-string of `semantic-displayor-tooltip-mode' for details." | 1575 | See doc-string of `semantic-displayor-tooltip-mode' for details." |
| 1575 | :group 'semantic | 1576 | :group 'semantic |
| 1577 | :version "24.3" | ||
| 1576 | :type 'integer) | 1578 | :type 'integer) |
| 1577 | 1579 | ||
| 1578 | (defcustom semantic-displayor-tooltip-max-tags 25 | 1580 | (defcustom semantic-displayor-tooltip-max-tags 25 |
| 1579 | "The maximum number of tags to be displayed. | 1581 | "The maximum number of tags to be displayed. |
| 1580 | Maximum number of completions where we have activated the | 1582 | Maximum number of completions where we have activated the |
| 1581 | extended completion list through typing TAB or SPACE multiple | 1583 | extended completion list through typing TAB or SPACE multiple |
| 1582 | times. This limit needs to fit on your screen! | 1584 | times. This limit needs to fit on your screen! |
| 1583 | 1585 | ||
| 1584 | Note: If available, customizing this variable increases | 1586 | Note: If available, customizing this variable increases |
| 1585 | 'x-max-tooltip-size' to force over-sized tooltips when necessary. | 1587 | `x-max-tooltip-size' to force over-sized tooltips when necessary. |
| 1586 | This will not happen if you directly set this variable via | 1588 | This will not happen if you directly set this variable via `setq'." |
| 1587 | `setq'." | 1589 | :group 'semantic |
| 1588 | :group 'semantic | 1590 | :version "24.3" |
| 1589 | :type 'integer | 1591 | :type 'integer |
| 1590 | :set '(lambda (sym var) | 1592 | :set '(lambda (sym var) |
| 1591 | (set-default sym var) | 1593 | (set-default sym var) |
| 1592 | (when (boundp 'x-max-tooltip-size) | 1594 | (when (boundp 'x-max-tooltip-size) |
| 1593 | (setcdr x-max-tooltip-size (max (1+ var) (cdr x-max-tooltip-size)))))) | 1595 | (setcdr x-max-tooltip-size (max (1+ var) (cdr x-max-tooltip-size)))))) |
| 1594 | 1596 | ||
| 1595 | 1597 | ||
| 1596 | (defclass semantic-displayor-tooltip (semantic-displayor-traditional) | 1598 | (defclass semantic-displayor-tooltip (semantic-displayor-traditional) |
diff --git a/lisp/cedet/semantic/wisent/grammar.el b/lisp/cedet/semantic/wisent/grammar.el new file mode 100644 index 00000000000..6fa52dc2adc --- /dev/null +++ b/lisp/cedet/semantic/wisent/grammar.el | |||
| @@ -0,0 +1,526 @@ | |||
| 1 | ;;; semantic/wisent/grammar.el --- Wisent's input grammar mode | ||
| 2 | |||
| 3 | ;; Copyright (C) 2002-2012 Free Software Foundation, Inc. | ||
| 4 | ;; | ||
| 5 | ;; Author: David Ponce <david@dponce.com> | ||
| 6 | ;; Maintainer: David Ponce <david@dponce.com> | ||
| 7 | ;; Created: 26 Aug 2002 | ||
| 8 | ;; Keywords: syntax | ||
| 9 | ;; This file is part of GNU Emacs. | ||
| 10 | |||
| 11 | ;; GNU Emacs is free software: you can redistribute it and/or modify | ||
| 12 | ;; it under the terms of the GNU General Public License as published by | ||
| 13 | ;; the Free Software Foundation, either version 3 of the License, or | ||
| 14 | ;; (at your option) any later version. | ||
| 15 | |||
| 16 | ;; GNU Emacs is distributed in the hope that it will be useful, | ||
| 17 | ;; but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
| 18 | ;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
| 19 | ;; GNU General Public License for more details. | ||
| 20 | |||
| 21 | ;; You should have received a copy of the GNU General Public License | ||
| 22 | ;; along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. | ||
| 23 | |||
| 24 | ;;; Commentary: | ||
| 25 | ;; | ||
| 26 | ;; Major mode for editing Wisent's input grammar (.wy) files. | ||
| 27 | |||
| 28 | ;;; Code: | ||
| 29 | (require 'semantic) | ||
| 30 | (require 'semantic/grammar) | ||
| 31 | (require 'semantic/find) | ||
| 32 | (require 'semantic/lex) | ||
| 33 | (require 'semantic/wisent) | ||
| 34 | (require 'semantic/bovine) | ||
| 35 | |||
| 36 | (defsubst wisent-grammar-region-placeholder (symb) | ||
| 37 | "Given a $N placeholder symbol in SYMB, return a $regionN symbol. | ||
| 38 | Return nil if $N is not a valid placeholder symbol." | ||
| 39 | (let ((n (symbol-name symb))) | ||
| 40 | (if (string-match "^[$]\\([1-9][0-9]*\\)$" n) | ||
| 41 | (intern (concat "$region" (match-string 1 n)))))) | ||
| 42 | |||
| 43 | (defun wisent-grammar-EXPAND (symb nonterm) | ||
| 44 | "Expand call to EXPAND grammar macro. | ||
| 45 | Return the form to parse from within a nonterminal. | ||
| 46 | SYMB is a $I placeholder symbol that gives the bounds of the area to | ||
| 47 | parse. | ||
| 48 | NONTERM is the nonterminal symbol to start with." | ||
| 49 | (unless (member nonterm (semantic-grammar-start)) | ||
| 50 | (error "EXPANDFULL macro called with %s, but not used with %%start" | ||
| 51 | nonterm)) | ||
| 52 | (let (($ri (wisent-grammar-region-placeholder symb))) | ||
| 53 | (if $ri | ||
| 54 | `(semantic-bovinate-from-nonterminal | ||
| 55 | (car ,$ri) (cdr ,$ri) ',nonterm) | ||
| 56 | (error "Invalid form (EXPAND %s %s)" symb nonterm)))) | ||
| 57 | |||
| 58 | (defun wisent-grammar-EXPANDFULL (symb nonterm) | ||
| 59 | "Expand call to EXPANDFULL grammar macro. | ||
| 60 | Return the form to recursively parse an area. | ||
| 61 | SYMB is a $I placeholder symbol that gives the bounds of the area. | ||
| 62 | NONTERM is the nonterminal symbol to start with." | ||
| 63 | (unless (member nonterm (semantic-grammar-start)) | ||
| 64 | (error "EXPANDFULL macro called with %s, but not used with %%start" | ||
| 65 | nonterm)) | ||
| 66 | (let (($ri (wisent-grammar-region-placeholder symb))) | ||
| 67 | (if $ri | ||
| 68 | `(semantic-parse-region | ||
| 69 | (car ,$ri) (cdr ,$ri) ',nonterm 1) | ||
| 70 | (error "Invalid form (EXPANDFULL %s %s)" symb nonterm)))) | ||
| 71 | |||
| 72 | (defun wisent-grammar-TAG (name class &rest attributes) | ||
| 73 | "Expand call to TAG grammar macro. | ||
| 74 | Return the form to create a generic semantic tag. | ||
| 75 | See the function `semantic-tag' for the meaning of arguments NAME, | ||
| 76 | CLASS and ATTRIBUTES." | ||
| 77 | `(wisent-raw-tag | ||
| 78 | (semantic-tag ,name ,class ,@attributes))) | ||
| 79 | |||
| 80 | (defun wisent-grammar-VARIABLE-TAG (name type default-value &rest attributes) | ||
| 81 | "Expand call to VARIABLE-TAG grammar macro. | ||
| 82 | Return the form to create a semantic tag of class variable. | ||
| 83 | See the function `semantic-tag-new-variable' for the meaning of | ||
| 84 | arguments NAME, TYPE, DEFAULT-VALUE and ATTRIBUTES." | ||
| 85 | `(wisent-raw-tag | ||
| 86 | (semantic-tag-new-variable ,name ,type ,default-value ,@attributes))) | ||
| 87 | |||
| 88 | (defun wisent-grammar-FUNCTION-TAG (name type arg-list &rest attributes) | ||
| 89 | "Expand call to FUNCTION-TAG grammar macro. | ||
| 90 | Return the form to create a semantic tag of class function. | ||
| 91 | See the function `semantic-tag-new-function' for the meaning of | ||
| 92 | arguments NAME, TYPE, ARG-LIST and ATTRIBUTES." | ||
| 93 | `(wisent-raw-tag | ||
| 94 | (semantic-tag-new-function ,name ,type ,arg-list ,@attributes))) | ||
| 95 | |||
| 96 | (defun wisent-grammar-TYPE-TAG (name type members parents &rest attributes) | ||
| 97 | "Expand call to TYPE-TAG grammar macro. | ||
| 98 | Return the form to create a semantic tag of class type. | ||
| 99 | See the function `semantic-tag-new-type' for the meaning of arguments | ||
| 100 | NAME, TYPE, MEMBERS, PARENTS and ATTRIBUTES." | ||
| 101 | `(wisent-raw-tag | ||
| 102 | (semantic-tag-new-type ,name ,type ,members ,parents ,@attributes))) | ||
| 103 | |||
| 104 | (defun wisent-grammar-INCLUDE-TAG (name system-flag &rest attributes) | ||
| 105 | "Expand call to INCLUDE-TAG grammar macro. | ||
| 106 | Return the form to create a semantic tag of class include. | ||
| 107 | See the function `semantic-tag-new-include' for the meaning of | ||
| 108 | arguments NAME, SYSTEM-FLAG and ATTRIBUTES." | ||
| 109 | `(wisent-raw-tag | ||
| 110 | (semantic-tag-new-include ,name ,system-flag ,@attributes))) | ||
| 111 | |||
| 112 | (defun wisent-grammar-PACKAGE-TAG (name detail &rest attributes) | ||
| 113 | "Expand call to PACKAGE-TAG grammar macro. | ||
| 114 | Return the form to create a semantic tag of class package. | ||
| 115 | See the function `semantic-tag-new-package' for the meaning of | ||
| 116 | arguments NAME, DETAIL and ATTRIBUTES." | ||
| 117 | `(wisent-raw-tag | ||
| 118 | (semantic-tag-new-package ,name ,detail ,@attributes))) | ||
| 119 | |||
| 120 | (defun wisent-grammar-CODE-TAG (name detail &rest attributes) | ||
| 121 | "Expand call to CODE-TAG grammar macro. | ||
| 122 | Return the form to create a semantic tag of class code. | ||
| 123 | See the function `semantic-tag-new-code' for the meaning of arguments | ||
| 124 | NAME, DETAIL and ATTRIBUTES." | ||
| 125 | `(wisent-raw-tag | ||
| 126 | (semantic-tag-new-code ,name ,detail ,@attributes))) | ||
| 127 | |||
| 128 | (defun wisent-grammar-ALIAS-TAG (name aliasclass definition &rest attributes) | ||
| 129 | "Expand call to ALIAS-TAG grammar macro. | ||
| 130 | Return the form to create a semantic tag of class alias. | ||
| 131 | See the function `semantic-tag-new-alias' for the meaning of arguments | ||
| 132 | NAME, ALIASCLASS, DEFINITION and ATTRIBUTES." | ||
| 133 | `(wisent-raw-tag | ||
| 134 | (semantic-tag-new-alias ,name ,aliasclass ,definition ,@attributes))) | ||
| 135 | |||
| 136 | (defun wisent-grammar-EXPANDTAG (raw-tag) | ||
| 137 | "Expand call to EXPANDTAG grammar macro. | ||
| 138 | Return the form to produce a list of cooked tags from raw form of | ||
| 139 | Semantic tag RAW-TAG." | ||
| 140 | `(wisent-cook-tag ,raw-tag)) | ||
| 141 | |||
| 142 | (defun wisent-grammar-AST-ADD (ast &rest nodes) | ||
| 143 | "Expand call to AST-ADD grammar macro. | ||
| 144 | Return the form to update the abstract syntax tree AST with NODES. | ||
| 145 | See also the function `semantic-ast-add'." | ||
| 146 | `(semantic-ast-add ,ast ,@nodes)) | ||
| 147 | |||
| 148 | (defun wisent-grammar-AST-PUT (ast &rest nodes) | ||
| 149 | "Expand call to AST-PUT grammar macro. | ||
| 150 | Return the form to update the abstract syntax tree AST with NODES. | ||
| 151 | See also the function `semantic-ast-put'." | ||
| 152 | `(semantic-ast-put ,ast ,@nodes)) | ||
| 153 | |||
| 154 | (defun wisent-grammar-AST-GET (ast node) | ||
| 155 | "Expand call to AST-GET grammar macro. | ||
| 156 | Return the form to get, from the abstract syntax tree AST, the value | ||
| 157 | of NODE. | ||
| 158 | See also the function `semantic-ast-get'." | ||
| 159 | `(semantic-ast-get ,ast ,node)) | ||
| 160 | |||
| 161 | (defun wisent-grammar-AST-GET1 (ast node) | ||
| 162 | "Expand call to AST-GET1 grammar macro. | ||
| 163 | Return the form to get, from the abstract syntax tree AST, the first | ||
| 164 | value of NODE. | ||
| 165 | See also the function `semantic-ast-get1'." | ||
| 166 | `(semantic-ast-get1 ,ast ,node)) | ||
| 167 | |||
| 168 | (defun wisent-grammar-AST-GET-STRING (ast node) | ||
| 169 | "Expand call to AST-GET-STRING grammar macro. | ||
| 170 | Return the form to get, from the abstract syntax tree AST, the value | ||
| 171 | of NODE as a string. | ||
| 172 | See also the function `semantic-ast-get-string'." | ||
| 173 | `(semantic-ast-get-string ,ast ,node)) | ||
| 174 | |||
| 175 | (defun wisent-grammar-AST-MERGE (ast1 ast2) | ||
| 176 | "Expand call to AST-MERGE grammar macro. | ||
| 177 | Return the form to merge the abstract syntax trees AST1 and AST2. | ||
| 178 | See also the function `semantic-ast-merge'." | ||
| 179 | `(semantic-ast-merge ,ast1 ,ast2)) | ||
| 180 | |||
| 181 | (defun wisent-grammar-SKIP-BLOCK (&optional symb) | ||
| 182 | "Expand call to SKIP-BLOCK grammar macro. | ||
| 183 | Return the form to skip a parenthesized block. | ||
| 184 | Optional argument SYMB is a $I placeholder symbol that gives the | ||
| 185 | bounds of the block to skip. By default, skip the block at `$1'. | ||
| 186 | See also the function `wisent-skip-block'." | ||
| 187 | (let ($ri) | ||
| 188 | (when symb | ||
| 189 | (unless (setq $ri (wisent-grammar-region-placeholder symb)) | ||
| 190 | (error "Invalid form (SKIP-BLOCK %s)" symb))) | ||
| 191 | `(wisent-skip-block ,$ri))) | ||
| 192 | |||
| 193 | (defun wisent-grammar-SKIP-TOKEN () | ||
| 194 | "Expand call to SKIP-TOKEN grammar macro. | ||
| 195 | Return the form to skip the lookahead token. | ||
| 196 | See also the function `wisent-skip-token'." | ||
| 197 | `(wisent-skip-token)) | ||
| 198 | |||
| 199 | (defun wisent-grammar-assocs () | ||
| 200 | "Return associativity and precedence level definitions." | ||
| 201 | (mapcar | ||
| 202 | #'(lambda (tag) | ||
| 203 | (cons (intern (semantic-tag-name tag)) | ||
| 204 | (mapcar #'semantic-grammar-item-value | ||
| 205 | (semantic-tag-get-attribute tag :value)))) | ||
| 206 | (semantic-find-tags-by-class 'assoc (current-buffer)))) | ||
| 207 | |||
| 208 | (defun wisent-grammar-terminals () | ||
| 209 | "Return the list of terminal symbols. | ||
| 210 | Keep order of declaration in the WY file without duplicates." | ||
| 211 | (let (terms) | ||
| 212 | (mapc | ||
| 213 | #'(lambda (tag) | ||
| 214 | (mapcar #'(lambda (name) | ||
| 215 | (add-to-list 'terms (intern name))) | ||
| 216 | (cons (semantic-tag-name tag) | ||
| 217 | (semantic-tag-get-attribute tag :rest)))) | ||
| 218 | (semantic--find-tags-by-function | ||
| 219 | #'(lambda (tag) | ||
| 220 | (memq (semantic-tag-class tag) '(token keyword))) | ||
| 221 | (current-buffer))) | ||
| 222 | (nreverse terms))) | ||
| 223 | |||
| 224 | ;; Cache of macro definitions currently in use. | ||
| 225 | (defvar wisent--grammar-macros nil) | ||
| 226 | |||
| 227 | (defun wisent-grammar-expand-macros (expr) | ||
| 228 | "Expand expression EXPR into a form without grammar macros. | ||
| 229 | Return the expanded expression." | ||
| 230 | (if (or (atom expr) (semantic-grammar-quote-p (car expr))) | ||
| 231 | expr ;; Just return atom or quoted expression. | ||
| 232 | (let* ((expr (mapcar 'wisent-grammar-expand-macros expr)) | ||
| 233 | (macro (assq (car expr) wisent--grammar-macros))) | ||
| 234 | (if macro ;; Expand Semantic built-in. | ||
| 235 | (apply (cdr macro) (cdr expr)) | ||
| 236 | expr)))) | ||
| 237 | |||
| 238 | (defun wisent-grammar-nonterminals () | ||
| 239 | "Return the list form of nonterminal definitions." | ||
| 240 | (let ((nttags (semantic-find-tags-by-class | ||
| 241 | 'nonterminal (current-buffer))) | ||
| 242 | ;; Setup the cache of macro definitions. | ||
| 243 | (wisent--grammar-macros (semantic-grammar-macros)) | ||
| 244 | rltags nterms rules rule elems elem actn sexp prec) | ||
| 245 | (while nttags | ||
| 246 | (setq rltags (semantic-tag-components (car nttags)) | ||
| 247 | rules nil) | ||
| 248 | (while rltags | ||
| 249 | (setq elems (semantic-tag-get-attribute (car rltags) :value) | ||
| 250 | prec (semantic-tag-get-attribute (car rltags) :prec) | ||
| 251 | actn (semantic-tag-get-attribute (car rltags) :expr) | ||
| 252 | rule nil) | ||
| 253 | (when elems ;; not an EMPTY rule | ||
| 254 | (while elems | ||
| 255 | (setq elem (car elems) | ||
| 256 | elems (cdr elems)) | ||
| 257 | (setq elem (if (consp elem) ;; mid-rule action | ||
| 258 | (wisent-grammar-expand-macros (read (car elem))) | ||
| 259 | (semantic-grammar-item-value elem)) ;; item | ||
| 260 | rule (cons elem rule))) | ||
| 261 | (setq rule (nreverse rule))) | ||
| 262 | (if prec | ||
| 263 | (setq prec (vector (semantic-grammar-item-value prec)))) | ||
| 264 | (if actn | ||
| 265 | (setq sexp (wisent-grammar-expand-macros (read actn)))) | ||
| 266 | (setq rule (if actn | ||
| 267 | (if prec | ||
| 268 | (list rule prec sexp) | ||
| 269 | (list rule sexp)) | ||
| 270 | (if prec | ||
| 271 | (list rule prec) | ||
| 272 | (list rule)))) | ||
| 273 | (setq rules (cons rule rules) | ||
| 274 | rltags (cdr rltags))) | ||
| 275 | (setq nterms (cons (cons (intern (semantic-tag-name (car nttags))) | ||
| 276 | (nreverse rules)) | ||
| 277 | nterms) | ||
| 278 | nttags (cdr nttags))) | ||
| 279 | (nreverse nterms))) | ||
| 280 | |||
| 281 | (defun wisent-grammar-grammar () | ||
| 282 | "Return Elisp form of the grammar." | ||
| 283 | (let* ((terminals (wisent-grammar-terminals)) | ||
| 284 | (nonterminals (wisent-grammar-nonterminals)) | ||
| 285 | (assocs (wisent-grammar-assocs))) | ||
| 286 | (cons terminals (cons assocs nonterminals)))) | ||
| 287 | |||
| 288 | (defun wisent-grammar-parsetable-builder () | ||
| 289 | "Return the value of the parser table." | ||
| 290 | `(progn | ||
| 291 | ;; Ensure that the grammar [byte-]compiler is available. | ||
| 292 | (eval-when-compile (require 'semantic/wisent/comp)) | ||
| 293 | (wisent-compile-grammar | ||
| 294 | ',(wisent-grammar-grammar) | ||
| 295 | ',(semantic-grammar-start)))) | ||
| 296 | |||
| 297 | (defun wisent-grammar-setupcode-builder () | ||
| 298 | "Return the parser setup code." | ||
| 299 | (format | ||
| 300 | "(semantic-install-function-overrides\n\ | ||
| 301 | '((parse-stream . wisent-parse-stream)))\n\ | ||
| 302 | (setq semantic-parser-name \"LALR\"\n\ | ||
| 303 | semantic--parse-table %s\n\ | ||
| 304 | semantic-debug-parser-source %S\n\ | ||
| 305 | semantic-flex-keywords-obarray %s\n\ | ||
| 306 | semantic-lex-types-obarray %s)\n\ | ||
| 307 | ;; Collect unmatched syntax lexical tokens\n\ | ||
| 308 | (semantic-make-local-hook 'wisent-discarding-token-functions)\n\ | ||
| 309 | (add-hook 'wisent-discarding-token-functions\n\ | ||
| 310 | 'wisent-collect-unmatched-syntax nil t)" | ||
| 311 | (semantic-grammar-parsetable) | ||
| 312 | (buffer-name) | ||
| 313 | (semantic-grammar-keywordtable) | ||
| 314 | (semantic-grammar-tokentable))) | ||
| 315 | |||
| 316 | (defvar wisent-grammar-menu | ||
| 317 | '("WY Grammar" | ||
| 318 | ["LALR Compiler Verbose" wisent-toggle-verbose-flag | ||
| 319 | :style toggle :active (boundp 'wisent-verbose-flag) | ||
| 320 | :selected (and (boundp 'wisent-verbose-flag) | ||
| 321 | wisent-verbose-flag)] | ||
| 322 | ) | ||
| 323 | "WY mode specific grammar menu. | ||
| 324 | Menu items are appended to the common grammar menu.") | ||
| 325 | |||
| 326 | ;;;###autoload | ||
| 327 | (define-derived-mode wisent-grammar-mode semantic-grammar-mode "WY" | ||
| 328 | "Major mode for editing Wisent grammars." | ||
| 329 | (semantic-grammar-setup-menu wisent-grammar-menu) | ||
| 330 | (semantic-install-function-overrides | ||
| 331 | '((grammar-parsetable-builder . wisent-grammar-parsetable-builder) | ||
| 332 | (grammar-setupcode-builder . wisent-grammar-setupcode-builder)))) | ||
| 333 | |||
| 334 | (defvar-mode-local wisent-grammar-mode semantic-grammar-macros | ||
| 335 | '( | ||
| 336 | (ASSOC . semantic-grammar-ASSOC) | ||
| 337 | (EXPAND . wisent-grammar-EXPAND) | ||
| 338 | (EXPANDFULL . wisent-grammar-EXPANDFULL) | ||
| 339 | (TAG . wisent-grammar-TAG) | ||
| 340 | (VARIABLE-TAG . wisent-grammar-VARIABLE-TAG) | ||
| 341 | (FUNCTION-TAG . wisent-grammar-FUNCTION-TAG) | ||
| 342 | (TYPE-TAG . wisent-grammar-TYPE-TAG) | ||
| 343 | (INCLUDE-TAG . wisent-grammar-INCLUDE-TAG) | ||
| 344 | (PACKAGE-TAG . wisent-grammar-PACKAGE-TAG) | ||
| 345 | (EXPANDTAG . wisent-grammar-EXPANDTAG) | ||
| 346 | (CODE-TAG . wisent-grammar-CODE-TAG) | ||
| 347 | (ALIAS-TAG . wisent-grammar-ALIAS-TAG) | ||
| 348 | (AST-ADD . wisent-grammar-AST-ADD) | ||
| 349 | (AST-PUT . wisent-grammar-AST-PUT) | ||
| 350 | (AST-GET . wisent-grammar-AST-GET) | ||
| 351 | (AST-GET1 . wisent-grammar-AST-GET1) | ||
| 352 | (AST-GET-STRING . wisent-grammar-AST-GET-STRING) | ||
| 353 | (AST-MERGE . wisent-grammar-AST-MERGE) | ||
| 354 | (SKIP-BLOCK . wisent-grammar-SKIP-BLOCK) | ||
| 355 | (SKIP-TOKEN . wisent-grammar-SKIP-TOKEN) | ||
| 356 | ) | ||
| 357 | "Semantic grammar macros used in wisent grammars.") | ||
| 358 | |||
| 359 | (defvar wisent-make-parsers--emacs-license | ||
| 360 | ";; This file is part of GNU Emacs. | ||
| 361 | |||
| 362 | ;; GNU Emacs is free software: you can redistribute it and/or modify | ||
| 363 | ;; it under the terms of the GNU General Public License as published by | ||
| 364 | ;; the Free Software Foundation, either version 3 of the License, or | ||
| 365 | ;; (at your option) any later version. | ||
| 366 | |||
| 367 | ;; GNU Emacs is distributed in the hope that it will be useful, | ||
| 368 | ;; but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
| 369 | ;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
| 370 | ;; GNU General Public License for more details. | ||
| 371 | |||
| 372 | ;; You should have received a copy of the GNU General Public License | ||
| 373 | ;; along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>.") | ||
| 374 | |||
| 375 | (defvar wisent-make-parsers--python-license | ||
| 376 | ";; It is derived in part from the Python grammar, used under the | ||
| 377 | ;; following license: | ||
| 378 | ;; | ||
| 379 | ;; PYTHON SOFTWARE FOUNDATION LICENSE VERSION 2 | ||
| 380 | ;; -------------------------------------------- | ||
| 381 | ;; 1. This LICENSE AGREEMENT is between the Python Software Foundation | ||
| 382 | ;; (\"PSF\"), and the Individual or Organization (\"Licensee\") accessing | ||
| 383 | ;; and otherwise using this software (\"Python\") in source or binary | ||
| 384 | ;; form and its associated documentation. | ||
| 385 | ;; | ||
| 386 | ;; 2. Subject to the terms and conditions of this License Agreement, | ||
| 387 | ;; PSF hereby grants Licensee a nonexclusive, royalty-free, world-wide | ||
| 388 | ;; license to reproduce, analyze, test, perform and/or display | ||
| 389 | ;; publicly, prepare derivative works, distribute, and otherwise use | ||
| 390 | ;; Python alone or in any derivative version, provided, however, that | ||
| 391 | ;; PSF's License Agreement and PSF's notice of copyright, i.e., | ||
| 392 | ;; \"Copyright (c) 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, | ||
| 393 | ;; 2009, 2010 Python Software Foundation; All Rights Reserved\" are | ||
| 394 | ;; retained in Python alone or in any derivative version prepared by | ||
| 395 | ;; Licensee. | ||
| 396 | ;; | ||
| 397 | ;; 3. In the event Licensee prepares a derivative work that is based | ||
| 398 | ;; on or incorporates Python or any part thereof, and wants to make | ||
| 399 | ;; the derivative work available to others as provided herein, then | ||
| 400 | ;; Licensee hereby agrees to include in any such work a brief summary | ||
| 401 | ;; of the changes made to Python. | ||
| 402 | ;; | ||
| 403 | ;; 4. PSF is making Python available to Licensee on an \"AS IS\" | ||
| 404 | ;; basis. PSF MAKES NO REPRESENTATIONS OR WARRANTIES, EXPRESS OR | ||
| 405 | ;; IMPLIED. BY WAY OF EXAMPLE, BUT NOT LIMITATION, PSF MAKES NO AND | ||
| 406 | ;; DISCLAIMS ANY REPRESENTATION OR WARRANTY OF MERCHANTABILITY OR FITNESS | ||
| 407 | ;; FOR ANY PARTICULAR PURPOSE OR THAT THE USE OF PYTHON WILL NOT | ||
| 408 | ;; INFRINGE ANY THIRD PARTY RIGHTS. | ||
| 409 | ;; | ||
| 410 | ;; 5. PSF SHALL NOT BE LIABLE TO LICENSEE OR ANY OTHER USERS OF PYTHON | ||
| 411 | ;; FOR ANY INCIDENTAL, SPECIAL, OR CONSEQUENTIAL DAMAGES OR LOSS AS A | ||
| 412 | ;; RESULT OF MODIFYING, DISTRIBUTING, OR OTHERWISE USING PYTHON, OR | ||
| 413 | ;; ANY DERIVATIVE THEREOF, EVEN IF ADVISED OF THE POSSIBILITY THEREOF. | ||
| 414 | ;; | ||
| 415 | ;; 6. This License Agreement will automatically terminate upon a | ||
| 416 | ;; material breach of its terms and conditions. | ||
| 417 | ;; | ||
| 418 | ;; 7. Nothing in this License Agreement shall be deemed to create any | ||
| 419 | ;; relationship of agency, partnership, or joint venture between PSF | ||
| 420 | ;; and Licensee. This License Agreement does not grant permission to | ||
| 421 | ;; use PSF trademarks or trade name in a trademark sense to endorse or | ||
| 422 | ;; promote products or services of Licensee, or any third party. | ||
| 423 | ;; | ||
| 424 | ;; 8. By copying, installing or otherwise using Python, Licensee | ||
| 425 | ;; agrees to be bound by the terms and conditions of this License | ||
| 426 | ;; Agreement.") | ||
| 427 | |||
| 428 | (defvar wisent-make-parsers--ecmascript-license | ||
| 429 | "\n;; It is derived from the grammar in the ECMAScript Language | ||
| 430 | ;; Specification published at | ||
| 431 | ;; | ||
| 432 | ;; http://www.ecma-international.org/publications/standards/Ecma-262.htm | ||
| 433 | ;; | ||
| 434 | ;; and redistributed under the following license: | ||
| 435 | ;; | ||
| 436 | ;; Redistribution and use in source and binary forms, with or without | ||
| 437 | ;; modification, are permitted provided that the following conditions | ||
| 438 | ;; are met: | ||
| 439 | ;; | ||
| 440 | ;; 1. Redistributions of source code must retain the above copyright | ||
| 441 | ;; notice, this list of conditions and the following disclaimer. | ||
| 442 | ;; | ||
| 443 | ;; 2. Redistributions in binary form must reproduce the above | ||
| 444 | ;; copyright notice, this list of conditions and the following | ||
| 445 | ;; disclaimer in the documentation and/or other materials provided | ||
| 446 | ;; with the distribution. | ||
| 447 | ;; | ||
| 448 | ;; 3. Neither the name of the authors nor Ecma International may be | ||
| 449 | ;; used to endorse or promote products derived from this software | ||
| 450 | ;; without specific prior written permission. THIS SOFTWARE IS | ||
| 451 | ;; PROVIDED BY THE ECMA INTERNATIONAL \"AS IS\" AND ANY EXPRESS OR | ||
| 452 | ;; IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED | ||
| 453 | ;; WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE | ||
| 454 | ;; ARE DISCLAIMED. IN NO EVENT SHALL ECMA INTERNATIONAL BE LIABLE FOR | ||
| 455 | ;; ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR | ||
| 456 | ;; CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT | ||
| 457 | ;; OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR | ||
| 458 | ;; BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF | ||
| 459 | ;; LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT | ||
| 460 | ;; (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE | ||
| 461 | ;; USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH | ||
| 462 | ;; DAMAGE.") | ||
| 463 | |||
| 464 | (defvar wisent-make-parsers--parser-file-name | ||
| 465 | `(("semantic/grammar-wy.el") | ||
| 466 | ("srecode/srt-wy.el") | ||
| 467 | ("semantic/wisent/js-wy.el" | ||
| 468 | "Copyright (C) 1998-2011 Ecma International." | ||
| 469 | ,wisent-make-parsers--ecmascript-license) | ||
| 470 | ("semantic/wisent/javat-wy.el") | ||
| 471 | ("semantic/wisent/python-wy.el" | ||
| 472 | "Copyright (c) 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, | ||
| 473 | \;; 2009, 2010 Python Software Foundation; All Rights Reserved" | ||
| 474 | ,wisent-make-parsers--python-license))) | ||
| 475 | |||
| 476 | (defun wisent-make-parsers () | ||
| 477 | "Generate Emacs' built-in Wisent-based parser files." | ||
| 478 | (interactive) | ||
| 479 | (semantic-mode 1) | ||
| 480 | ;; Loop through each .wy file in current directory, and run | ||
| 481 | ;; `semantic-grammar-batch-build-one-package' to build the grammar. | ||
| 482 | (dolist (f (directory-files default-directory nil "\\.wy\\'")) | ||
| 483 | (let ((packagename | ||
| 484 | (condition-case err | ||
| 485 | (with-current-buffer (find-file-noselect f) | ||
| 486 | (semantic-grammar-create-package)) | ||
| 487 | (error (message "%s" (error-message-string err)) nil))) | ||
| 488 | output-data) | ||
| 489 | (when (setq output-data (assoc packagename wisent-make-parsers--parser-file-name)) | ||
| 490 | (let ((additional-copyright (nth 1 output-data)) | ||
| 491 | (additional-license (nth 2 output-data)) | ||
| 492 | (filename (progn (string-match ".*/\\(.*\\)" packagename) (match-string 1 packagename))) | ||
| 493 | copyright-end) | ||
| 494 | ;; Touch up the generated parsers for Emacs integration. | ||
| 495 | (with-temp-buffer | ||
| 496 | (insert-file-contents filename) | ||
| 497 | ;; Fix copyright header: | ||
| 498 | (goto-char (point-min)) | ||
| 499 | (when additional-copyright | ||
| 500 | (re-search-forward "Copyright (C).*$") | ||
| 501 | (insert "\n;; " additional-copyright)) | ||
| 502 | (re-search-forward "^;; Author:") | ||
| 503 | (setq copyright-end (match-beginning 0)) | ||
| 504 | (re-search-forward "^;;; Code:\n") | ||
| 505 | (delete-region copyright-end (match-end 0)) | ||
| 506 | (goto-char copyright-end) | ||
| 507 | (insert wisent-make-parsers--emacs-license) | ||
| 508 | (insert "\n\n;;; Commentary: | ||
| 509 | ;; | ||
| 510 | ;; This file was generated from admin/grammars/" | ||
| 511 | f ".") | ||
| 512 | (when additional-license | ||
| 513 | (insert "\n" additional-license)) | ||
| 514 | (insert "\n\n;;; Code:\n") | ||
| 515 | (goto-char (point-min)) | ||
| 516 | (delete-region (point-min) (line-end-position)) | ||
| 517 | (insert ";;; " packagename | ||
| 518 | " --- Generated parser support file") | ||
| 519 | (re-search-forward ";;; \\(.*\\) ends here") | ||
| 520 | (replace-match packagename nil nil nil 1) | ||
| 521 | (delete-trailing-whitespace) | ||
| 522 | (write-region nil nil (expand-file-name filename)))))))) | ||
| 523 | |||
| 524 | (provide 'semantic/wisent/grammar) | ||
| 525 | |||
| 526 | ;;; semantic/wisent/grammar.el ends here | ||
diff --git a/lisp/ehelp.el b/lisp/ehelp.el index 281148d9cf6..a1bd4d65385 100644 --- a/lisp/ehelp.el +++ b/lisp/ehelp.el | |||
| @@ -61,6 +61,8 @@ | |||
| 61 | 61 | ||
| 62 | (defvar electric-help-map | 62 | (defvar electric-help-map |
| 63 | (let ((map (make-keymap))) | 63 | (let ((map (make-keymap))) |
| 64 | ;; FIXME fragile. Should derive from help-mode-map in a smarter way. | ||
| 65 | (set-keymap-parent map button-buffer-map) | ||
| 64 | ;; allow all non-self-inserting keys - search, scroll, etc, but | 66 | ;; allow all non-self-inserting keys - search, scroll, etc, but |
| 65 | ;; let M-x and C-x exit ehelp mode and retain buffer: | 67 | ;; let M-x and C-x exit ehelp mode and retain buffer: |
| 66 | (suppress-keymap map) | 68 | (suppress-keymap map) |
| @@ -102,7 +104,7 @@ | |||
| 102 | (setq buffer-read-only t) | 104 | (setq buffer-read-only t) |
| 103 | (setq electric-help-orig-major-mode major-mode) | 105 | (setq electric-help-orig-major-mode major-mode) |
| 104 | (setq mode-name "Help") | 106 | (setq mode-name "Help") |
| 105 | (setq major-mode 'help) | 107 | (setq major-mode 'help-mode) |
| 106 | (setq mode-line-buffer-identification '(" Help: %b")) | 108 | (setq mode-line-buffer-identification '(" Help: %b")) |
| 107 | (use-local-map electric-help-map) | 109 | (use-local-map electric-help-map) |
| 108 | (add-hook 'mouse-leave-buffer-hook 'electric-help-retain) | 110 | (add-hook 'mouse-leave-buffer-hook 'electric-help-retain) |
diff --git a/lisp/emacs-lisp/cl-loaddefs.el b/lisp/emacs-lisp/cl-loaddefs.el index 922c9856208..e25ac5f9708 100644 --- a/lisp/emacs-lisp/cl-loaddefs.el +++ b/lisp/emacs-lisp/cl-loaddefs.el | |||
| @@ -260,7 +260,7 @@ Remove from SYMBOL's plist the property PROPNAME and its value. | |||
| 260 | ;;;;;; cl-typecase cl-ecase cl-case cl-load-time-value cl-eval-when | 260 | ;;;;;; cl-typecase cl-ecase cl-case cl-load-time-value cl-eval-when |
| 261 | ;;;;;; cl-destructuring-bind cl-function cl-defmacro cl-defun cl-gentemp | 261 | ;;;;;; cl-destructuring-bind cl-function cl-defmacro cl-defun cl-gentemp |
| 262 | ;;;;;; cl-gensym cl--compiler-macro-cXXr cl--compiler-macro-list*) | 262 | ;;;;;; cl-gensym cl--compiler-macro-cXXr cl--compiler-macro-list*) |
| 263 | ;;;;;; "cl-macs" "cl-macs.el" "da92f58f688ff6fb4d0098eb0f3acf0b") | 263 | ;;;;;; "cl-macs" "cl-macs.el" "6951d080daefb5194b1d21fe9b2deae4") |
| 264 | ;;; Generated autoloads from cl-macs.el | 264 | ;;; Generated autoloads from cl-macs.el |
| 265 | 265 | ||
| 266 | (autoload 'cl--compiler-macro-list* "cl-macs" "\ | 266 | (autoload 'cl--compiler-macro-list* "cl-macs" "\ |
| @@ -657,8 +657,9 @@ copier, a `NAME-p' predicate, and slot accessors named `NAME-SLOT'. | |||
| 657 | You can use the accessors to set the corresponding slots, via `setf'. | 657 | You can use the accessors to set the corresponding slots, via `setf'. |
| 658 | 658 | ||
| 659 | NAME may instead take the form (NAME OPTIONS...), where each | 659 | NAME may instead take the form (NAME OPTIONS...), where each |
| 660 | OPTION is either a single keyword or (KEYWORD VALUE). | 660 | OPTION is either a single keyword or (KEYWORD VALUE) where |
| 661 | See Info node `(cl)Structures' for a list of valid keywords. | 661 | KEYWORD can be one of :conc-name, :constructor, :copier, :predicate, |
| 662 | :type, :named, :initial-offset, :print-function, or :include. | ||
| 662 | 663 | ||
| 663 | Each SLOT may instead take the form (SLOT SLOT-OPTS...), where | 664 | Each SLOT may instead take the form (SLOT SLOT-OPTS...), where |
| 664 | SLOT-OPTS are keyword-value pairs for that slot. Currently, only | 665 | SLOT-OPTS are keyword-value pairs for that slot. Currently, only |
diff --git a/lisp/emacs-lisp/cl-macs.el b/lisp/emacs-lisp/cl-macs.el index 56e698bec0a..99bae1944e8 100644 --- a/lisp/emacs-lisp/cl-macs.el +++ b/lisp/emacs-lisp/cl-macs.el | |||
| @@ -2154,8 +2154,9 @@ copier, a `NAME-p' predicate, and slot accessors named `NAME-SLOT'. | |||
| 2154 | You can use the accessors to set the corresponding slots, via `setf'. | 2154 | You can use the accessors to set the corresponding slots, via `setf'. |
| 2155 | 2155 | ||
| 2156 | NAME may instead take the form (NAME OPTIONS...), where each | 2156 | NAME may instead take the form (NAME OPTIONS...), where each |
| 2157 | OPTION is either a single keyword or (KEYWORD VALUE). | 2157 | OPTION is either a single keyword or (KEYWORD VALUE) where |
| 2158 | See Info node `(cl)Structures' for a list of valid keywords. | 2158 | KEYWORD can be one of :conc-name, :constructor, :copier, :predicate, |
| 2159 | :type, :named, :initial-offset, :print-function, or :include. | ||
| 2159 | 2160 | ||
| 2160 | Each SLOT may instead take the form (SLOT SLOT-OPTS...), where | 2161 | Each SLOT may instead take the form (SLOT SLOT-OPTS...), where |
| 2161 | SLOT-OPTS are keyword-value pairs for that slot. Currently, only | 2162 | SLOT-OPTS are keyword-value pairs for that slot. Currently, only |
diff --git a/lisp/emulation/crisp.el b/lisp/emulation/crisp.el index c9822b7ec27..01d202f87b5 100644 --- a/lisp/emulation/crisp.el +++ b/lisp/emulation/crisp.el | |||
| @@ -171,14 +171,14 @@ | |||
| 171 | All the bindings are done here instead of globally to try and be | 171 | All the bindings are done here instead of globally to try and be |
| 172 | nice to the world.") | 172 | nice to the world.") |
| 173 | 173 | ||
| 174 | (define-obsolete-variable-alias 'crisp-mode-modeline-string | ||
| 175 | 'crisp-mode-mode-line-string "24.3") | ||
| 176 | |||
| 174 | (defcustom crisp-mode-mode-line-string " *CRiSP*" | 177 | (defcustom crisp-mode-mode-line-string " *CRiSP*" |
| 175 | "String to display in the mode line when CRiSP emulation mode is enabled." | 178 | "String to display in the mode line when CRiSP emulation mode is enabled." |
| 176 | :type 'string | 179 | :type 'string |
| 177 | :group 'crisp) | 180 | :group 'crisp) |
| 178 | 181 | ||
| 179 | (define-obsolete-variable-alias 'crisp-mode-modeline-string | ||
| 180 | 'crisp-mode-mode-line-string "24.3") | ||
| 181 | |||
| 182 | ;;;###autoload | 182 | ;;;###autoload |
| 183 | (defcustom crisp-mode nil | 183 | (defcustom crisp-mode nil |
| 184 | "Track status of CRiSP emulation mode. | 184 | "Track status of CRiSP emulation mode. |
diff --git a/lisp/erc/ChangeLog b/lisp/erc/ChangeLog index 3558a8a90b5..8b4df6099bc 100644 --- a/lisp/erc/ChangeLog +++ b/lisp/erc/ChangeLog | |||
| @@ -1,3 +1,27 @@ | |||
| 1 | 2012-10-07 Deniz Dogan <deniz@dogan.se> | ||
| 2 | |||
| 3 | * erc-log.el (erc-generate-log-file-name-function): | ||
| 4 | Clarify tags for various choices. (Bug#11186) | ||
| 5 | |||
| 6 | 2012-10-07 Glenn Morris <rgm@gnu.org> | ||
| 7 | |||
| 8 | * erc-button.el (erc-button-alist): Remove "finger". (Bug#4443) | ||
| 9 | |||
| 10 | 2012-10-07 Antoine Levitt <antoine.levitt@gmail.com> | ||
| 11 | |||
| 12 | * erc-stamp.el (erc-format-timestamp): Don't apply intangible | ||
| 13 | property to invisible stamps. (Bug#11706) | ||
| 14 | |||
| 15 | 2012-10-07 Glenn Morris <rgm@gnu.org> | ||
| 16 | |||
| 17 | * erc-backend.el (NICK): Handle pre-existing buffers. (Bug#12002) | ||
| 18 | |||
| 19 | 2012-10-06 Glenn Morris <rgm@gnu.org> | ||
| 20 | |||
| 21 | * erc.el (erc-lurker): | ||
| 22 | * erc-desktop-notifications.el (erc-notifications): | ||
| 23 | Add missing group :version tags. | ||
| 24 | |||
| 1 | 2012-10-04 Julien Danjou <julien@danjou.info> | 25 | 2012-10-04 Julien Danjou <julien@danjou.info> |
| 2 | 26 | ||
| 3 | * erc-desktop-notifications.el: Rename from erc-notifications to | 27 | * erc-desktop-notifications.el: Rename from erc-notifications to |
| @@ -9,8 +33,7 @@ | |||
| 9 | 33 | ||
| 10 | 2012-09-17 Chong Yidong <cyd@gnu.org> | 34 | 2012-09-17 Chong Yidong <cyd@gnu.org> |
| 11 | 35 | ||
| 12 | * erc-page.el (erc-page-function): | 36 | * erc-page.el (erc-page-function): |
| 13 | |||
| 14 | * erc-stamp.el (erc-stamp): Doc fix. | 37 | * erc-stamp.el (erc-stamp): Doc fix. |
| 15 | 38 | ||
| 16 | 2012-08-21 Josh Feinstein <jlf@foxtail.org> | 39 | 2012-08-21 Josh Feinstein <jlf@foxtail.org> |
| @@ -103,7 +126,7 @@ | |||
| 103 | (erc-autojoin-after-ident): Ditto. | 126 | (erc-autojoin-after-ident): Ditto. |
| 104 | (erc-autojoin-channels-alist): Mention auth-source. | 127 | (erc-autojoin-channels-alist): Mention auth-source. |
| 105 | 128 | ||
| 106 | 2012-04-10 Deniz Dogan <deniz@dogan.se> (tiny change) | 129 | 2012-04-10 Deniz Dogan <deniz@dogan.se> |
| 107 | 130 | ||
| 108 | * erc.el (erc-display-prompt): Adds the field text property to the | 131 | * erc.el (erc-display-prompt): Adds the field text property to the |
| 109 | ERC prompt. This allows users to use `kill-whole-line' to kill | 132 | ERC prompt. This allows users to use `kill-whole-line' to kill |
diff --git a/lisp/erc/erc-backend.el b/lisp/erc/erc-backend.el index 75f0047bf06..20ccd071b95 100644 --- a/lisp/erc/erc-backend.el +++ b/lisp/erc/erc-backend.el | |||
| @@ -1316,7 +1316,7 @@ add things to `%s' instead." | |||
| 1316 | (when (equal (erc-default-target) nick) | 1316 | (when (equal (erc-default-target) nick) |
| 1317 | (setq erc-default-recipients | 1317 | (setq erc-default-recipients |
| 1318 | (cons nn (cdr erc-default-recipients))) | 1318 | (cons nn (cdr erc-default-recipients))) |
| 1319 | (rename-buffer nn) | 1319 | (rename-buffer nn t) ; bug#12002 |
| 1320 | (erc-update-mode-line) | 1320 | (erc-update-mode-line) |
| 1321 | (add-to-list 'bufs (current-buffer))))) | 1321 | (add-to-list 'bufs (current-buffer))))) |
| 1322 | (erc-update-user-nick nick nn host nil nil login) | 1322 | (erc-update-user-nick nick nn host nil nil login) |
diff --git a/lisp/erc/erc-button.el b/lisp/erc/erc-button.el index 687d11d144e..433ffc05340 100644 --- a/lisp/erc/erc-button.el +++ b/lisp/erc/erc-button.el | |||
| @@ -135,7 +135,7 @@ longer than `erc-fill-column'." | |||
| 135 | '(('nicknames 0 erc-button-buttonize-nicks erc-nick-popup 0) | 135 | '(('nicknames 0 erc-button-buttonize-nicks erc-nick-popup 0) |
| 136 | (erc-button-url-regexp 0 t browse-url 0) | 136 | (erc-button-url-regexp 0 t browse-url 0) |
| 137 | ("<URL: *\\([^<> ]+\\) *>" 0 t browse-url 1) | 137 | ("<URL: *\\([^<> ]+\\) *>" 0 t browse-url 1) |
| 138 | ("(\\(\\([^~\n \t@][^\n \t@]*\\)@\\([a-zA-Z0-9.:-]+\\)\\)" 1 t finger 2 3) | 138 | ;;; ("(\\(\\([^~\n \t@][^\n \t@]*\\)@\\([a-zA-Z0-9.:-]+\\)\\)" 1 t finger 2 3) |
| 139 | ;; emacs internal | 139 | ;; emacs internal |
| 140 | ("[`]\\([a-zA-Z][-a-zA-Z_0-9]+\\)[']" 1 t erc-button-describe-symbol 1) | 140 | ("[`]\\([a-zA-Z][-a-zA-Z_0-9]+\\)[']" 1 t erc-button-describe-symbol 1) |
| 141 | ;; pseudo links | 141 | ;; pseudo links |
| @@ -183,6 +183,7 @@ PAR is a number of a regexp grouping whose text will be passed to | |||
| 183 | 'nicknames, these are ignored, and CALLBACK will be called with | 183 | 'nicknames, these are ignored, and CALLBACK will be called with |
| 184 | the nickname matched as the argument." | 184 | the nickname matched as the argument." |
| 185 | :group 'erc-button | 185 | :group 'erc-button |
| 186 | :version "24.3" ; remove finger (bug#4443) | ||
| 186 | :type '(repeat | 187 | :type '(repeat |
| 187 | (list :tag "Button" | 188 | (list :tag "Button" |
| 188 | (choice :tag "Matches" | 189 | (choice :tag "Matches" |
diff --git a/lisp/erc/erc-desktop-notifications.el b/lisp/erc/erc-desktop-notifications.el index 57b93f43219..2cc3c80a8ea 100644 --- a/lisp/erc/erc-desktop-notifications.el +++ b/lisp/erc/erc-desktop-notifications.el | |||
| @@ -35,6 +35,7 @@ | |||
| 35 | 35 | ||
| 36 | (defgroup erc-notifications nil | 36 | (defgroup erc-notifications nil |
| 37 | "Send notifications on PRIVMSG or mentions." | 37 | "Send notifications on PRIVMSG or mentions." |
| 38 | :version "24.3" | ||
| 38 | :group 'erc) | 39 | :group 'erc) |
| 39 | 40 | ||
| 40 | (defvar erc-notifications-last-notification nil | 41 | (defvar erc-notifications-last-notification nil |
diff --git a/lisp/erc/erc-log.el b/lisp/erc/erc-log.el index 9e6c587bd12..b3f3f5865a1 100644 --- a/lisp/erc/erc-log.el +++ b/lisp/erc/erc-log.el | |||
| @@ -114,11 +114,13 @@ If you want to write logs into different directories, make a | |||
| 114 | custom function which returns the directory part and set | 114 | custom function which returns the directory part and set |
| 115 | `erc-log-channels-directory' to its name." | 115 | `erc-log-channels-directory' to its name." |
| 116 | :group 'erc-log | 116 | :group 'erc-log |
| 117 | :type '(choice (const :tag "Long style" erc-generate-log-file-name-long) | 117 | :type '(choice (const :tag "#channel!nick@server:port.txt" |
| 118 | (const :tag "Long, but with network name rather than server" | 118 | erc-generate-log-file-name-long) |
| 119 | (const :tag "#channel!nick@network.txt" | ||
| 119 | erc-generate-log-file-name-network) | 120 | erc-generate-log-file-name-network) |
| 120 | (const :tag "Short" erc-generate-log-file-name-short) | 121 | (const :tag "#channel.txt" erc-generate-log-file-name-short) |
| 121 | (const :tag "With date" erc-generate-log-file-name-with-date) | 122 | (const :tag "#channel@date.txt" |
| 123 | erc-generate-log-file-name-with-date) | ||
| 122 | (function :tag "Other function"))) | 124 | (function :tag "Other function"))) |
| 123 | 125 | ||
| 124 | (defcustom erc-truncate-buffer-on-save nil | 126 | (defcustom erc-truncate-buffer-on-save nil |
diff --git a/lisp/erc/erc-stamp.el b/lisp/erc/erc-stamp.el index 1613d03912c..4fa3f9f5915 100644 --- a/lisp/erc/erc-stamp.el +++ b/lisp/erc/erc-stamp.el | |||
| @@ -353,8 +353,9 @@ Return the empty string if FORMAT is nil." | |||
| 353 | 'isearch-open-invisible 'timestamp ts) | 353 | 'isearch-open-invisible 'timestamp ts) |
| 354 | ;; N.B. Later use categories instead of this harmless, but | 354 | ;; N.B. Later use categories instead of this harmless, but |
| 355 | ;; inelegant, hack. -- BPT | 355 | ;; inelegant, hack. -- BPT |
| 356 | (when erc-timestamp-intangible | 356 | (and erc-timestamp-intangible |
| 357 | (erc-put-text-property 0 (length ts) 'intangible t ts)) | 357 | (not erc-hide-timestamps) ; bug#11706 |
| 358 | (erc-put-text-property 0 (length ts) 'intangible t ts)) | ||
| 358 | ts) | 359 | ts) |
| 359 | "")) | 360 | "")) |
| 360 | 361 | ||
diff --git a/lisp/erc/erc.el b/lisp/erc/erc.el index 687e60da28a..bbd9dad4310 100644 --- a/lisp/erc/erc.el +++ b/lisp/erc/erc.el | |||
| @@ -102,6 +102,7 @@ | |||
| 102 | 102 | ||
| 103 | (defgroup erc-lurker nil | 103 | (defgroup erc-lurker nil |
| 104 | "Hide specified message types sent by lurkers" | 104 | "Hide specified message types sent by lurkers" |
| 105 | :version "24.3" | ||
| 105 | :group 'erc-ignore) | 106 | :group 'erc-ignore) |
| 106 | 107 | ||
| 107 | (defgroup erc-query nil | 108 | (defgroup erc-query nil |
diff --git a/lisp/eshell/esh-mode.el b/lisp/eshell/esh-mode.el index 8a9107e5470..673632400f2 100644 --- a/lisp/eshell/esh-mode.el +++ b/lisp/eshell/esh-mode.el | |||
| @@ -193,14 +193,14 @@ This is used by `eshell-watch-for-password-prompt'." | |||
| 193 | :type '(choice (const nil) function) | 193 | :type '(choice (const nil) function) |
| 194 | :group 'eshell-mode) | 194 | :group 'eshell-mode) |
| 195 | 195 | ||
| 196 | (define-obsolete-variable-alias 'eshell-status-in-modeline | ||
| 197 | 'eshell-status-in-mode-line "24.3") | ||
| 198 | |||
| 196 | (defcustom eshell-status-in-mode-line t | 199 | (defcustom eshell-status-in-mode-line t |
| 197 | "If non-nil, let the user know a command is running in the mode line." | 200 | "If non-nil, let the user know a command is running in the mode line." |
| 198 | :type 'boolean | 201 | :type 'boolean |
| 199 | :group 'eshell-mode) | 202 | :group 'eshell-mode) |
| 200 | 203 | ||
| 201 | (define-obsolete-variable-alias 'eshell-status-in-modeline | ||
| 202 | 'eshell-status-in-mode-line "24.3") | ||
| 203 | |||
| 204 | (defvar eshell-first-time-p t | 204 | (defvar eshell-first-time-p t |
| 205 | "A variable which is non-nil the first time Eshell is loaded.") | 205 | "A variable which is non-nil the first time Eshell is loaded.") |
| 206 | 206 | ||
diff --git a/lisp/files.el b/lisp/files.el index c3f9e1ef1a0..e030aff0ae2 100644 --- a/lisp/files.el +++ b/lisp/files.el | |||
| @@ -2326,6 +2326,8 @@ ARC\\|ZIP\\|LZH\\|LHA\\|ZOO\\|[JEW]AR\\|XPI\\|RAR\\|7Z\\)\\'" . archive-mode) | |||
| 2326 | ("\\.js\\'" . javascript-mode) | 2326 | ("\\.js\\'" . javascript-mode) |
| 2327 | ("\\.json\\'" . javascript-mode) | 2327 | ("\\.json\\'" . javascript-mode) |
| 2328 | ("\\.[ds]?vh?\\'" . verilog-mode) | 2328 | ("\\.[ds]?vh?\\'" . verilog-mode) |
| 2329 | ("\\.by\\'" . bovine-grammar-mode) | ||
| 2330 | ("\\.wy\\'" . wisent-grammar-mode) | ||
| 2329 | ;; .emacs or .gnus or .viper following a directory delimiter in | 2331 | ;; .emacs or .gnus or .viper following a directory delimiter in |
| 2330 | ;; Unix, MSDOG or VMS syntax. | 2332 | ;; Unix, MSDOG or VMS syntax. |
| 2331 | ("[]>:/\\]\\..*\\(emacs\\|gnus\\|viper\\)\\'" . emacs-lisp-mode) | 2333 | ("[]>:/\\]\\..*\\(emacs\\|gnus\\|viper\\)\\'" . emacs-lisp-mode) |
diff --git a/lisp/gnus/ChangeLog b/lisp/gnus/ChangeLog index 983d09e2589..f79353ebfb3 100644 --- a/lisp/gnus/ChangeLog +++ b/lisp/gnus/ChangeLog | |||
| @@ -1,3 +1,12 @@ | |||
| 1 | 2012-10-06 Glenn Morris <rgm@gnu.org> | ||
| 2 | |||
| 3 | * gnus-notifications.el (gnus-notifications): | ||
| 4 | Add missing group :version tag. | ||
| 5 | * gnus-msg.el (gnus-gcc-pre-body-encode-hook) | ||
| 6 | (gnus-gcc-post-body-encode-hook): | ||
| 7 | * gnus-sync.el (gnus-sync-lesync-name) | ||
| 8 | (gnus-sync-lesync-install-topics): Add missing custom :version tags. | ||
| 9 | |||
| 1 | 2012-09-25 Katsumi Yamaoka <yamaoka@jpl.org> | 10 | 2012-09-25 Katsumi Yamaoka <yamaoka@jpl.org> |
| 2 | 11 | ||
| 3 | * gnus-art.el (gnus-article-browse-delete-temp-files): Never ask again | 12 | * gnus-art.el (gnus-article-browse-delete-temp-files): Never ask again |
diff --git a/lisp/gnus/gnus-msg.el b/lisp/gnus/gnus-msg.el index c2f79e70d1e..77bb6281bc4 100644 --- a/lisp/gnus/gnus-msg.el +++ b/lisp/gnus/gnus-msg.el | |||
| @@ -319,6 +319,7 @@ The current buffer (when the hook is run) contains the message | |||
| 319 | including the message header. Changes made to the message will | 319 | including the message header. Changes made to the message will |
| 320 | only affect the Gcc copy, but not the original message." | 320 | only affect the Gcc copy, but not the original message." |
| 321 | :group 'gnus-message | 321 | :group 'gnus-message |
| 322 | :version "24.3" | ||
| 322 | :type 'hook) | 323 | :type 'hook) |
| 323 | 324 | ||
| 324 | (defcustom gnus-gcc-post-body-encode-hook nil | 325 | (defcustom gnus-gcc-post-body-encode-hook nil |
| @@ -327,6 +328,7 @@ The current buffer (when the hook is run) contains the message | |||
| 327 | including the message header. Changes made to the message will | 328 | including the message header. Changes made to the message will |
| 328 | only affect the Gcc copy, but not the original message." | 329 | only affect the Gcc copy, but not the original message." |
| 329 | :group 'gnus-message | 330 | :group 'gnus-message |
| 331 | :version "24.3" | ||
| 330 | :type 'hook) | 332 | :type 'hook) |
| 331 | 333 | ||
| 332 | (autoload 'gnus-message-citation-mode "gnus-cite" nil t) | 334 | (autoload 'gnus-message-citation-mode "gnus-cite" nil t) |
diff --git a/lisp/gnus/gnus-notifications.el b/lisp/gnus/gnus-notifications.el index 5104a56c6e7..3848dee8d4f 100644 --- a/lisp/gnus/gnus-notifications.el +++ b/lisp/gnus/gnus-notifications.el | |||
| @@ -42,6 +42,7 @@ | |||
| 42 | 42 | ||
| 43 | (defgroup gnus-notifications nil | 43 | (defgroup gnus-notifications nil |
| 44 | "Send notifications on new message in Gnus." | 44 | "Send notifications on new message in Gnus." |
| 45 | :version "24.3" | ||
| 45 | :group 'gnus) | 46 | :group 'gnus) |
| 46 | 47 | ||
| 47 | (defcustom gnus-notifications-use-google-contacts t | 48 | (defcustom gnus-notifications-use-google-contacts t |
diff --git a/lisp/gnus/gnus-sync.el b/lisp/gnus/gnus-sync.el index ca8662ff936..b5f8379e367 100644 --- a/lisp/gnus/gnus-sync.el +++ b/lisp/gnus/gnus-sync.el | |||
| @@ -134,11 +134,13 @@ and `gnus-topic-alist'. Also see `gnus-variable-list'." | |||
| 134 | (defcustom gnus-sync-lesync-name (system-name) | 134 | (defcustom gnus-sync-lesync-name (system-name) |
| 135 | "The LeSync name for this machine." | 135 | "The LeSync name for this machine." |
| 136 | :group 'gnus-sync | 136 | :group 'gnus-sync |
| 137 | :version "24.3" | ||
| 137 | :type 'string) | 138 | :type 'string) |
| 138 | 139 | ||
| 139 | (defcustom gnus-sync-lesync-install-topics 'ask | 140 | (defcustom gnus-sync-lesync-install-topics 'ask |
| 140 | "Should LeSync install the recorded topics?" | 141 | "Should LeSync install the recorded topics?" |
| 141 | :group 'gnus-sync | 142 | :group 'gnus-sync |
| 143 | :version "24.3" | ||
| 142 | :type '(choice (const :tag "Never Install" nil) | 144 | :type '(choice (const :tag "Never Install" nil) |
| 143 | (const :tag "Always Install" t) | 145 | (const :tag "Always Install" t) |
| 144 | (const :tag "Ask Me Once" ask))) | 146 | (const :tag "Ask Me Once" ask))) |
diff --git a/lisp/hi-lock.el b/lisp/hi-lock.el index f92e2ab0af2..59743124cc5 100644 --- a/lisp/hi-lock.el +++ b/lisp/hi-lock.el | |||
| @@ -444,8 +444,8 @@ updated as you type." | |||
| 444 | ;;;###autoload | 444 | ;;;###autoload |
| 445 | (defun hi-lock-face-phrase-buffer (regexp &optional face) | 445 | (defun hi-lock-face-phrase-buffer (regexp &optional face) |
| 446 | "Set face of each match of phrase REGEXP to FACE. | 446 | "Set face of each match of phrase REGEXP to FACE. |
| 447 | Whitespace in REGEXP converted to arbitrary whitespace and initial | 447 | If called interactively, replaces whitespace in REGEXP with |
| 448 | lower-case letters made case insensitive. | 448 | arbitrary whitespace and makes initial lower-case letters case-insensitive. |
| 449 | 449 | ||
| 450 | If Font Lock mode is enabled in the buffer, it is used to | 450 | If Font Lock mode is enabled in the buffer, it is used to |
| 451 | highlight REGEXP. If Font Lock mode is disabled, overlays are | 451 | highlight REGEXP. If Font Lock mode is disabled, overlays are |
| @@ -544,9 +544,15 @@ be found in variable `hi-lock-interactive-patterns'." | |||
| 544 | Blanks in PHRASE replaced by regexp that matches arbitrary whitespace | 544 | Blanks in PHRASE replaced by regexp that matches arbitrary whitespace |
| 545 | and initial lower-case letters made case insensitive." | 545 | and initial lower-case letters made case insensitive." |
| 546 | (let ((mod-phrase nil)) | 546 | (let ((mod-phrase nil)) |
| 547 | ;; FIXME fragile; better to just bind case-fold-search? (Bug#7161) | ||
| 547 | (setq mod-phrase | 548 | (setq mod-phrase |
| 548 | (replace-regexp-in-string | 549 | (replace-regexp-in-string |
| 549 | "\\<[a-z]" (lambda (m) (format "[%s%s]" (upcase m) m)) phrase)) | 550 | "\\(^\\|\\s-\\)\\([a-z]\\)" |
| 551 | (lambda (m) (format "%s[%s%s]" | ||
| 552 | (match-string 1 m) | ||
| 553 | (upcase (match-string 2 m)) | ||
| 554 | (match-string 2 m))) phrase)) | ||
| 555 | ;; FIXME fragile; better to use search-spaces-regexp? | ||
| 550 | (setq mod-phrase | 556 | (setq mod-phrase |
| 551 | (replace-regexp-in-string | 557 | (replace-regexp-in-string |
| 552 | "\\s-+" "[ \t\n]+" mod-phrase nil t)))) | 558 | "\\s-+" "[ \t\n]+" mod-phrase nil t)))) |
diff --git a/lisp/mail/rmail.el b/lisp/mail/rmail.el index 828cd6e72e7..c75a1989e8e 100644 --- a/lisp/mail/rmail.el +++ b/lisp/mail/rmail.el | |||
| @@ -4605,7 +4605,7 @@ With prefix argument N moves forward N messages with these labels. | |||
| 4605 | 4605 | ||
| 4606 | ;;;*** | 4606 | ;;;*** |
| 4607 | 4607 | ||
| 4608 | ;;;### (autoloads (rmail-mime) "rmailmm" "rmailmm.el" "0c18b83f914803d1216e1a9df7ea5275") | 4608 | ;;;### (autoloads (rmail-mime) "rmailmm" "rmailmm.el" "f1937f85a1258de8880a089fa5ae5621") |
| 4609 | ;;; Generated autoloads from rmailmm.el | 4609 | ;;; Generated autoloads from rmailmm.el |
| 4610 | 4610 | ||
| 4611 | (autoload 'rmail-mime "rmailmm" "\ | 4611 | (autoload 'rmail-mime "rmailmm" "\ |
diff --git a/lisp/mail/rmailmm.el b/lisp/mail/rmailmm.el index 2cc57963ef7..11bccd59765 100644 --- a/lisp/mail/rmailmm.el +++ b/lisp/mail/rmailmm.el | |||
| @@ -832,7 +832,7 @@ The other arguments are the same as `rmail-mime-multipart-handler'." | |||
| 832 | (let ((boundary (cdr (assq 'boundary content-type))) | 832 | (let ((boundary (cdr (assq 'boundary content-type))) |
| 833 | (subtype (cadr (split-string (car content-type) "/"))) | 833 | (subtype (cadr (split-string (car content-type) "/"))) |
| 834 | (index 0) | 834 | (index 0) |
| 835 | beg end next entities truncated) | 835 | beg end next entities truncated last) |
| 836 | (unless boundary | 836 | (unless boundary |
| 837 | (rmail-mm-get-boundary-error-message | 837 | (rmail-mm-get-boundary-error-message |
| 838 | "No boundary defined" content-type content-disposition | 838 | "No boundary defined" content-type content-disposition |
| @@ -867,7 +867,13 @@ The other arguments are the same as `rmail-mime-multipart-handler'." | |||
| 867 | ;; Handle the rest of the truncated message | 867 | ;; Handle the rest of the truncated message |
| 868 | ;; (if it isn't empty) by pretending that the boundary | 868 | ;; (if it isn't empty) by pretending that the boundary |
| 869 | ;; appears at the end of the message. | 869 | ;; appears at the end of the message. |
| 870 | (and (save-excursion | 870 | ;; We use `last' to distinguish this from the more |
| 871 | ;; likely situation of there being an epilogue | ||
| 872 | ;; after the last boundary, which should be ignored. | ||
| 873 | ;; See rmailmm-test-multipart-handler for an example, | ||
| 874 | ;; and also bug#10101. | ||
| 875 | (and (not last) | ||
| 876 | (save-excursion | ||
| 871 | (skip-chars-forward "\n") | 877 | (skip-chars-forward "\n") |
| 872 | (> (point-max) (point))) | 878 | (> (point-max) (point))) |
| 873 | (setq truncated t end (point-max)))) | 879 | (setq truncated t end (point-max)))) |
| @@ -875,7 +881,8 @@ The other arguments are the same as `rmail-mime-multipart-handler'." | |||
| 875 | ;; epilogue, else hide the boundary only. Use a marker for | 881 | ;; epilogue, else hide the boundary only. Use a marker for |
| 876 | ;; `next' because `rmail-mime-show' may change the buffer. | 882 | ;; `next' because `rmail-mime-show' may change the buffer. |
| 877 | (cond ((looking-at "--[ \t]*$") | 883 | (cond ((looking-at "--[ \t]*$") |
| 878 | (setq next (point-max-marker))) | 884 | (setq next (point-max-marker) |
| 885 | last t)) | ||
| 879 | ((looking-at "[ \t]*\n") | 886 | ((looking-at "[ \t]*\n") |
| 880 | (setq next (copy-marker (match-end 0) t))) | 887 | (setq next (copy-marker (match-end 0) t))) |
| 881 | (truncated | 888 | (truncated |
diff --git a/lisp/minibuffer.el b/lisp/minibuffer.el index cf990019abc..a9be1749423 100644 --- a/lisp/minibuffer.el +++ b/lisp/minibuffer.el | |||
| @@ -632,6 +632,7 @@ That is what completion commands operate on." | |||
| 632 | (defun delete-minibuffer-contents () | 632 | (defun delete-minibuffer-contents () |
| 633 | "Delete all user input in a minibuffer. | 633 | "Delete all user input in a minibuffer. |
| 634 | If the current buffer is not a minibuffer, erase its entire contents." | 634 | If the current buffer is not a minibuffer, erase its entire contents." |
| 635 | (interactive) | ||
| 635 | ;; We used to do `delete-field' here, but when file name shadowing | 636 | ;; We used to do `delete-field' here, but when file name shadowing |
| 636 | ;; is on, the field doesn't cover the entire minibuffer contents. | 637 | ;; is on, the field doesn't cover the entire minibuffer contents. |
| 637 | (delete-region (minibuffer-prompt-end) (point-max))) | 638 | (delete-region (minibuffer-prompt-end) (point-max))) |
diff --git a/lisp/net/tramp.el b/lisp/net/tramp.el index 019ab1eef0f..b1532eb2ae4 100644 --- a/lisp/net/tramp.el +++ b/lisp/net/tramp.el | |||
| @@ -403,6 +403,7 @@ interpreted as a regular expression which always matches." | |||
| 403 | (defcustom tramp-save-ad-hoc-proxies nil | 403 | (defcustom tramp-save-ad-hoc-proxies nil |
| 404 | "Whether to save ad-hoc proxies persistently." | 404 | "Whether to save ad-hoc proxies persistently." |
| 405 | :group 'tramp | 405 | :group 'tramp |
| 406 | :version "24.3" | ||
| 406 | :type 'boolean) | 407 | :type 'boolean) |
| 407 | 408 | ||
| 408 | (defcustom tramp-restricted-shell-hosts-alist | 409 | (defcustom tramp-restricted-shell-hosts-alist |
diff --git a/lisp/proced.el b/lisp/proced.el index ec41ce65ef5..e3ff9fb5c95 100644 --- a/lisp/proced.el +++ b/lisp/proced.el | |||
| @@ -68,6 +68,7 @@ the external command (usually \"kill\")." | |||
| 68 | (defcustom proced-renice-command "renice" | 68 | (defcustom proced-renice-command "renice" |
| 69 | "Name of renice command." | 69 | "Name of renice command." |
| 70 | :group 'proced | 70 | :group 'proced |
| 71 | :version "24.3" | ||
| 71 | :type '(string :tag "command")) | 72 | :type '(string :tag "command")) |
| 72 | 73 | ||
| 73 | (defcustom proced-signal-list | 74 | (defcustom proced-signal-list |
diff --git a/lisp/profiler.el b/lisp/profiler.el index 5e605957833..e9261eb1af7 100644 --- a/lisp/profiler.el +++ b/lisp/profiler.el | |||
| @@ -29,6 +29,7 @@ | |||
| 29 | (defgroup profiler nil | 29 | (defgroup profiler nil |
| 30 | "Emacs profiler." | 30 | "Emacs profiler." |
| 31 | :group 'lisp | 31 | :group 'lisp |
| 32 | :version "24.3" | ||
| 32 | :prefix "profiler-") | 33 | :prefix "profiler-") |
| 33 | 34 | ||
| 34 | (defconst profiler-version "24.3") | 35 | (defconst profiler-version "24.3") |
diff --git a/lisp/progmodes/bug-reference.el b/lisp/progmodes/bug-reference.el index 97fcb6874dd..3561105e59d 100644 --- a/lisp/progmodes/bug-reference.el +++ b/lisp/progmodes/bug-reference.el | |||
| @@ -74,6 +74,7 @@ so that it is considered safe, see `enable-local-variables'.") | |||
| 74 | The second subexpression should match the bug reference (usually a number)." | 74 | The second subexpression should match the bug reference (usually a number)." |
| 75 | :type 'string | 75 | :type 'string |
| 76 | :safe 'stringp | 76 | :safe 'stringp |
| 77 | :version "24.3" ; previously defconst | ||
| 77 | :group 'bug-reference) | 78 | :group 'bug-reference) |
| 78 | 79 | ||
| 79 | (defun bug-reference-set-overlay-properties () | 80 | (defun bug-reference-set-overlay-properties () |
diff --git a/lisp/progmodes/flymake.el b/lisp/progmodes/flymake.el index 10d5fdf9c64..26d4a399c2d 100644 --- a/lisp/progmodes/flymake.el +++ b/lisp/progmodes/flymake.el | |||
| @@ -768,6 +768,7 @@ line number outside the file being compiled." | |||
| 768 | The value may also be a list of two elements where the second | 768 | The value may also be a list of two elements where the second |
| 769 | element specifies the face for the bitmap." | 769 | element specifies the face for the bitmap." |
| 770 | :group 'flymake | 770 | :group 'flymake |
| 771 | :version "24.3" | ||
| 771 | :type 'symbol) | 772 | :type 'symbol) |
| 772 | 773 | ||
| 773 | (defcustom flymake-warning-bitmap 'question-mark | 774 | (defcustom flymake-warning-bitmap 'question-mark |
| @@ -775,6 +776,7 @@ element specifies the face for the bitmap." | |||
| 775 | The value may also be a list of two elements where the second | 776 | The value may also be a list of two elements where the second |
| 776 | element specifies the face for the bitmap." | 777 | element specifies the face for the bitmap." |
| 777 | :group 'flymake | 778 | :group 'flymake |
| 779 | :version "24.3" | ||
| 778 | :type 'symbol) | 780 | :type 'symbol) |
| 779 | 781 | ||
| 780 | (defcustom flymake-fringe-indicator-position 'left-fringe | 782 | (defcustom flymake-fringe-indicator-position 'left-fringe |
| @@ -782,6 +784,7 @@ element specifies the face for the bitmap." | |||
| 782 | The value can be nil, left-fringe or right-fringe. | 784 | The value can be nil, left-fringe or right-fringe. |
| 783 | Fringe indicators are disabled if nil." | 785 | Fringe indicators are disabled if nil." |
| 784 | :group 'flymake | 786 | :group 'flymake |
| 787 | :version "24.3" | ||
| 785 | :type '(choice (const left-fringe) | 788 | :type '(choice (const left-fringe) |
| 786 | (const right-fringe) | 789 | (const right-fringe) |
| 787 | (const :tag "No fringe indicators" nil))) | 790 | (const :tag "No fringe indicators" nil))) |
diff --git a/lisp/progmodes/python.el b/lisp/progmodes/python.el index b3b3b0181d7..726c0b2d542 100644 --- a/lisp/progmodes/python.el +++ b/lisp/progmodes/python.el | |||
| @@ -1667,10 +1667,6 @@ variable. | |||
| 1667 | \(Type \\[describe-mode] in the process buffer for a list of commands.)" | 1667 | \(Type \\[describe-mode] in the process buffer for a list of commands.)" |
| 1668 | (set-syntax-table python-mode-syntax-table) | 1668 | (set-syntax-table python-mode-syntax-table) |
| 1669 | (setq mode-line-process '(":%s")) | 1669 | (setq mode-line-process '(":%s")) |
| 1670 | (setq comint-prompt-regexp (format "^\\(?:%s\\|%s\\|%s\\)" | ||
| 1671 | python-shell-prompt-regexp | ||
| 1672 | python-shell-prompt-block-regexp | ||
| 1673 | python-shell-prompt-pdb-regexp)) | ||
| 1674 | (make-local-variable 'comint-output-filter-functions) | 1670 | (make-local-variable 'comint-output-filter-functions) |
| 1675 | (add-hook 'comint-output-filter-functions | 1671 | (add-hook 'comint-output-filter-functions |
| 1676 | 'python-comint-output-filter-function) | 1672 | 'python-comint-output-filter-function) |
| @@ -1720,7 +1716,11 @@ killed." | |||
| 1720 | (process (get-buffer-process buffer))) | 1716 | (process (get-buffer-process buffer))) |
| 1721 | (with-current-buffer buffer | 1717 | (with-current-buffer buffer |
| 1722 | (inferior-python-mode) | 1718 | (inferior-python-mode) |
| 1723 | (python-util-clone-local-variables current-buffer)) | 1719 | (python-util-clone-local-variables current-buffer) |
| 1720 | (setq comint-prompt-regexp (format "^\\(?:%s\\|%s\\|%s\\)" | ||
| 1721 | python-shell-prompt-regexp | ||
| 1722 | python-shell-prompt-block-regexp | ||
| 1723 | python-shell-prompt-pdb-regexp))) | ||
| 1724 | (accept-process-output process) | 1724 | (accept-process-output process) |
| 1725 | (and pop (pop-to-buffer buffer t)) | 1725 | (and pop (pop-to-buffer buffer t)) |
| 1726 | (and internal (set-process-query-on-exit-flag process nil)))) | 1726 | (and internal (set-process-query-on-exit-flag process nil)))) |
| @@ -1861,26 +1861,39 @@ When MSG is non-nil messages the first line of STRING." | |||
| 1861 | (string-match "\n[ \t].*\n?$" string)) | 1861 | (string-match "\n[ \t].*\n?$" string)) |
| 1862 | (comint-send-string process "\n"))))) | 1862 | (comint-send-string process "\n"))))) |
| 1863 | 1863 | ||
| 1864 | ;; Shell output catching stolen from gud-gdb | 1864 | (defvar python-shell-output-filter-in-progress nil) |
| 1865 | (defvar python-shell-fetch-lines-in-progress nil) | 1865 | (defvar python-shell-output-filter-buffer nil) |
| 1866 | (defvar python-shell-fetch-lines-string nil) | 1866 | |
| 1867 | (defvar python-shell-fetched-lines nil) | 1867 | (defun python-shell-output-filter (string) |
| 1868 | 1868 | "Filter used in `python-shell-send-string-no-output' to grab output. | |
| 1869 | (defun python-shell-fetch-lines-filter (string) | 1869 | STRING is the output received to this point from the process. |
| 1870 | "Filter used to read the list of lines output by a command. | 1870 | This filter saves received output from the process in |
| 1871 | STRING is the output to filter." | 1871 | `python-shell-output-filter-buffer' and stops receiving it after |
| 1872 | (setq string (concat python-shell-fetch-lines-string string)) | 1872 | detecting a prompt at the end of the buffer." |
| 1873 | (while (string-match "\n" string) | 1873 | (setq |
| 1874 | (push (substring string 0 (match-beginning 0)) | 1874 | string (ansi-color-filter-apply string) |
| 1875 | python-shell-fetched-lines) | 1875 | python-shell-output-filter-buffer |
| 1876 | (setq string (substring string (match-end 0)))) | 1876 | (concat python-shell-output-filter-buffer string)) |
| 1877 | (if (equal (string-match comint-prompt-regexp string) 0) | 1877 | (when (string-match |
| 1878 | (progn | 1878 | (format "\n\\(?:%s\\|%s\\|%s\\)$" |
| 1879 | (setq python-shell-fetch-lines-in-progress nil) | 1879 | python-shell-prompt-regexp |
| 1880 | string) | 1880 | python-shell-prompt-block-regexp |
| 1881 | (progn | 1881 | python-shell-prompt-pdb-regexp) |
| 1882 | (setq python-shell-fetch-lines-string string) | 1882 | python-shell-output-filter-buffer) |
| 1883 | ""))) | 1883 | ;; Output ends when `python-shell-output-filter-buffer' contains |
| 1884 | ;; the prompt attached at the end of it. | ||
| 1885 | (setq python-shell-output-filter-in-progress nil | ||
| 1886 | python-shell-output-filter-buffer | ||
| 1887 | (substring python-shell-output-filter-buffer | ||
| 1888 | 0 (match-beginning 0))) | ||
| 1889 | (when (and (> (length python-shell-prompt-output-regexp) 0) | ||
| 1890 | (string-match (concat "^" python-shell-prompt-output-regexp) | ||
| 1891 | python-shell-output-filter-buffer)) | ||
| 1892 | ;; Some shells, like iPython might append a prompt before the | ||
| 1893 | ;; output, clean that. | ||
| 1894 | (setq python-shell-output-filter-buffer | ||
| 1895 | (substring python-shell-output-filter-buffer (match-end 0))))) | ||
| 1896 | "") | ||
| 1884 | 1897 | ||
| 1885 | (defun python-shell-send-string-no-output (string &optional process msg) | 1898 | (defun python-shell-send-string-no-output (string &optional process msg) |
| 1886 | "Send STRING to PROCESS and inhibit output. | 1899 | "Send STRING to PROCESS and inhibit output. |
| @@ -1888,18 +1901,20 @@ When MSG is non-nil messages the first line of STRING. Return | |||
| 1888 | the output." | 1901 | the output." |
| 1889 | (let ((process (or process (python-shell-get-or-create-process))) | 1902 | (let ((process (or process (python-shell-get-or-create-process))) |
| 1890 | (comint-preoutput-filter-functions | 1903 | (comint-preoutput-filter-functions |
| 1891 | '(python-shell-fetch-lines-filter)) | 1904 | '(python-shell-output-filter)) |
| 1892 | (python-shell-fetch-lines-in-progress t) | 1905 | (python-shell-output-filter-in-progress t) |
| 1893 | (inhibit-quit t)) | 1906 | (inhibit-quit t)) |
| 1894 | (or | 1907 | (or |
| 1895 | (with-local-quit | 1908 | (with-local-quit |
| 1896 | (python-shell-send-string string process msg) | 1909 | (python-shell-send-string string process msg) |
| 1897 | (while python-shell-fetch-lines-in-progress | 1910 | (while python-shell-output-filter-in-progress |
| 1911 | ;; `python-shell-output-filter' takes care of setting | ||
| 1912 | ;; `python-shell-output-filter-in-progress' to NIL after it | ||
| 1913 | ;; detects end of output. | ||
| 1898 | (accept-process-output process)) | 1914 | (accept-process-output process)) |
| 1899 | (prog1 | 1915 | (prog1 |
| 1900 | (mapconcat #'identity | 1916 | python-shell-output-filter-buffer |
| 1901 | (reverse python-shell-fetched-lines) "\n") | 1917 | (setq python-shell-output-filter-buffer nil))) |
| 1902 | (setq python-shell-fetched-lines nil))) | ||
| 1903 | (with-current-buffer (process-buffer process) | 1918 | (with-current-buffer (process-buffer process) |
| 1904 | (comint-interrupt-subjob))))) | 1919 | (comint-interrupt-subjob))))) |
| 1905 | 1920 | ||
diff --git a/lisp/progmodes/sh-script.el b/lisp/progmodes/sh-script.el index e94919ee2a9..06ded5fb53d 100644 --- a/lisp/progmodes/sh-script.el +++ b/lisp/progmodes/sh-script.el | |||
| @@ -1767,7 +1767,9 @@ Does not preserve point." | |||
| 1767 | 1767 | ||
| 1768 | (defcustom sh-indent-after-continuation t | 1768 | (defcustom sh-indent-after-continuation t |
| 1769 | "If non-nil, try to make sure text is indented after a line continuation." | 1769 | "If non-nil, try to make sure text is indented after a line continuation." |
| 1770 | :type 'boolean) | 1770 | :version "24.3" |
| 1771 | :type 'boolean | ||
| 1772 | :group 'sh-indentation) | ||
| 1771 | 1773 | ||
| 1772 | (defun sh-smie--continuation-start-indent () | 1774 | (defun sh-smie--continuation-start-indent () |
| 1773 | "Return the initial indentation of a continued line. | 1775 | "Return the initial indentation of a continued line. |
diff --git a/lisp/progmodes/verilog-mode.el b/lisp/progmodes/verilog-mode.el index 8c4167b6724..6ffe88f721e 100644 --- a/lisp/progmodes/verilog-mode.el +++ b/lisp/progmodes/verilog-mode.el | |||
| @@ -1159,6 +1159,7 @@ See the \\[verilog-faq] for examples on using this." | |||
| 1159 | "Non-nil means report warning if an AUTO_TEMPLATE line is not used. | 1159 | "Non-nil means report warning if an AUTO_TEMPLATE line is not used. |
| 1160 | This feature is not supported before Emacs 21.1 or XEmacs 21.4." | 1160 | This feature is not supported before Emacs 21.1 or XEmacs 21.4." |
| 1161 | :group 'verilog-mode-auto | 1161 | :group 'verilog-mode-auto |
| 1162 | :version "24.3" | ||
| 1162 | :type 'boolean) | 1163 | :type 'boolean) |
| 1163 | (put 'verilog-auto-template-warn-unused 'safe-local-variable 'verilog-booleanp) | 1164 | (put 'verilog-auto-template-warn-unused 'safe-local-variable 'verilog-booleanp) |
| 1164 | 1165 | ||
| @@ -1230,11 +1231,13 @@ For example, \"_t$\" matches typedefs named with _t, as in the C language." | |||
| 1230 | (defcustom verilog-before-save-font-hook nil | 1231 | (defcustom verilog-before-save-font-hook nil |
| 1231 | "Hook run before `verilog-save-font-mods' removes highlighting." | 1232 | "Hook run before `verilog-save-font-mods' removes highlighting." |
| 1232 | :group 'verilog-mode-auto | 1233 | :group 'verilog-mode-auto |
| 1234 | :version "24.3" | ||
| 1233 | :type 'hook) | 1235 | :type 'hook) |
| 1234 | 1236 | ||
| 1235 | (defcustom verilog-after-save-font-hook nil | 1237 | (defcustom verilog-after-save-font-hook nil |
| 1236 | "Hook run after `verilog-save-font-mods' restores highlighting." | 1238 | "Hook run after `verilog-save-font-mods' restores highlighting." |
| 1237 | :group 'verilog-mode-auto | 1239 | :group 'verilog-mode-auto |
| 1240 | :version "24.3" | ||
| 1238 | :type 'hook) | 1241 | :type 'hook) |
| 1239 | 1242 | ||
| 1240 | (defvar verilog-imenu-generic-expression | 1243 | (defvar verilog-imenu-generic-expression |
diff --git a/lisp/progmodes/vhdl-mode.el b/lisp/progmodes/vhdl-mode.el index 52757b9eede..6ad7d3b168a 100644 --- a/lisp/progmodes/vhdl-mode.el +++ b/lisp/progmodes/vhdl-mode.el | |||
| @@ -483,6 +483,7 @@ with other user Makefiles." | |||
| 483 | :type '(list (string :tag "Compile entire design") | 483 | :type '(list (string :tag "Compile entire design") |
| 484 | (string :tag "Clean entire design ") | 484 | (string :tag "Clean entire design ") |
| 485 | (string :tag "Create design library")) | 485 | (string :tag "Create design library")) |
| 486 | :version "24.3" | ||
| 486 | :group 'vhdl-compile) | 487 | :group 'vhdl-compile) |
| 487 | 488 | ||
| 488 | (defcustom vhdl-makefile-generation-hook nil | 489 | (defcustom vhdl-makefile-generation-hook nil |
| @@ -772,6 +773,7 @@ index, the record field or array index is included with the record name in | |||
| 772 | the sensitivity list (e.g. \"in1(0)\", \"in2.f0\"). | 773 | the sensitivity list (e.g. \"in1(0)\", \"in2.f0\"). |
| 773 | Otherwise, only the record name is included (e.g. \"in1\", \"in2\")." | 774 | Otherwise, only the record name is included (e.g. \"in1\", \"in2\")." |
| 774 | :type 'boolean | 775 | :type 'boolean |
| 776 | :version "24.3" | ||
| 775 | :group 'vhdl-style) | 777 | :group 'vhdl-style) |
| 776 | 778 | ||
| 777 | (defgroup vhdl-naming nil | 779 | (defgroup vhdl-naming nil |
| @@ -1849,6 +1851,7 @@ Otherwise, comment lines are indented like the preceding code line. | |||
| 1849 | Indenting comment lines like the following code line gives nicer indentation | 1851 | Indenting comment lines like the following code line gives nicer indentation |
| 1850 | when comments precede the code that they refer to." | 1852 | when comments precede the code that they refer to." |
| 1851 | :type 'boolean | 1853 | :type 'boolean |
| 1854 | :version "24.3" | ||
| 1852 | :group 'vhdl-misc) | 1855 | :group 'vhdl-misc) |
| 1853 | 1856 | ||
| 1854 | (defcustom vhdl-word-completion-case-sensitive nil | 1857 | (defcustom vhdl-word-completion-case-sensitive nil |
diff --git a/lisp/register.el b/lisp/register.el index fb35a26a653..7c2d9337fa2 100644 --- a/lisp/register.el +++ b/lisp/register.el | |||
| @@ -382,6 +382,7 @@ START and END are buffer positions indicating what to append." | |||
| 382 | register (cond ((not reg) text) | 382 | register (cond ((not reg) text) |
| 383 | ((stringp reg) (concat reg separator text)) | 383 | ((stringp reg) (concat reg separator text)) |
| 384 | (t (error "Register does not contain text"))))) | 384 | (t (error "Register does not contain text"))))) |
| 385 | (setq deactivate-mark t) | ||
| 385 | (cond (delete-flag | 386 | (cond (delete-flag |
| 386 | (delete-region start end)) | 387 | (delete-region start end)) |
| 387 | ((called-interactively-p 'interactive) | 388 | ((called-interactively-p 'interactive) |
| @@ -400,6 +401,7 @@ START and END are buffer positions indicating what to prepend." | |||
| 400 | register (cond ((not reg) text) | 401 | register (cond ((not reg) text) |
| 401 | ((stringp reg) (concat text separator reg)) | 402 | ((stringp reg) (concat text separator reg)) |
| 402 | (t (error "Register does not contain text"))))) | 403 | (t (error "Register does not contain text"))))) |
| 404 | (setq deactivate-mark t) | ||
| 403 | (cond (delete-flag | 405 | (cond (delete-flag |
| 404 | (delete-region start end)) | 406 | (delete-region start end)) |
| 405 | ((called-interactively-p 'interactive) | 407 | ((called-interactively-p 'interactive) |
diff --git a/lisp/strokes.el b/lisp/strokes.el index 62a8528f25d..9a3a7608d2b 100644 --- a/lisp/strokes.el +++ b/lisp/strokes.el | |||
| @@ -212,13 +212,14 @@ static char * stroke_xpm[] = { | |||
| 212 | :link '(emacs-commentary-link "strokes") | 212 | :link '(emacs-commentary-link "strokes") |
| 213 | :group 'mouse) | 213 | :group 'mouse) |
| 214 | 214 | ||
| 215 | (define-obsolete-variable-alias 'strokes-modeline-string 'strokes-lighter | ||
| 216 | "24.3") | ||
| 217 | |||
| 215 | (defcustom strokes-lighter " Strokes" | 218 | (defcustom strokes-lighter " Strokes" |
| 216 | "Mode line identifier for Strokes mode." | 219 | "Mode line identifier for Strokes mode." |
| 217 | :type 'string | 220 | :type 'string |
| 218 | :group 'strokes) | 221 | :group 'strokes) |
| 219 | 222 | ||
| 220 | (define-obsolete-variable-alias 'strokes-modeline-string 'strokes-lighter "24.3") | ||
| 221 | |||
| 222 | (defcustom strokes-character ?@ | 223 | (defcustom strokes-character ?@ |
| 223 | "Character used when drawing strokes in the strokes buffer. | 224 | "Character used when drawing strokes in the strokes buffer. |
| 224 | \(The default is `@', which works well.\)" | 225 | \(The default is `@', which works well.\)" |
diff --git a/lisp/subr.el b/lisp/subr.el index 72bedc69c3c..e438a860cbc 100644 --- a/lisp/subr.el +++ b/lisp/subr.el | |||
| @@ -2143,6 +2143,13 @@ any other non-digit terminates the character code and is then used as input.")) | |||
| 2143 | (setq first nil)) | 2143 | (setq first nil)) |
| 2144 | code)) | 2144 | code)) |
| 2145 | 2145 | ||
| 2146 | (defconst read-passwd-map | ||
| 2147 | (let ((map (make-sparse-keymap))) | ||
| 2148 | (set-keymap-parent map minibuffer-local-map) | ||
| 2149 | (define-key map "\C-u" #'delete-minibuffer-contents) ;bug#12570 | ||
| 2150 | map) | ||
| 2151 | "Keymap used while reading passwords.") | ||
| 2152 | |||
| 2146 | (defun read-passwd (prompt &optional confirm default) | 2153 | (defun read-passwd (prompt &optional confirm default) |
| 2147 | "Read a password, prompting with PROMPT, and return it. | 2154 | "Read a password, prompting with PROMPT, and return it. |
| 2148 | If optional CONFIRM is non-nil, read the password twice to make sure. | 2155 | If optional CONFIRM is non-nil, read the password twice to make sure. |
| @@ -2180,18 +2187,11 @@ by doing (clear-string STRING)." | |||
| 2180 | (setq minibuf (current-buffer)) | 2187 | (setq minibuf (current-buffer)) |
| 2181 | ;; Turn off electricity. | 2188 | ;; Turn off electricity. |
| 2182 | (set (make-local-variable 'post-self-insert-hook) nil) | 2189 | (set (make-local-variable 'post-self-insert-hook) nil) |
| 2190 | (use-local-map read-passwd-map) | ||
| 2183 | (add-hook 'after-change-functions hide-chars-fun nil 'local)) | 2191 | (add-hook 'after-change-functions hide-chars-fun nil 'local)) |
| 2184 | (unwind-protect | 2192 | (unwind-protect |
| 2185 | (let ((enable-recursive-minibuffers t) | 2193 | (let ((enable-recursive-minibuffers t)) |
| 2186 | (map minibuffer-local-map) | 2194 | (read-string prompt nil t default)) ; t = "no history" |
| 2187 | result) | ||
| 2188 | (define-key map "\C-u" ; bug#12570 | ||
| 2189 | (lambda () (interactive) (delete-minibuffer-contents))) | ||
| 2190 | (setq result | ||
| 2191 | ;; t = no history. | ||
| 2192 | (read-from-minibuffer prompt nil map nil t default)) | ||
| 2193 | (if (and (equal "" result) default) default | ||
| 2194 | result)) | ||
| 2195 | (when (buffer-live-p minibuf) | 2195 | (when (buffer-live-p minibuf) |
| 2196 | (with-current-buffer minibuf | 2196 | (with-current-buffer minibuf |
| 2197 | ;; Not sure why but it seems that there might be cases where the | 2197 | ;; Not sure why but it seems that there might be cases where the |
diff --git a/lisp/textmodes/reftex-vars.el b/lisp/textmodes/reftex-vars.el index df3d729adca..2c1fc972057 100644 --- a/lisp/textmodes/reftex-vars.el +++ b/lisp/textmodes/reftex-vars.el | |||
| @@ -968,6 +968,7 @@ the macro type is being prompted for. (See also | |||
| 968 | `reftex-ref-macro-prompt'.) The keys, represented as characters, | 968 | `reftex-ref-macro-prompt'.) The keys, represented as characters, |
| 969 | have to be unique." | 969 | have to be unique." |
| 970 | :group 'reftex-referencing-labels | 970 | :group 'reftex-referencing-labels |
| 971 | :version "24.3" | ||
| 971 | :type '(alist :key-type (string :tag "Style name") | 972 | :type '(alist :key-type (string :tag "Style name") |
| 972 | :value-type (group (choice :tag "Package" | 973 | :value-type (group (choice :tag "Package" |
| 973 | (const :tag "Any package" t) | 974 | (const :tag "Any package" t) |
| @@ -979,6 +980,7 @@ have to be unique." | |||
| 979 | (defcustom reftex-ref-macro-prompt t | 980 | (defcustom reftex-ref-macro-prompt t |
| 980 | "If non-nil, `reftex-reference' prompts for the reference macro." | 981 | "If non-nil, `reftex-reference' prompts for the reference macro." |
| 981 | :group 'reftex-referencing-labels | 982 | :group 'reftex-referencing-labels |
| 983 | :version "24.3" | ||
| 982 | :type 'boolean) | 984 | :type 'boolean) |
| 983 | 985 | ||
| 984 | (defcustom reftex-vref-is-default nil | 986 | (defcustom reftex-vref-is-default nil |
| @@ -1014,6 +1016,7 @@ can be cycled in the buffer for selecting a label. The entries | |||
| 1014 | in the list have to match the respective reference style names | 1016 | in the list have to match the respective reference style names |
| 1015 | used in the variable `reftex-ref-style-alist'." | 1017 | used in the variable `reftex-ref-style-alist'." |
| 1016 | :group 'reftex-referencing-labels | 1018 | :group 'reftex-referencing-labels |
| 1019 | :version "24.3" | ||
| 1017 | :type `(set ,@(mapcar (lambda (x) (list 'const (car x))) | 1020 | :type `(set ,@(mapcar (lambda (x) (list 'const (car x))) |
| 1018 | reftex-ref-style-alist))) | 1021 | reftex-ref-style-alist))) |
| 1019 | 1022 | ||
| @@ -1257,17 +1260,20 @@ should return the string to insert into the buffer." | |||
| 1257 | (defcustom reftex-cite-key-separator "," | 1260 | (defcustom reftex-cite-key-separator "," |
| 1258 | "String to be used for separating several keys in a \\cite macro." | 1261 | "String to be used for separating several keys in a \\cite macro." |
| 1259 | :group 'reftex-citation-support | 1262 | :group 'reftex-citation-support |
| 1263 | :version "24.3" | ||
| 1260 | :type 'string) | 1264 | :type 'string) |
| 1261 | 1265 | ||
| 1262 | (defcustom reftex-create-bibtex-header nil | 1266 | (defcustom reftex-create-bibtex-header nil |
| 1263 | "Header to insert in BibTeX files generated by RefTeX." | 1267 | "Header to insert in BibTeX files generated by RefTeX." |
| 1264 | :group 'reftex-citation-support | 1268 | :group 'reftex-citation-support |
| 1265 | :type 'string) | 1269 | :version "24.3" |
| 1270 | :type '(choice (const :tag "No header" nil) string)) | ||
| 1266 | 1271 | ||
| 1267 | (defcustom reftex-create-bibtex-footer nil | 1272 | (defcustom reftex-create-bibtex-footer nil |
| 1268 | "Footer to insert in BibTeX files generated by RefTeX." | 1273 | "Footer to insert in BibTeX files generated by RefTeX." |
| 1269 | :group 'reftex-citation-support | 1274 | :group 'reftex-citation-support |
| 1270 | :type 'string) | 1275 | :version "24.3" |
| 1276 | :type '(choice (const :tag "No footer" nil) string)) | ||
| 1271 | 1277 | ||
| 1272 | ;; Index Support Configuration | 1278 | ;; Index Support Configuration |
| 1273 | 1279 | ||
diff --git a/lisp/textmodes/rst.el b/lisp/textmodes/rst.el index 869da63064a..f2c74dfb941 100644 --- a/lisp/textmodes/rst.el +++ b/lisp/textmodes/rst.el | |||
| @@ -218,7 +218,7 @@ and before TAIL-RE and DELIM-RE in VAR or DEFAULT for no match." | |||
| 218 | ;; Use CVSHeader to really get information from CVS and not other version | 218 | ;; Use CVSHeader to really get information from CVS and not other version |
| 219 | ;; control systems. | 219 | ;; control systems. |
| 220 | (defconst rst-cvs-header | 220 | (defconst rst-cvs-header |
| 221 | "$CVSHeader: sm/rst_el/rst.el,v 1.327.2.2 2012-09-23 14:44:25 stefan Exp $") | 221 | "$CVSHeader: sm/rst_el/rst.el,v 1.327.2.5 2012-10-07 12:44:34 stefan Exp $") |
| 222 | (defconst rst-cvs-rev | 222 | (defconst rst-cvs-rev |
| 223 | (rst-extract-version "\\$" "CVSHeader: \\S + " "[0-9]+\\(?:\\.[0-9]+\\)+" | 223 | (rst-extract-version "\\$" "CVSHeader: \\S + " "[0-9]+\\(?:\\.[0-9]+\\)+" |
| 224 | " .*" rst-cvs-header "0.0") | 224 | " .*" rst-cvs-header "0.0") |
| @@ -247,7 +247,7 @@ SVN revision is the upstream (docutils) revision.") | |||
| 247 | "Official version of the package.") | 247 | "Official version of the package.") |
| 248 | (defconst rst-official-cvs-rev | 248 | (defconst rst-official-cvs-rev |
| 249 | (rst-extract-version "[%$]" "Revision: " "[0-9]+\\(?:\\.[0-9]+\\)+" " " | 249 | (rst-extract-version "[%$]" "Revision: " "[0-9]+\\(?:\\.[0-9]+\\)+" " " |
| 250 | "$Revision: 1.327.2.2 $") | 250 | "$Revision: 1.327.2.5 $") |
| 251 | "CVS revision of this file in the official version.") | 251 | "CVS revision of this file in the official version.") |
| 252 | 252 | ||
| 253 | (defconst rst-version | 253 | (defconst rst-version |
| @@ -967,7 +967,7 @@ for modes derived from Text mode, like Mail mode." | |||
| 967 | :version "21.1") | 967 | :version "21.1") |
| 968 | 968 | ||
| 969 | (define-obsolete-variable-alias | 969 | (define-obsolete-variable-alias |
| 970 | 'rst-preferred-decorations 'rst-preferred-adornments "1.0.0") | 970 | 'rst-preferred-decorations 'rst-preferred-adornments "rst 1.0.0") |
| 971 | (defcustom rst-preferred-adornments '((?= over-and-under 1) | 971 | (defcustom rst-preferred-adornments '((?= over-and-under 1) |
| 972 | (?= simple 0) | 972 | (?= simple 0) |
| 973 | (?- simple 0) | 973 | (?- simple 0) |
| @@ -2835,7 +2835,7 @@ here." | |||
| 2835 | :package-version '(rst . "1.1.0")) | 2835 | :package-version '(rst . "1.1.0")) |
| 2836 | 2836 | ||
| 2837 | (define-obsolete-variable-alias | 2837 | (define-obsolete-variable-alias |
| 2838 | 'rst-shift-basic-offset 'rst-indent-width "1.0.0") | 2838 | 'rst-shift-basic-offset 'rst-indent-width "rst 1.0.0") |
| 2839 | (defcustom rst-indent-width 2 | 2839 | (defcustom rst-indent-width 2 |
| 2840 | "Indentation when there is no more indentation point given." | 2840 | "Indentation when there is no more indentation point given." |
| 2841 | :group 'rst-indent | 2841 | :group 'rst-indent |
| @@ -2845,24 +2845,28 @@ here." | |||
| 2845 | (defcustom rst-indent-field 3 | 2845 | (defcustom rst-indent-field 3 |
| 2846 | "Indentation for first line after a field or 0 to always indent for content." | 2846 | "Indentation for first line after a field or 0 to always indent for content." |
| 2847 | :group 'rst-indent | 2847 | :group 'rst-indent |
| 2848 | :package-version '(rst . "1.1.0") | ||
| 2848 | :type '(integer)) | 2849 | :type '(integer)) |
| 2849 | (rst-testcover-defcustom) | 2850 | (rst-testcover-defcustom) |
| 2850 | 2851 | ||
| 2851 | (defcustom rst-indent-literal-normal 3 | 2852 | (defcustom rst-indent-literal-normal 3 |
| 2852 | "Default indentation for literal block after a markup on an own line." | 2853 | "Default indentation for literal block after a markup on an own line." |
| 2853 | :group 'rst-indent | 2854 | :group 'rst-indent |
| 2855 | :package-version '(rst . "1.1.0") | ||
| 2854 | :type '(integer)) | 2856 | :type '(integer)) |
| 2855 | (rst-testcover-defcustom) | 2857 | (rst-testcover-defcustom) |
| 2856 | 2858 | ||
| 2857 | (defcustom rst-indent-literal-minimized 2 | 2859 | (defcustom rst-indent-literal-minimized 2 |
| 2858 | "Default indentation for literal block after a minimized markup." | 2860 | "Default indentation for literal block after a minimized markup." |
| 2859 | :group 'rst-indent | 2861 | :group 'rst-indent |
| 2862 | :package-version '(rst . "1.1.0") | ||
| 2860 | :type '(integer)) | 2863 | :type '(integer)) |
| 2861 | (rst-testcover-defcustom) | 2864 | (rst-testcover-defcustom) |
| 2862 | 2865 | ||
| 2863 | (defcustom rst-indent-comment 3 | 2866 | (defcustom rst-indent-comment 3 |
| 2864 | "Default indentation for first line of a comment." | 2867 | "Default indentation for first line of a comment." |
| 2865 | :group 'rst-indent | 2868 | :group 'rst-indent |
| 2869 | :package-version '(rst . "1.1.0") | ||
| 2866 | :type '(integer)) | 2870 | :type '(integer)) |
| 2867 | (rst-testcover-defcustom) | 2871 | (rst-testcover-defcustom) |
| 2868 | 2872 | ||