[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: GSoC 2018 Syntax and semantics of systemd units in the Shepherd - 1s
From: |
Ludovic Courtès |
Subject: |
Re: GSoC 2018 Syntax and semantics of systemd units in the Shepherd - 1st update |
Date: |
Tue, 12 Jun 2018 15:11:10 +0200 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/26.1 (gnu/linux) |
Heya,
Ioannis Panagiotis Koutsidis <address@hidden> skribis:
> Thank you a lot for your comments! I will make sure to make the changes that
> you
> suggested.
Awesome.
> As for match and things like car/cdr, I had issues with match and signal
> handling
> in the service file, which was why I changed it with a cond. As for the unit
> parser
> I also take the rest of the list via cdar because match in something like
> (x y rest ...) does not bind rest - I will probably have to use (x . (y .
> rest)) in
> the replacement.
If you have a specific example, we can look at it. Rest elements in
‘match’ patterns should definitely get bound. Here’s an example at the
Guile REPL:
--8<---------------cut here---------------start------------->8---
scheme@(guile-user)> ,use(ice-9 match)
scheme@(guile-user)> (match '(hello brave gnu world!)
((x rest ...)
rest))
$2 = (brave gnu world!)
--8<---------------cut here---------------end--------------->8---
Here ‘rest’ is bound to the cdr of the list.
If you want let’s get in touch on IRC to discuss the issue that you had.
Cheers,
Ludo’.