Function: c-semi&comma-no-newlines-before-nonblanks

c-semi&comma-no-newlines-before-nonblanks is a byte-compiled function defined in cc-align.el.gz.

Signature

(c-semi&comma-no-newlines-before-nonblanks)

Documentation

Controls newline insertion after semicolons.

If a comma was inserted, no determination is made. If a semicolon was inserted, and the following line is not blank, no newline is inserted. Otherwise, no determination is made.

Source Code

;; Defined in /usr/src/emacs/lisp/progmodes/cc-align.el.gz
;; Suppresses newlines before non-blank lines
(defun c-semi&comma-no-newlines-before-nonblanks ()
  "Controls newline insertion after semicolons.
If a comma was inserted, no determination is made.  If a semicolon was
inserted, and the following line is not blank, no newline is inserted.
Otherwise, no determination is made."
  (save-excursion
    (if (and (= (c-last-command-char) ?\;)
	     ;;(/= (point-max)
	     ;;    (save-excursion (skip-syntax-forward " ") (point))
	     (zerop (forward-line 1))
	     (bolp)			; forward-line has funny behavior at eob.
	     (not (looking-at "^[ \t]*$")))
	'stop
      nil)))