Ludovic Courtès writes: > I find it a bit hard to read. What I had in mind is along these lines: > > (match (openssh-authorized-keys config) > (((users _ ...) ...) > ;; Build a user/key-list mapping. > (let ((user-keys (fold (lambda (spec table) > (match spec > ((user keys ...) > (vhash-cons user keys table)))) > vlist-null > (openssh-authorized-keys config)))) > ;; Coalesce the key lists associated with each user. > (map (lambda (user) > (concatenate (vhash-fold* cons '() user user-keys))) > users)))) That’s way cleaner. I didn’t know of vhash-fold*, it seems to save the day! (just fixing the final map function not to forget the user name in the alist, and removing "spec")