guix-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

patch-shebang and Rust - Change on core-updates?


From: Danny Milosavljevic
Subject: patch-shebang and Rust - Change on core-updates?
Date: Mon, 20 Jan 2020 20:28:14 +0100

Hi,

Rust uses #![...] for something that is definitely not a shebang
(file-wide feature tests).

Currently, our patch-shebang[1] emits a lot of warnings because of those.

Should we change patch-shebang to ignore lines starting with "#![" ?

If so, how?  There's some get-char* magic that I don't understand.

The easiest way would be to add peek-char after the two calls to get-char*,
but not sure if that would work.

Alternatively, we could adapt the regexp.

>(define patch-shebang
>  (let ((shebang-rx (make-regexp 
> "^[[:blank:]]*([[:graph:]]+)[[:blank:]]*([[:graph:]]*)(.*)$")))

The [[:graph:]]+ would have to change to something like 

  [[:graph-without-opening-bracket:]][[:graph:]]+

[1] ./guix/build/utils.scm patch-shebang

Attachment: pgpOuuXiaH5zr.pgp
Description: OpenPGP digital signature


reply via email to

[Prev in Thread] Current Thread [Next in Thread]