mirror of
https://git.savannah.gnu.org/git/emacs.git
synced 2024-11-29 07:58:28 +00:00
* lisp/progmodes/cc-cmds.el (c-defun-name): Handle objc selectors properly.
Fixes: debbugs:7879
This commit is contained in:
parent
fe1a523fd9
commit
3646bcd6b8
@ -1,5 +1,8 @@
|
|||||||
2012-07-20 Leo Liu <sdl.web@gmail.com>
|
2012-07-20 Leo Liu <sdl.web@gmail.com>
|
||||||
|
|
||||||
|
* progmodes/cc-cmds.el (c-defun-name): Handle objc selectors properly.
|
||||||
|
(Bug#7879)
|
||||||
|
|
||||||
* progmodes/cc-langs.el (c-symbol-start): Include char _ (bug#11986).
|
* progmodes/cc-langs.el (c-symbol-start): Include char _ (bug#11986).
|
||||||
|
|
||||||
2012-07-18 Stefan Monnier <monnier@iro.umontreal.ca>
|
2012-07-18 Stefan Monnier <monnier@iro.umontreal.ca>
|
||||||
|
@ -1826,14 +1826,16 @@ with a brace block."
|
|||||||
;; DEFFLAGSET(syslog_opt_flags,LOG_PID ...) ==> syslog_opt_flags
|
;; DEFFLAGSET(syslog_opt_flags,LOG_PID ...) ==> syslog_opt_flags
|
||||||
(match-string-no-properties 1))
|
(match-string-no-properties 1))
|
||||||
|
|
||||||
;; Objective-C method starting with + or -.
|
;; Objc selectors.
|
||||||
((and (derived-mode-p 'objc-mode)
|
((assq 'objc-method-intro (c-guess-basic-syntax))
|
||||||
(looking-at "[-+]\s*("))
|
(let ((bound (save-excursion (c-end-of-statement) (point)))
|
||||||
(when (c-syntactic-re-search-forward ")\s*" nil t)
|
(kw-re (concat "\\(?:" c-symbol-key "\\)?:"))
|
||||||
(c-forward-token-2)
|
(stretches))
|
||||||
(setq name-end (point))
|
(when (c-syntactic-re-search-forward c-symbol-key bound t t t)
|
||||||
(c-backward-token-2)
|
(push (match-string 0) stretches)
|
||||||
(buffer-substring-no-properties (point) name-end)))
|
(while (c-syntactic-re-search-forward kw-re bound t t t)
|
||||||
|
(push (match-string 0) stretches)))
|
||||||
|
(apply 'concat (nreverse stretches))))
|
||||||
|
|
||||||
(t
|
(t
|
||||||
;; Normal function or initializer.
|
;; Normal function or initializer.
|
||||||
|
Loading…
Reference in New Issue
Block a user