extra/sass-mode.el in haml-edge-3.1.44 vs extra/sass-mode.el in haml-edge-3.1.45
- old
+ new
@@ -41,15 +41,16 @@
"Amount of offset per level of indentation."
:type 'integer
:group 'sass)
(defvar sass-non-block-openers
- '("^ *:[^ \t]+[ \t]+[^ \t]"
- "^ *[^ \t:]+[ \t]*[=:][ \t]*[^ \t]")
- "A list of regexps that match lines of Sass that don't open blocks.
-That is, a Sass line that can't have text nested beneath it
-should be matched by a regexp in this list.")
+ '("^.*,$" ;; Continued selectors
+ "^ *@\\(extend\\|debug\\|warn\\|include\\|import\\)" ;; Single-line mixins
+ "^ *[$!]" ;; Variables
+ )
+ "A list of regexps that match lines of Sass that couldn't have
+text nested beneath them.")
;; Font lock
(defconst sass-selector-font-lock-keywords
'(;; Attribute selectors (e.g. p[foo=bar])
@@ -193,11 +194,11 @@
;; Indentation
(defun sass-indent-p ()
"Return non-nil if the current line can have lines nested beneath it."
(loop for opener in sass-non-block-openers
- unless (looking-at opener) return t
- return nil))
+ if (looking-at opener) return nil
+ finally return t))
;;;###autoload
(add-to-list 'auto-mode-alist '("\\.sass$" . sass-mode))
;; Setup/Activation