GNU bug report logs - #35790
[PATCH] scripts: lint: Handle warnings with a record type.

Previous Next

Package: guix-patches;

Reported by: Christopher Baines <mail <at> cbaines.net>

Date: Sat, 18 May 2019 09:43:02 UTC

Severity: normal

Tags: patch

Done: Christopher Baines <mail <at> cbaines.net>

Bug is archived. No further changes may be made.

Full log


Message #50 received at 35790 <at> debbugs.gnu.org (full text, mbox):

From: Christopher Baines <mail <at> cbaines.net>
To: Ludovic Courtès <ludo <at> gnu.org>
Cc: 35790 <at> debbugs.gnu.org
Subject: Re: [bug#35790] [PATCH] scripts: lint: Separate the message warning
 text and data.
Date: Sat, 29 Jun 2019 09:46:44 +0100
[Message part 1 (text/plain, inline)]
Ludovic Courtès <ludo <at> gnu.org> writes:

> Hello,
>
> Christopher Baines <mail <at> cbaines.net> skribis:
>
>> +(define-syntax make-warning
>> +  (syntax-rules (G_)
>> +    ((_ package (G_ message) rest ...)
>> +     (%make-warning package message rest ...))
>> +    ((_ package message rest ...)
>> +     (%make-warning package message rest ...))))
>
> I think you can remove the second clause: that will ensure we never
> forget to add a G_ around messages.

Sure, there was one case where this clause was used, but I've switched
that to call %make-warning directly, and added a comment:

  (define (check-patch-file-names package)
    "Emit a warning if the patches requires by PACKAGE are badly named or if the
  patch could not be found."
    (guard (c ((message-condition? c)     ;raised by 'search-patch'
               (list
                ;; Use %make-warning, as condition-mesasge is already
                ;; translated.
                (%make-warning package (condition-message c)
                               #:field 'patch-file-names))))
[signature.asc (application/pgp-signature, inline)]

This bug report was last modified 6 years and 30 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.