changeset 15431:68cca71d69bd

(set-fill-column): Error if no argument.
author Richard M. Stallman <rms@gnu.org>
date Fri, 14 Jun 1996 02:11:11 +0000
parents 760c7139c19c
children c76e8e8fdb0a
files lisp/simple.el
diffstat 1 files changed, 9 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/simple.el	Thu Jun 13 21:05:06 1996 +0000
+++ b/lisp/simple.el	Fri Jun 14 02:11:11 1996 +0000
@@ -2452,10 +2452,16 @@
   (auto-fill-mode 1))
 
 (defun set-fill-column (arg)
-  "Set `fill-column' to current column, or to argument if given.
-The variable `fill-column' has a separate value for each buffer."
+  "Set `fill-column' to specified argument.
+Just \\[universal-argument] as argument means to use the current column."
   (interactive "P")
-  (setq fill-column (if (integerp arg) arg (current-column)))
+  (cond ((integerp arg)
+	 (setq fill-column arg))
+	((consp arg)
+	 (setq fill-column (current-column)))
+	;; Disallow missing argument; it's probably a typo for C-x C-f.
+	(t
+	 (error "set-fill-column requires an explicit argument")))
   (message "fill-column set to %d" fill-column))
 
 (defconst comment-multi-line nil