Errata

Writing GNU Emacs Extensions

Errata for Writing GNU Emacs Extensions

Submit your own errata for this product.

The errata list is a list of errors and their corrections that were found after the product was released.

The following errata were submitted by our customers and have not yet been approved or disproved by the author or editor. They solely represent the opinion of the customer.

Color Key: Serious technical mistake Minor technical mistake Language or formatting error Typo Question Note Update

Version Location Description Submitted by Date submitted
Printed Page 102
second code listing on page

This is probably a typo, but I am not that good at this yet, so I've
flagged it as a request for clarification.

The second definition of the refill function on the page doesn't terminate
the initialization of the variables in time.

The "fixed" version of the code, comments indicate my changes from the
original code.

(defun refill (start end len)
"After a text change, refill the current paragraph."
(let ((left (if (zerop len)
start
(save-excursion
(goto-char start)
(beginning-of-line 0)
(point))))); close paren added here
(save-excursion
(fill-region left end nil nil t)))) ; close paren removed here

Anonymous   
Printed Page 102
2nd line

to the end of the previous line

should be

to the beginning of the previous line

Kyungwon Chun  Feb 11, 2014