A NOTE has been added to this issue. ====================================================================== https://austingroupbugs.net/view.php?id=1771 ====================================================================== Reported By: calestyo Assigned To: ====================================================================== Project: Issue 8 drafts Issue ID: 1771 Category: Shell and Utilities Type: Enhancement Request Severity: Editorial Priority: normal Status: New Name: Christoph Anton Mitterer Organization: User Reference: Section: Utilities / printf Page Number: 3269 Line Number: 111019 Final Accepted Text: ====================================================================== Date Submitted: 2023-08-07 19:22 UTC Last Modified: 2023-08-08 14:28 UTC ====================================================================== Summary: support or reserve %q as printf-utility format specifier ======================================================================
---------------------------------------------------------------------- (0006420) calestyo (reporter) - 2023-08-08 14:28 https://austingroupbugs.net/view.php?id=1771#c6420 ---------------------------------------------------------------------- A I see... lower case letters for conversion specifiers are apparently reserved for future use in 7.31.11 Input/output <stdio.h>. But POSIX already specifies %b for the printf utility, and on a quick search I couldn't find any reference in the C standard that this would be reserved. Also there seem to be other (lower case) conversion specifiers, not standardised but still used by implementations (sigh), e.g. glib/uClibc/musl have: 'm' Well %Q is already used by bash as follows: > %Q like %q, but applies any supplied precision to the argument > before quoting it. But I guess that would be still compatible with %q. GNU printf does not seem to use %Q. %q is probably already used in many real world scripts... not sure how easy it would be to have the C folks exclude q (and perhaps also b) from their reservation? Issue History Date Modified Username Field Change ====================================================================== 2023-08-07 19:22 calestyo New Issue 2023-08-07 19:22 calestyo Name => Christoph Anton Mitterer 2023-08-07 19:22 calestyo Section => Utilities / printf 2023-08-07 19:22 calestyo Page Number => 3269 2023-08-07 19:22 calestyo Line Number => 111019 2023-08-07 19:36 chet_ramey Note Added: 0006416 2023-08-07 19:46 calestyo Note Added: 0006417 2023-08-07 23:39 salewski Issue Monitored: salewski 2023-08-08 08:46 geoffclare Note Added: 0006418 2023-08-08 14:28 calestyo Note Added: 0006420 ======================================================================
