diff options
Diffstat (limited to 'lisp/emacs-lisp')
-rw-r--r-- | lisp/emacs-lisp/byte-opt.el | 15 | ||||
-rw-r--r-- | lisp/emacs-lisp/bytecomp.el | 20 | ||||
-rw-r--r-- | lisp/emacs-lisp/cl-macs.el | 2 | ||||
-rw-r--r-- | lisp/emacs-lisp/copyright.el | 10 | ||||
-rw-r--r-- | lisp/emacs-lisp/generic.el | 4 | ||||
-rw-r--r-- | lisp/emacs-lisp/regexp-opt.el | 14 |
6 files changed, 39 insertions, 26 deletions
diff --git a/lisp/emacs-lisp/byte-opt.el b/lisp/emacs-lisp/byte-opt.el index 8c3fcffbc7d..db6d96ee9a0 100644 --- a/lisp/emacs-lisp/byte-opt.el +++ b/lisp/emacs-lisp/byte-opt.el @@ -1221,8 +1221,9 @@ of FORM by signaling the error at compile-time." char-equal char-to-string char-width compare-strings concat coordinates-in-window-p copy-alist copy-sequence copy-marker cos count-lines + decdoe-char decode-time default-boundp default-value documentation downcase - elt exp expt encode-time error-message-string + elt encode-char exp expt encode-time error-message-string fboundp fceiling featurep ffloor file-directory-p file-exists-p file-locked-p file-name-absolute-p file-newer-than-file-p file-readable-p file-symlink-p file-writable-p @@ -1233,7 +1234,7 @@ of FORM by signaling the error at compile-time." int-to-string intern-soft keymap-parent length local-variable-if-set-p local-variable-p log log10 logand - logb logior lognot logxor lsh + logb logior lognot logxor lsh langinfo make-list make-string make-symbol marker-buffer max member memq min mod multibyte-char-to-unibyte next-window nth nthcdr number-to-string @@ -1245,6 +1246,7 @@ of FORM by signaling the error at compile-time." string-to-int string-to-number substring sxhash symbol-function symbol-name symbol-plist symbol-value string-make-unibyte string-make-multibyte string-as-multibyte string-as-unibyte + string-to-multibyte tan truncate unibyte-char-to-multibyte upcase user-full-name user-login-name user-original-login-name user-variable-p @@ -1256,7 +1258,8 @@ of FORM by signaling the error at compile-time." '(arrayp atom bobp bolp bool-vector-p buffer-end buffer-list buffer-size buffer-string bufferp - car-safe case-table-p cdr-safe char-or-string-p commandp cons consp + car-safe case-table-p cdr-safe char-or-string-p characterp + charsetp commandp cons consp current-buffer current-global-map current-indentation current-local-map current-minor-mode-maps current-time current-time-string current-time-zone @@ -1268,11 +1271,13 @@ of FORM by signaling the error at compile-time." invocation-directory invocation-name keymapp line-beginning-position line-end-position list listp - make-marker mark mark-marker markerp memory-limit minibuffer-window + make-marker mark mark-marker markerp max-char + memory-limit minibuffer-window mouse-movement-p natnump nlistp not null number-or-marker-p numberp one-window-p overlayp - point point-marker point-min point-max preceding-char processp + point point-marker point-min point-max preceding-char primary-charset + processp recent-keys recursion-depth safe-length selected-frame selected-window sequencep standard-case-table standard-syntax-table stringp subrp symbolp diff --git a/lisp/emacs-lisp/bytecomp.el b/lisp/emacs-lisp/bytecomp.el index 64b0a07332b..5e415b870ee 100644 --- a/lisp/emacs-lisp/bytecomp.el +++ b/lisp/emacs-lisp/bytecomp.el @@ -786,7 +786,7 @@ otherwise pop it") (setcar (cdr bytes) (logand pc 255)) (setcar bytes (lsh pc -8)))) (setq patchlist (cdr patchlist)))) - (concat (nreverse bytes)))) + (string-make-unibyte (concat (nreverse bytes))))) ;;; compile-time evaluation @@ -1865,13 +1865,13 @@ With argument, insert value in current buffer after the form." (delete-region (point) (progn (re-search-forward "^(") (beginning-of-line) (point))) - (insert ";;; This file contains multibyte non-ASCII characters\n" - ";;; and therefore cannot be loaded into Emacs 19.\n") - ;; Replace "19" or "19.29" with "20", twice. + (insert ";;; This file contains utf-8 non-ASCII characters\n" + ";;; and therefore cannot be loaded into Emacs 21 or earlier.\n") + ;; Replace "19" or "19.29" with "22", twice. (re-search-forward "19\\(\\.[0-9]+\\)") - (replace-match "20") + (replace-match "23") (re-search-forward "19\\(\\.[0-9]+\\)") - (replace-match "20") + (replace-match "23") ;; Now compensate for the change in size, ;; to make sure all positions in the file remain valid. (setq delta (- (point-max) old-header-end)) @@ -1886,7 +1886,7 @@ With argument, insert value in current buffer after the form." (set-buffer outbuffer) (goto-char 1) ;; The magic number of .elc files is ";ELC", or 0x3B454C43. After - ;; that is the file-format version number (18, 19 or 20) as a + ;; that is the file-format version number (18, 19, 20, or 23) as a ;; byte, followed by some nulls. The primary motivation for doing ;; this is to get some binary characters up in the first line of ;; the file so that `diff' will simply say "Binary files differ" @@ -1898,7 +1898,7 @@ With argument, insert value in current buffer after the form." (insert ";ELC" - (if (byte-compile-version-cond byte-compile-compatibility) 18 20) + (if (byte-compile-version-cond byte-compile-compatibility) 18 23) "\000\000\000\n" ) (insert ";;; Compiled by " @@ -1954,7 +1954,7 @@ With argument, insert value in current buffer after the form." ;; Insert semicolons as ballast, so that byte-compile-fix-header ;; can delete them so as to keep the buffer positions ;; constant for the actual compiled code. - ";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;\n\n")) + ";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;\n\n")) ;; Here if we want Emacs 18 compatibility. (when dynamic-docstrings (error "Version-18 compatibility doesn't support dynamic doc strings")) @@ -3337,6 +3337,8 @@ That command is designed for interactive use only" fn)) (byte-defop-compiler-1 mapc byte-compile-funarg) (byte-defop-compiler-1 maphash byte-compile-funarg) (byte-defop-compiler-1 map-char-table byte-compile-funarg) +(byte-defop-compiler-1 map-char-table byte-compile-funarg-2) +;; map-charset-chars should be funarg but has optional third arg (byte-defop-compiler-1 sort byte-compile-funarg-2) (byte-defop-compiler-1 let) (byte-defop-compiler-1 let*) diff --git a/lisp/emacs-lisp/cl-macs.el b/lisp/emacs-lisp/cl-macs.el index e8590933863..45ec97b3281 100644 --- a/lisp/emacs-lisp/cl-macs.el +++ b/lisp/emacs-lisp/cl-macs.el @@ -2394,7 +2394,7 @@ The type name can then be used in `typecase', `check-type', etc." ((eq type 'real) `(numberp ,val)) ((eq type 'fixnum) `(integerp ,val)) ;; FIXME: Should `character' accept things like ?\C-\M-a ? -stef - ((memq type '(character string-char)) `(char-valid-p ,val)) + ((memq type '(character string-char)) `(characterp ,val)) (t (let* ((name (symbol-name type)) (namep (intern (concat name "p")))) diff --git a/lisp/emacs-lisp/copyright.el b/lisp/emacs-lisp/copyright.el index 4b5cbe51dd6..371fdd66b60 100644 --- a/lisp/emacs-lisp/copyright.el +++ b/lisp/emacs-lisp/copyright.el @@ -43,12 +43,10 @@ A value of nil means to search whole buffer." :type '(choice (integer :tag "Limit") (const :tag "No limit"))) -;; The character classes have the Latin-1 version and the Latin-9 -;; version, which is probably enough. (defcustom copyright-regexp - "\\([]\\|@copyright{}\\|[Cc]opyright\\s *:?\\s *\\(?:(C)\\)?\ -\\|[Cc]opyright\\s *:?\\s *[]\\)\ -\\s *\\([1-9]\\([-0-9, ';/*%#\n\t]\\|\\s<\\|\\s>\\)*[0-9]+\\)" + "\\(©\|@copyright{}\\|[Cc]opyright\\s *:?\\s *\\(?:(C)\\)?\ +\\|[Cc]opyright\\s *:?\\s *©\\)\ +\\s *\\([1-9]\\([-0-9, ';\n\t]\\|\\s<\\|\\s>\\)*[0-9]+\\)" "*What your copyright notice looks like. The second \\( \\) construct must match the years." :group 'copyright @@ -232,7 +230,7 @@ Uses heuristic: year >= 50 means 19xx, < 50 means 20xx." ;; For the copyright sign: ;; Local Variables: -;; coding: emacs-mule +;; coding: utf-8 ;; End: ;;; arch-tag: b4991afb-b6b1-4590-bebe-e076d9d4aee8 diff --git a/lisp/emacs-lisp/generic.el b/lisp/emacs-lisp/generic.el index 20df0b7ad6f..e52072e9db1 100644 --- a/lisp/emacs-lisp/generic.el +++ b/lisp/emacs-lisp/generic.el @@ -240,9 +240,9 @@ Some generic modes are defined in `generic-x.el'." (when (consp start) (setq end (cdr start)) (setq start (car start))) - (when (char-valid-p start) (setq start (char-to-string start))) + (when (characterp start) (setq start (char-to-string start))) (cond - ((char-valid-p end) (setq end (char-to-string end))) + ((characterp end) (setq end (char-to-string end))) ((zerop (length end)) (setq end "\n"))) ;; Setup the vars for `comment-region' diff --git a/lisp/emacs-lisp/regexp-opt.el b/lisp/emacs-lisp/regexp-opt.el index 52cbc956bc3..c2e13be20d8 100644 --- a/lisp/emacs-lisp/regexp-opt.el +++ b/lisp/emacs-lisp/regexp-opt.el @@ -263,13 +263,21 @@ This means the number of non-shy regexp grouping constructs (map-char-table (lambda (c v) (when v - (if (= (1- c) end) (setq end c) - (if (> end (+ start 2)) + (if (consp c) + (if (= (1- (car c)) end) (setq end (cdr c)) + (if (> end (+ start 2)) + (setq charset (format "%s%c-%c" charset start end)) + (while (>= end start) + (setq charset (format "%s%c" charset start)) + (incf start))) + (setq start (car c) end (cdr c))) + (if (= (1- c) end) (setq end c) + (if (> end (+ start 2)) (setq charset (format "%s%c-%c" charset start end)) (while (>= end start) (setq charset (format "%s%c" charset start)) (incf start))) - (setq start c end c)))) + (setq start c end c))))) charmap) (when (>= end start) (if (> end (+ start 2)) |