 (require 'newcomment)
 
+;;
+;; Buzz mode hook
+;;
+(defvar buzz-mode-hook nil
+  "Function hook to execute when Buzz mode is run.")
+
+;;
+;; Customization group
+;;
+(defgroup buzz nil
+  "Customization variables for Buzz mode."
+  :tag "Buzz"
+  :group 'languages)
+
+;;
+;; Indentation level
+;;
+(defcustom buzz-indent-level 2
+  "Number of spaces for each indentation step in `buzz-mode'."
+  :type 'integer
+  :safe 'integerp
+  :group 'buzz)
+
+;;
 ;; Command to comment/uncomment text
+;;
 (defun buzz-comment-dwim (arg)
   "Comment or uncomment current line or region in a smart way.
 For detail, see `comment-dwim'."

;;
(setq buzz-font-lock-list
      `(
        (,buzz-builtins-regexp  . font-lock-builtin-face)
        (,buzz-functions-regexp 1 font-lock-function-name-face)
        (,buzz-keywords-regexp  . font-lock-keyword-face)
))

;;
;; Define the mode
;;
(define-derived-mode buzz-mode prog-mode
  "Buzz mode"
  "Major mode for editing Buzz scripts"
  :syntax-table buzz-syntax-table
  ;; Set font lock
  (setq font-lock-defaults '((buzz-font-lock-list)))
  ;; Modify the keymap
  (define-key buzz-mode-map [remap comment-dwim] 'buzz-comment-dwim)
  ;; Clear memory
  (setq buzz-keywords-regexp nil)
  (setq buzz-functions-regexp nil)
)

(provide 'buzz-mode)

  (let ((comment-start "#") (comment-end ""))
    (comment-dwim arg)))

;;
;; Buzz syntax table
;;
(defvar buzz-syntax-table nil "Syntax table for `buzz-mode'.")
(setq buzz-syntax-table
      (let ((synTable (make-syntax-table)))
