branch: elpa/zig-mode
commit bc1bed3ec84b9bd809abbc07b3db056892ed2f84
Author: Syohei YOSHIDA <syo...@gmail.com>
Commit: Syohei YOSHIDA <syo...@gmail.com>

    Fix package
    
    - Load cc-mode.el for byte-compile warning
    - Use setq instead of setq-local because those variables are already
      buffer local variables
---
 zig-mode.el | 7 +++++--
 1 file changed, 5 insertions(+), 2 deletions(-)

diff --git a/zig-mode.el b/zig-mode.el
index 9c1d334..bc80bfc 100644
--- a/zig-mode.el
+++ b/zig-mode.el
@@ -10,6 +10,9 @@
 ;;
 
 ;;; Code:
+
+(require 'cc-mode)
+
 (defvar zig--builtins
   '("@addWithOverflow"
     "@mulWithOverflow"
@@ -101,13 +104,13 @@
   "This hook is called when 'zig-mode' is initialized.")
 
 ;; Indentation is 4 spaces by default:
-(add-hook 'zig-mode-init-hook '(lambda() (setq-local c-basic-offset 4)))
+(add-hook 'zig-mode-init-hook '(lambda() (setq c-basic-offset 4)))
 
 ;;;###autoload
 (define-derived-mode zig-mode c-mode "Zig"
   "A major mode for the Zig programming language."
   (run-hooks 'zig-mode-init-hook)
-  (setq-local font-lock-defaults '(zig--font-lock-keywords)))
+  (setq font-lock-defaults '(zig--font-lock-keywords)))
 
 ;;;###autoload
 (add-to-list 'auto-mode-alist '("\\.zig\\'" . zig-mode))

Reply via email to