Subject: bug#75997: (ice-9 match): warning: unused variable `failure'

From: Ludovic Courtès <[email-masked]>
Date: Wed, 26 Feb 2025 16:09:33 +0100

Tomas Volf <[email-masked]> skribis:

> (lambda (expr)
>   (let* ((v expr)
>          (failure
>            (lambda ()
>              ((@@ (ice-9 match) throw)
>               'match-error
>               "match"
>               "no matching pattern"
>               v)
>              #f)))
>     #f))

Hi!  Currently the unused-variable warning pass is unable to determine
that ‘failure’ was introduced by expanding a macro and thus that no
warning should be emitted.

It’s always been this way and I don’t know of a clear way to fix it.

Ludo’.