summary refs log tree commit diff
path: root/etc
diff options
context:
space:
mode:
authorMaxim Cournoyer <maxim.cournoyer@gmail.com>2023-08-30 15:37:42 -0400
committerMaxim Cournoyer <maxim.cournoyer@gmail.com>2023-08-30 15:40:34 -0400
commitd6966b8a5b4f2ddda2bc685b9642e7a1c2cbe17c (patch)
tree4ca9d6b451eb41018f9f87c230308c9f0a900193 /etc
parentd72c3fcf2d72e97715389762c09bf4c4fe81dc0e (diff)
downloadguix-d6966b8a5b4f2ddda2bc685b9642e7a1c2cbe17c.tar.gz
etc: teams: Fix regexp match and execution.
This is a follow up to commit 4d7b25a0 ("etc: teams: Sort and improve display
of regular expression in 'scope' field.").

* etc/teams.scm.in (regexp-exec*): Rename to...
(regexp*-exec): ... this.
(find-team-by-scope): Replace regexp? with regexp*?.  Replace regexp-exec with
regexp*-exec.
Diffstat (limited to 'etc')
-rw-r--r--etc/teams.scm.in6
1 files changed, 3 insertions, 3 deletions
diff --git a/etc/teams.scm.in b/etc/teams.scm.in
index 29813e8c6e..e84e89201d 100644
--- a/etc/teams.scm.in
+++ b/etc/teams.scm.in
@@ -53,7 +53,7 @@
   "Alternative to `make-regexp' producing annotated <regexp*> objects."
   (%make-regexp* pat flag (make-regexp pat flag)))
 
-(define (regexp-exec* rx* str)
+(define (regexp*-exec rx* str)
   "Execute the RX* regexp, a <regexp*> object."
   (regexp-exec (regexp*-rx rx*) str))
 
@@ -653,8 +653,8 @@ of file names as string."
                 (any (match-lambda
                        ((? string? scope)
                         (string=? scope file))
-                       ((? regexp? scope)
-                        (regexp-exec scope file)))
+                       ((? regexp*? scope)
+                        (regexp*-exec scope file)))
                      (team-scope team)))
               files)
          (cons team acc)