changeset 5421:a248a39fa4b8

(make-syntax-table): New function; no longer an alias for copy-syntax-table.
author Richard M. Stallman <rms@gnu.org>
date Mon, 03 Jan 1994 07:41:00 +0000
parents a5e2d8c44144
children b56d0a9dbcf2
files lisp/subr.el
diffstat 1 files changed, 24 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/subr.el	Mon Jan 03 07:21:12 1994 +0000
+++ b/lisp/subr.el	Mon Jan 03 07:41:00 1994 +0000
@@ -403,7 +403,6 @@
 
 ;;;; Obsolescent names for functions.
 
-(defalias 'make-syntax-table 'copy-syntax-table)
 (defalias 'dot 'point)
 (defalias 'dot-marker 'point-marker)
 (defalias 'dot-min 'point-min)
@@ -655,6 +654,30 @@
 	    start (1+ end)))
     (concat result (substring argument start))))
 
+(defun make-syntax-table ()
+  "Return a new syntax table.
+It inherits all letters and control characters from the standard
+syntax table; other characters are copied from the standard syntax table."
+  (let ((table (copy-syntax-table))
+	i)
+    (setq i 0)
+    (while (<= i 31)
+      (aset table i 13)
+      (setq i (1+ i)))
+    (setq i ?A)
+    (while (<= i ?Z)
+      (aset table i 13)
+      (setq i (1+ i)))
+    (setq i ?a)
+    (while (<= i ?z)
+      (aset table i 13)
+      (setq i (1+ i)))
+    (setq i 128)
+    (while (<= i 255)
+      (aset table i 13)
+      (setq i (1+ i)))
+    table))
+
 ;; now in fns.c
 ;(defun nth (n list)
 ;  "Returns the Nth element of LIST.