summaryrefslogtreecommitdiffstats
path: root/ravi-init-cpp.el
diff options
context:
space:
mode:
Diffstat (limited to 'ravi-init-cpp.el')
-rw-r--r--ravi-init-cpp.el20
1 files changed, 6 insertions, 14 deletions
diff --git a/ravi-init-cpp.el b/ravi-init-cpp.el
index 7157c17..8e9e9ff 100644
--- a/ravi-init-cpp.el
+++ b/ravi-init-cpp.el
@@ -166,6 +166,12 @@
(c-set-style "stroustrup")
(setq c-basic-offset 2)
(setq c-recognize-knr-p nil)
+ (add-to-list 'c-cleanup-list 'empty-defun-braces)
+ (add-to-list 'c-cleanup-list 'defun-close-semi)
+ (add-to-list 'c-cleanup-list 'list-close-comma)
+ (add-to-list 'c-cleanup-list 'scope-operator)
+ (add-to-list 'c-cleanup-list 'one-liner-defun)
+ (add-to-list 'c-cleanup-list 'comment-close-slash)
(font-lock-add-keywords 'c++-mode '(("\\<\\(assert\\|DEBUG\\)("
1 font-lock-warning-face t))))
@@ -307,7 +313,6 @@ this to 3 makes header-protection define KIG_MISC_NEWTYPE_H for a file named
(newline-and-indent))
(bind-key "," 'insert-comma c-mode-base-map)
- (bind-key ";" 'insert-semicolon c-mode-base-map)
(bind-key "<M-f8>" 'compile-dwim c-mode-base-map)
@@ -319,19 +324,6 @@ this to 3 makes header-protection define KIG_MISC_NEWTYPE_H for a file named
(bind-key "<S-f11>" 'show-ifdef-block c-mode-base-map)
;; (setq c-syntactic-indentation nil)
-
- ;; (bind-key "#" 'self-insert-command c-mode-base-map)
- ;; (bind-key "{" 'self-insert-command c-mode-base-map)
- ;; (bind-key "}" 'self-insert-command c-mode-base-map)
- ;; (bind-key "/" 'self-insert-command c-mode-base-map)
- ;; (bind-key "*" 'self-insert-command c-mode-base-map)
- ;; (bind-key ";" 'self-insert-command c-mode-base-map)
- ;; (bind-key "," 'self-insert-command c-mode-base-map)
- ;; (bind-key ":" 'self-insert-command c-mode-base-map)
- ;; (bind-key "(" 'self-insert-command c-mode-base-map)
- ;; (bind-key ")" 'self-insert-command c-mode-base-map)
- ;; (bind-key "<" 'self-insert-command c++-mode-map)
- ;; (bind-key ">" 'self-insert-command c++-mode-map)
)
)