Date: Thu, 7 Oct 2021 13:19:52 -0400
On 10/7/21 12:31 PM, Gabriel Dos Reis wrote:
> [Tom]
>> Thank you, Gaby, but I'm still a little confused. Could you please
>> elaborate with regard to what runtime semantics you believe would
>> differ?
> See the conversion/promotion rules - I think they were points 2, 3, and 4 on the slide presentations.
The polls we took had consensus for aligning behavior there (the only
exception I'm aware of being that some conversions would be ill-formed
in C++, but not in C).
>
>> What changes would be needed to align the runtime semantics across the languages?
> The rules that the WG14 representatives were unwilling to make. See the poll results.
Unless I'm mistaken, the only difference that remains after the polls is
not a run-time concern. If that doesn't match your understanding, please
be specific with regard to what semantic differences you believe remain.
>
> Note: I am quite happy with the C++ proposal, EXCEPT the aliasing part. I would reconsider my vote and recommendations to the various constituents when there is sufficient convergence. I would still recommend against the _Fxxx names in the global namespace.
There is a trade off between not polluting the global namespace in the
standard vs programmers having to #ifdef their C code that is otherwise
written in a common subset of the two languages. From the programmer
perspective, the desired choice seems obvious to me, especially since,
in practice, some implementations will just use the _Fxxx names anyway.
Perhaps worth noting, if the proposal included new suffixes for
literals, then the aliases could be portably defined with something like
using float32_t = decltype(1.0F32);
Tom.
>
> -- Gaby
>
> -----Original Message-----
> From: Tom Honermann <tom_at_[hidden]>
> Sent: Thursday, October 7, 2021 9:25 AM
> To: Gabriel Dos Reis <gdr_at_[hidden]>; Aaron Ballman <aaron_at_[hidden]>; WG14/WG21 liaison mailing list <liaison_at_[hidden]>
> Subject: Re: [wg14/wg21 liaison] C and C++ Compatibility SG meeting summary for Oct 06, 2021
>
> On 10/7/21 12:19 PM, Gabriel Dos Reis wrote:
>> The polls that were taken before this one indicated that both languages are headed towards distinct types that behave similarly in certain ways, but distinctly in other ways, and yet it was repeated that the goal was that if a program using those types compiles in both C and C++, then the runtime semantics should be the same. And that wasn't happening. Consequently, pretending that the types in C++ were aliases to the types in C was just plain misleading and wrong. If we are concerned about economic harms because of differences, there subtle differences should dissuade us to purse an "type aliasing" semantics.
> Thank you, Gaby, but I'm still a little confused. Could you please
> elaborate with regard to what runtime semantics you believe would
> differ? What changes would be needed to align the runtime semantics
> across the languages?
>
> Tom.
>
>> -- Gaby
>>
>> -----Original Message-----
>> From: Aaron Ballman <aaron_at_[hidden]>
>> Sent: Thursday, October 7, 2021 8:55 AM
>> To: WG14/WG21 liaison mailing list <liaison_at_[hidden]>
>> Cc: Tom Honermann <tom_at_[hidden]>
>> Subject: Re: [wg14/wg21 liaison] C and C++ Compatibility SG meeting summary for Oct 06, 2021
>>
>> On Thu, Oct 7, 2021 at 11:39 AM Tom Honermann via Liaison
>> <liaison_at_[hidden]> wrote:
>>> Thank you for hosting the meeting yesterday, Aaron!
>> My pleasure, I'm glad it was a productive meeting, thank you for participating!
>>
>>> With regard to this poll: Should the _Float* C names be available
>>> (through some means) in C++ and be used as the types behind the
>>> std::float* aliases?
>>>
>>> The SA vote rationale was "My reasons against were that similar but
>>> slightly incompatible types is not good for the same names. ...."
>>>
>>> Previous polls had consensus to align the usual arithmetic conversions
>>> between C and C++, but did not have consensus for applying the C++
>>> implicit conversion rules to C. With regard to the SA rationale above,
>>> is the "slightly incompatible types" concern directed at those
>>> differences in the implicit conversion rules? Or is the concern over
>>> other differences? If the latter, a list of notable differences would be
>>> useful.
>> I'll leave it to the person who made the comments to explain further,
>> but my personal interpretation of the comment was that there was
>> unease with exposing the C names in C++ unless the semantics were
>> identical and there are cases where the semantics are compatible for a
>> well-formed program in both languages but not identical across
>> languages. If I have this wrong, hopefully I'll be corrected.
>>
>>> My understanding is that the intent of P1467R4, and as stated by the
>>> author yesterday, is that these types would have the same semantics in
>>> each language with the only exception being that, in some cases, a use
>>> may be ill-formed in one language and not the other (e.g., the
>>> differences in the implicit conversion rules).
>> This matches my understanding of the authors' intent with P1467.
>>
>> ~Aaron
>>
>>> Tom.
>>>
>>> On 10/7/21 8:57 AM, Aaron Ballman via Liaison wrote:
>>>> The meeting minutes from the Oct 2021 special session on
>>>> floating-point types can be found at:
>>>> https://nam06.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwiki.edg.com%2Fbin%2Fview%2FWg21telecons2021%2FTeleconference2021-10-06&data=04%7C01%7Cgdr%40microsoft.com%7C0c4485021a2d45b8ce5c08d989af0da0%7C72f988bf86f141af91ab2d7cd011db47%7C1%7C0%7C637692207217336419%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=bSnTbVP%2FO12LCJUY%2FEjiTRviQcgBsD59Y3egY1qUjQs%3D&reserved=0.
>>>> The WG14 minutes will be posted to the document log in the near
>>>> future.
>>>>
>>>> Big thanks to Rajan Bhakta for taking minutes, and to all the
>>>> attendees for having such a productive special session!
>>>>
>>>> ~Aaron
>>>> _______________________________________________
>>>> Liaison mailing list
>>>> Liaison_at_[hidden]
>>>> Subscription: https://nam06.safelinks.protection.outlook.com/?url=https%3A%2F%2Flists.isocpp.org%2Fmailman%2Flistinfo.cgi%2Fliaison&data=04%7C01%7Cgdr%40microsoft.com%7C0c4485021a2d45b8ce5c08d989af0da0%7C72f988bf86f141af91ab2d7cd011db47%7C1%7C0%7C637692207217336419%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=7R18sXyeYEXGBHg0CfrcIVSGFdsHIVcnd9V4ko3zBTM%3D&reserved=0
>>>> Link to this post: https://nam06.safelinks.protection.outlook.com/?url=http%3A%2F%2Flists.isocpp.org%2Fliaison%2F2021%2F10%2F0867.php&data=04%7C01%7Cgdr%40microsoft.com%7C0c4485021a2d45b8ce5c08d989af0da0%7C72f988bf86f141af91ab2d7cd011db47%7C1%7C0%7C637692207217336419%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=fIgqzD6vLiC9jNGD0l3D2r63x%2Bxh4DepZPV1CWcisx8%3D&reserved=0
>>> _______________________________________________
>>> Liaison mailing list
>>> Liaison_at_[hidden]
>>> Subscription: https://nam06.safelinks.protection.outlook.com/?url=https%3A%2F%2Flists.isocpp.org%2Fmailman%2Flistinfo.cgi%2Fliaison&data=04%7C01%7Cgdr%40microsoft.com%7C0c4485021a2d45b8ce5c08d989af0da0%7C72f988bf86f141af91ab2d7cd011db47%7C1%7C0%7C637692207217336419%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=7R18sXyeYEXGBHg0CfrcIVSGFdsHIVcnd9V4ko3zBTM%3D&reserved=0
>>> Link to this post: https://nam06.safelinks.protection.outlook.com/?url=http%3A%2F%2Flists.isocpp.org%2Fliaison%2F2021%2F10%2F0868.php&data=04%7C01%7Cgdr%40microsoft.com%7C0c4485021a2d45b8ce5c08d989af0da0%7C72f988bf86f141af91ab2d7cd011db47%7C1%7C0%7C637692207217336419%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=0RjcPBY%2BkF%2BcQCCG0hvkyDT4EJfAnuMO2XSgtomvKxY%3D&reserved=0
>
> [Tom]
>> Thank you, Gaby, but I'm still a little confused. Could you please
>> elaborate with regard to what runtime semantics you believe would
>> differ?
> See the conversion/promotion rules - I think they were points 2, 3, and 4 on the slide presentations.
The polls we took had consensus for aligning behavior there (the only
exception I'm aware of being that some conversions would be ill-formed
in C++, but not in C).
>
>> What changes would be needed to align the runtime semantics across the languages?
> The rules that the WG14 representatives were unwilling to make. See the poll results.
Unless I'm mistaken, the only difference that remains after the polls is
not a run-time concern. If that doesn't match your understanding, please
be specific with regard to what semantic differences you believe remain.
>
> Note: I am quite happy with the C++ proposal, EXCEPT the aliasing part. I would reconsider my vote and recommendations to the various constituents when there is sufficient convergence. I would still recommend against the _Fxxx names in the global namespace.
There is a trade off between not polluting the global namespace in the
standard vs programmers having to #ifdef their C code that is otherwise
written in a common subset of the two languages. From the programmer
perspective, the desired choice seems obvious to me, especially since,
in practice, some implementations will just use the _Fxxx names anyway.
Perhaps worth noting, if the proposal included new suffixes for
literals, then the aliases could be portably defined with something like
using float32_t = decltype(1.0F32);
Tom.
>
> -- Gaby
>
> -----Original Message-----
> From: Tom Honermann <tom_at_[hidden]>
> Sent: Thursday, October 7, 2021 9:25 AM
> To: Gabriel Dos Reis <gdr_at_[hidden]>; Aaron Ballman <aaron_at_[hidden]>; WG14/WG21 liaison mailing list <liaison_at_[hidden]>
> Subject: Re: [wg14/wg21 liaison] C and C++ Compatibility SG meeting summary for Oct 06, 2021
>
> On 10/7/21 12:19 PM, Gabriel Dos Reis wrote:
>> The polls that were taken before this one indicated that both languages are headed towards distinct types that behave similarly in certain ways, but distinctly in other ways, and yet it was repeated that the goal was that if a program using those types compiles in both C and C++, then the runtime semantics should be the same. And that wasn't happening. Consequently, pretending that the types in C++ were aliases to the types in C was just plain misleading and wrong. If we are concerned about economic harms because of differences, there subtle differences should dissuade us to purse an "type aliasing" semantics.
> Thank you, Gaby, but I'm still a little confused. Could you please
> elaborate with regard to what runtime semantics you believe would
> differ? What changes would be needed to align the runtime semantics
> across the languages?
>
> Tom.
>
>> -- Gaby
>>
>> -----Original Message-----
>> From: Aaron Ballman <aaron_at_[hidden]>
>> Sent: Thursday, October 7, 2021 8:55 AM
>> To: WG14/WG21 liaison mailing list <liaison_at_[hidden]>
>> Cc: Tom Honermann <tom_at_[hidden]>
>> Subject: Re: [wg14/wg21 liaison] C and C++ Compatibility SG meeting summary for Oct 06, 2021
>>
>> On Thu, Oct 7, 2021 at 11:39 AM Tom Honermann via Liaison
>> <liaison_at_[hidden]> wrote:
>>> Thank you for hosting the meeting yesterday, Aaron!
>> My pleasure, I'm glad it was a productive meeting, thank you for participating!
>>
>>> With regard to this poll: Should the _Float* C names be available
>>> (through some means) in C++ and be used as the types behind the
>>> std::float* aliases?
>>>
>>> The SA vote rationale was "My reasons against were that similar but
>>> slightly incompatible types is not good for the same names. ...."
>>>
>>> Previous polls had consensus to align the usual arithmetic conversions
>>> between C and C++, but did not have consensus for applying the C++
>>> implicit conversion rules to C. With regard to the SA rationale above,
>>> is the "slightly incompatible types" concern directed at those
>>> differences in the implicit conversion rules? Or is the concern over
>>> other differences? If the latter, a list of notable differences would be
>>> useful.
>> I'll leave it to the person who made the comments to explain further,
>> but my personal interpretation of the comment was that there was
>> unease with exposing the C names in C++ unless the semantics were
>> identical and there are cases where the semantics are compatible for a
>> well-formed program in both languages but not identical across
>> languages. If I have this wrong, hopefully I'll be corrected.
>>
>>> My understanding is that the intent of P1467R4, and as stated by the
>>> author yesterday, is that these types would have the same semantics in
>>> each language with the only exception being that, in some cases, a use
>>> may be ill-formed in one language and not the other (e.g., the
>>> differences in the implicit conversion rules).
>> This matches my understanding of the authors' intent with P1467.
>>
>> ~Aaron
>>
>>> Tom.
>>>
>>> On 10/7/21 8:57 AM, Aaron Ballman via Liaison wrote:
>>>> The meeting minutes from the Oct 2021 special session on
>>>> floating-point types can be found at:
>>>> https://nam06.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwiki.edg.com%2Fbin%2Fview%2FWg21telecons2021%2FTeleconference2021-10-06&data=04%7C01%7Cgdr%40microsoft.com%7C0c4485021a2d45b8ce5c08d989af0da0%7C72f988bf86f141af91ab2d7cd011db47%7C1%7C0%7C637692207217336419%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=bSnTbVP%2FO12LCJUY%2FEjiTRviQcgBsD59Y3egY1qUjQs%3D&reserved=0.
>>>> The WG14 minutes will be posted to the document log in the near
>>>> future.
>>>>
>>>> Big thanks to Rajan Bhakta for taking minutes, and to all the
>>>> attendees for having such a productive special session!
>>>>
>>>> ~Aaron
>>>> _______________________________________________
>>>> Liaison mailing list
>>>> Liaison_at_[hidden]
>>>> Subscription: https://nam06.safelinks.protection.outlook.com/?url=https%3A%2F%2Flists.isocpp.org%2Fmailman%2Flistinfo.cgi%2Fliaison&data=04%7C01%7Cgdr%40microsoft.com%7C0c4485021a2d45b8ce5c08d989af0da0%7C72f988bf86f141af91ab2d7cd011db47%7C1%7C0%7C637692207217336419%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=7R18sXyeYEXGBHg0CfrcIVSGFdsHIVcnd9V4ko3zBTM%3D&reserved=0
>>>> Link to this post: https://nam06.safelinks.protection.outlook.com/?url=http%3A%2F%2Flists.isocpp.org%2Fliaison%2F2021%2F10%2F0867.php&data=04%7C01%7Cgdr%40microsoft.com%7C0c4485021a2d45b8ce5c08d989af0da0%7C72f988bf86f141af91ab2d7cd011db47%7C1%7C0%7C637692207217336419%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=fIgqzD6vLiC9jNGD0l3D2r63x%2Bxh4DepZPV1CWcisx8%3D&reserved=0
>>> _______________________________________________
>>> Liaison mailing list
>>> Liaison_at_[hidden]
>>> Subscription: https://nam06.safelinks.protection.outlook.com/?url=https%3A%2F%2Flists.isocpp.org%2Fmailman%2Flistinfo.cgi%2Fliaison&data=04%7C01%7Cgdr%40microsoft.com%7C0c4485021a2d45b8ce5c08d989af0da0%7C72f988bf86f141af91ab2d7cd011db47%7C1%7C0%7C637692207217336419%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=7R18sXyeYEXGBHg0CfrcIVSGFdsHIVcnd9V4ko3zBTM%3D&reserved=0
>>> Link to this post: https://nam06.safelinks.protection.outlook.com/?url=http%3A%2F%2Flists.isocpp.org%2Fliaison%2F2021%2F10%2F0868.php&data=04%7C01%7Cgdr%40microsoft.com%7C0c4485021a2d45b8ce5c08d989af0da0%7C72f988bf86f141af91ab2d7cd011db47%7C1%7C0%7C637692207217336419%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=0RjcPBY%2BkF%2BcQCCG0hvkyDT4EJfAnuMO2XSgtomvKxY%3D&reserved=0
>
Received on 2021-10-07 12:19:55