-1
Мне нужно использовать отступ в стиле Google в приложении Java. Мне был предоставлен код для добавления в файл .emacs, но он не работает.Java-стиль отступа emacs-файла
Когда я запускаю код checkstyle, он дает мне ошибки табуляции.
Это то, что мой файл .emacs содержит:
;; .emacs
(custom-set-variables
;; custom-set-variables was added by Custom.
;; If you edit it by hand, you could mess it up, so be careful.
;; Your init file should contain only one such instance.
;; If there is more than one, they won't work right.
'(diff-switches "-u")
'(inhibit-startup-screen t))
;;; uncomment for CJK utf-8 support for non-Asian users
;; (require 'un-define)
(custom-set-faces
;; custom-set-faces was added by Custom.
;; If you edit it by hand, you could mess it up, so be careful.
;; Your init file should contain only one such instance.
;; If there is more than one, they won't work right.
)
;;; google conformant indentation for java
(add-hook 'java-mode-hook
(lambda()
(progn
(setq c-basic-offset 2)
(c-set-offset 'case-label '+)
(c-set-offset 'statement-cont '++))))
Не могли бы вы сказать мне, что это неправильно, или указать мне файл я получил заменить его?