A NOTE has been added to this issue. 
====================================================================== 
https://austingroupbugs.net/view.php?id=1647 
====================================================================== 
Reported By:                eblake
Assigned To:                
====================================================================== 
Project:                    1003.1(2016/18)/Issue7+TC2
Issue ID:                   1647
Category:                   System Interfaces
Type:                       Clarification Requested
Severity:                   Objection
Priority:                   normal
Status:                     Interpretation Required
Name:                       Eric Blake 
Organization:               Red Hat 
User Reference:             ebb.printf %lc 
Section:                    fprintf 
Page Number:                913 
Line Number:                30957 
Interp Status:              Proposed 
Final Accepted Text:        https://austingroupbugs.net/view.php?id=1647#c6239 
====================================================================== 
Date Submitted:             2023-03-28 16:32 UTC
Last Modified:              2023-06-26 09:25 UTC
====================================================================== 
Summary:                    printf("%lc", (wint_t)0) can't output NUL byte
======================================================================
Relationships       ID      Summary
----------------------------------------------------------------------
related to          0001643 fprintf %lc: wrong reference to the cur...
====================================================================== 

---------------------------------------------------------------------- 
 (0006349) geoffclare (manager) - 2023-06-26 09:25
 https://austingroupbugs.net/view.php?id=1647#c6349 
---------------------------------------------------------------------- 
> it follows by the deference to the C standard's translation phases that
all of the requirements of those translation phases apply to the c17
utility

Irrelevant, as there is nothing in the C17 description of those translation
phases in 5.1.1.2 that would pull in the C17 requirements for the behaviour
of printf() from 7.21.6.3.

> the requirement to "accept source code conforming to the ISO C standard"
is by itself already sufficient. A conforming C17 program can call
printf("%lc", (wint_t)0).

Non-sequitur. If the source code contains a call to printf("%lc",
(wint_t)0), c17 is required to produce a program (or shared library) that
calls a function called printf() with those two arguments. There is nothing
that says the behaviour of that function has to be as described in C17; the
required behaviour is described in XSH and any behavioural requirements
from C17 derive only from the XSH description, so that is the only place
that needs to state anything about POSIX not deferring to C17 on a specific
aspect of printf()'s behaviour.

> This requirement is only placed on "Strictly Conforming POSIX
Application". No such requirement exists for "Conforming POSIX
Application".

The relevant text from XSH 2.2.1.1 is:<blockquote>A POSIX-conforming
application shall ensure that the feature test macro _POSIX_C_SOURCE is
defined before inclusion of any header.</blockquote>"POSIX-conforming
application" is not the same as "Conforming POSIX Application"; this text
does not distinguish between the different ways an application can conform
to POSIX, and so applies to all three. 

Issue History 
Date Modified    Username       Field                    Change               
====================================================================== 
2023-03-28 16:32 eblake         New Issue                                    
2023-03-28 16:32 eblake         Name                      => Eric Blake      
2023-03-28 16:32 eblake         Organization              => Red Hat         
2023-03-28 16:32 eblake         User Reference            => ebb.printf %lc  
2023-03-28 16:32 eblake         Section                   => fprintf         
2023-03-28 16:32 eblake         Page Number               => 913             
2023-03-28 16:32 eblake         Line Number               => 30957           
2023-03-28 16:32 eblake         Interp Status             => ---             
2023-03-28 16:32 eblake         Relationship added       child of 0001643    
2023-03-28 16:33 eblake         Desired Action Updated                       
2023-03-28 17:02 eblake         Desired Action Updated                       
2023-03-28 17:30 eblake         Note Added: 0006237                          
2023-03-28 17:31 eblake         Description Updated                          
2023-03-28 17:37 eblake         Desired Action Updated                       
2023-03-30 16:33 eblake         Note Added: 0006239                          
2023-03-30 17:14 eblake         Tag Attached: tc3-2008                       
2023-03-30 17:14 eblake         Tag Attached: issue8                         
2023-04-03 15:27 eblake         Note Added: 0006246                          
2023-04-03 15:28 eblake         Note Edited: 0006239                         
2023-04-03 15:28 geoffclare     Tag Detached: tc3-2008                       
2023-04-03 15:31 ajosey         Interp Status            --- => Pending      
2023-04-03 15:31 ajosey         Final Accepted Text       =>
https://austingroupbugs.net/view.php?id=1647#c6239    
2023-04-03 15:31 ajosey         Resolution               Open => Accepted As
Marked
2023-04-03 15:32 ajosey         Status                   New => Interpretation
Required
2023-04-03 16:31 ajosey         Note Added: 0006248                          
2023-04-03 16:31 ajosey         Status                   Interpretation Required
=> Resolution Proposed
2023-04-03 16:46 hvd            Note Added: 0006251                          
2023-04-03 17:15 ajosey         Interp Status            Pending => Proposed 
2023-04-03 17:15 ajosey         Status                   Resolution Proposed =>
Interpretation Required
2023-04-20 16:22 geoffclare     Relationship replaced    related to 0001643  
2023-06-23 16:19 geoffclare     Note Added: 0006346                          
2023-06-23 16:45 hvd            Note Added: 0006347                          
2023-06-26 09:25 geoffclare     Note Added: 0006349                          
======================================================================


  • [1003.1(2016... Austin Group Bug Tracker via austin-group-l at The Open Group
  • [1003.1(2016... Austin Group Bug Tracker via austin-group-l at The Open Group
  • [1003.1(2016... Austin Group Bug Tracker via austin-group-l at The Open Group
  • [1003.1(2016... Austin Group Bug Tracker via austin-group-l at The Open Group
  • [1003.1(2016... Austin Group Bug Tracker via austin-group-l at The Open Group
  • [1003.1(2016... Austin Group Bug Tracker via austin-group-l at The Open Group
  • [1003.1(2016... Austin Group Bug Tracker via austin-group-l at The Open Group
  • [1003.1(2016... Austin Group Bug Tracker via austin-group-l at The Open Group
  • [1003.1(2016... Austin Group Bug Tracker via austin-group-l at The Open Group
  • [1003.1(2016... Austin Group Bug Tracker via austin-group-l at The Open Group
  • [1003.1(2016... Austin Group Bug Tracker via austin-group-l at The Open Group
  • [1003.1(2016... Austin Group Bug Tracker via austin-group-l at The Open Group
  • [1003.1(2016... Austin Group Bug Tracker via austin-group-l at The Open Group
  • [1003.1(2016... Austin Group Bug Tracker via austin-group-l at The Open Group
  • [1003.1(2016... Austin Group Bug Tracker via austin-group-l at The Open Group
  • [1003.1(2016... Austin Group Bug Tracker via austin-group-l at The Open Group
  • [1003.1(2016... Austin Group Bug Tracker via austin-group-l at The Open Group
  • [1003.1(2016... Austin Group Bug Tracker via austin-group-l at The Open Group
  • [1003.1(2016... Austin Group Bug Tracker via austin-group-l at The Open Group
  • [1003.1(2016... Austin Group Bug Tracker via austin-group-l at The Open Group

Reply via email to