David Thompson <dthomps...@worcester.edu> writes: > Is the 'begin' form necessary here? Also, when substituting a single > file, you can just pass a string instead of a list of strings. > > (and > (zero? (system* "sh" "bootstrap")) > (substitute* "configure" > (("/usr/bin/file") "file")))
Since phase procedures are expected to return non-false and the return value of `substitute*' is probably unspecified, one should provide an explicit return value, but this is done pretty much nowhere so I guess it was needless and if we'll fix it we'll have to do it some other way. (I think it would have been better if Scheme specified zero return values for procedures called only for side-effect, so the above would raise an error and not trap the language's users into situations where they write code that "works by chance", but I guess it's way too late for such a thing, and in Guix's codebase we will just rely on Guile returning the special *unspecified* value for such procedures, which works as a non-false value.) Taylan