]> code.delx.au - gnu-emacs-elpa/blobdiff - packages/company/company-css.el
Merge commit 'b1d019a4c815ac8bdc240d69eaa74eb4e34640e8' from company-master
[gnu-emacs-elpa] / packages / company / company-css.el
index b8bd639c188985fad6e39c9112bb096f48048615..ec48653907d6257e119e0ea71ea62a330f7de1f4 100644 (file)
                 (push child results))
             (push value results)))
         (setq results (sort results 'string<))
-        (puthash attribute results company-css-property-cache)
+        (puthash attribute
+                 (if (fboundp 'delete-consecutive-dups)
+                     (delete-consecutive-dups results)
+                   (delete-dups results))
+                 company-css-property-cache)
         results)))
 
 ;;; bracket detection
@@ -402,7 +406,7 @@ Returns \"\" if no property found, but feasible at this position."
 
 ;;; values
 (defconst company-css-property-value-regexp
-  "\\_<\\([[:alpha:]-]+\\):\\(?:[^};]*[[:space:]]+\\)?\\([^};]*\\_>\\|\\)\\="
+  "\\_<\\([[:alpha:]-]+\\):\\(?:[^{};]*[[:space:]]+\\)?\\([^{};]*\\_>\\|\\)\\="
   "A regular expression matching CSS tags.")
 
 ;;;###autoload