GNU bug report logs - #78885
[PATCH] maint: assume that compilers support '\a' as specified by C89

Previous Next

Package: sed;

Reported by: Collin Funk <collin.funk1 <at> gmail.com>

Date: Tue, 24 Jun 2025 04:45:02 UTC

Severity: normal

Tags: patch

To reply to this bug, email your comments to 78885 AT debbugs.gnu.org.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to bug-sed <at> gnu.org:
bug#78885; Package sed. (Tue, 24 Jun 2025 04:45:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to Collin Funk <collin.funk1 <at> gmail.com>:
New bug report received and forwarded. Copy sent to bug-sed <at> gnu.org. (Tue, 24 Jun 2025 04:45:02 GMT) Full text and rfc822 format available.

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

From: Collin Funk <collin.funk1 <at> gmail.com>
To: bug-sed <at> gnu.org
Subject: [PATCH] maint: assume that compilers support '\a' as specified by C89
Date: Mon, 23 Jun 2025 21:44:28 -0700
[Message part 1 (text/plain, inline)]
Hi,

I noticed some very old code:

    #if defined __STDC__ && __STDC__-0
               case 'a': *q++ = '\a'; p++; continue;
    #else /* Not STDC; we'll just assume ASCII */
              case 'a': *q++ = '\007'; p++; continue;
    #endif

This is from before C89 when '\a' was standardized. In sed/debug.c and
in Gnulib we already assume it is supported. So the fallback code can be
removed.

And if compilers don't support it, they most certainly have other larger
problems than this. :)

Collin

[0001-maint-assume-that-compilers-support-a-as-specified-b.patch (text/x-patch, attachment)]

This bug report was last modified 2 days ago.

Previous Next


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