exactly the old newline insertion behavior."
;; newline only after semicolon, but only if that semicolon is not
;; inside a parenthesis list (e.g. a for loop statement)
- (if (not (eq last-command-event ?\;))
+ (if (not (eq (c-last-command-char) ?\;))
nil ; continue checking
(if (condition-case nil
(save-excursion
inserted, and the following line is not blank, no newline is inserted.
Otherwise, no determination is made."
(save-excursion
- (if (and (= last-command-event ?\;)
+ (if (and (= (c-last-command-char) ?\;)
;;(/= (point-max)
;; (save-excursion (skip-syntax-forward " ") (point))
(zerop (forward-line 1))
For other semicolon contexts, no determination is made."
(let ((syntax (c-guess-basic-syntax))
(bol (save-excursion
- (if (c-safe (up-list -1) t)
- (c-point 'bol)
- -1))))
- (if (and (eq last-command-event ?\;)
- (eq (car (car syntax)) 'inclass)
- (eq (car (car (cdr syntax))) 'topmost-intro)
- (= (c-point 'bol) bol))
+ (if (c-safe (up-list -1) t)
+ (c-point 'bol)
+ -1))))
+ (if (and (eq (c-last-command-char) ?\;)
+ (eq (car (car syntax)) 'inclass)
+ (eq (car (car (cdr syntax))) 'topmost-intro)
+ (= (c-point 'bol) bol))
'stop
nil)))