From b4be5e8072478a9c916add695acdbf6e8ea4fe45 Mon Sep 17 00:00:00 2001 From: Kyle Meyer Date: Thu, 17 Nov 2016 18:12:22 -0500 Subject: snakemake-rx-constituents: Replace sm-func with sm-builtin The sm-builtin regexp will be extended to support built-in Snakemake objects like "input" and "output", at which point "function" will no longer be an accurate description. --- snakemake-mode.el | 20 +++++++++++--------- 1 file changed, 11 insertions(+), 9 deletions(-) diff --git a/snakemake-mode.el b/snakemake-mode.el index 9471965..448a4af 100644 --- a/snakemake-mode.el +++ b/snakemake-mode.el @@ -111,14 +111,16 @@ "wildcard_constraints" "workdir") symbol-end)) - (sm-func . ,(rx symbol-start - (or "dynamic" - "expand" - "protected" - "shell" - "temp" - "touch") - symbol-end))) + (sm-builtin . ,(rx symbol-start + (or "dynamic" + "expand" + "protected" + "shell" + "temp" + "touch") + symbol-end)) + ;; Deprecated. Use `sm-builtin' instead. + (sm-func . sm-builtin)) "Snakemake-specific sexps for `snakemake-rx'.") (defmacro snakemake-rx (&rest regexps) @@ -414,7 +416,7 @@ embedded R, you need to set mmm-global-mode to a non-nil value such as 'maybe.") (1 font-lock-keyword-face nil 'lax) (2 font-lock-function-name-face nil 'lax) (3 font-lock-keyword-face nil 'lax)) - (,(snakemake-rx (group sm-func) (zero-or-more space) "(") + (,(snakemake-rx (group sm-builtin) (zero-or-more space) "(") 1 font-lock-builtin-face) (,(snakemake-rx line-start (one-or-more space) (group field-key) -- cgit v1.2.3