<span style=" font-size:10pt;font-family:sans-serif">Sorry, last sentence
had a copy/paste error... It is corrected below.</span><br><br><span style=" font-size:10pt;font-family:sans-serif">Regards,<br><br>Rajan Bhakta<br>z/OS XL C/C++ Compiler Technical Architect<br>ISO C Standards Representative for Canada, PL22.11 Chair (USA)<br>C Compiler Development<br>Contact: rbhakta@us.ibm.com, Rajan Bhakta/Houston/IBM</span><br><br><br><br><span style=" font-size:9pt;color:#5f5f5f;font-family:sans-serif">From:
</span><span style=" font-size:9pt;font-family:sans-serif">"Rajan
Bhakta" <rbhakta@us.ibm.com></span><br><span style=" font-size:9pt;color:#5f5f5f;font-family:sans-serif">To:
</span><span style=" font-size:9pt;font-family:sans-serif">Cfp
<cfp-interest@oakapple.net></span><br><span style=" font-size:9pt;color:#5f5f5f;font-family:sans-serif">Date:
</span><span style=" font-size:9pt;font-family:sans-serif">02/18/2020
08:26 AM</span><br><span style=" font-size:9pt;color:#5f5f5f;font-family:sans-serif">Subject:
</span><span style=" font-size:9pt;font-family:sans-serif">[EXTERNAL]
[Cfp-interest 1485] Action item: Constant expressions _Float16</span><br><span style=" font-size:9pt;color:#5f5f5f;font-family:sans-serif">Sent
by: </span><span style=" font-size:9pt;font-family:sans-serif">cfp-interest-bounces@oakapple.net</span><br><hr noshade><br><br><br><span style=" font-size:10pt;font-family:sans-serif">For my action
item:<br> Rajan: Ensure casting to _Float16 won't cause a problem with
the using INFINITY wherever a constant expression can be used change we
proposed.</span><span style=" font-size:12pt"><br></span><span style=" font-size:10pt;font-family:sans-serif"><br>From 6.6p1, it fits the description.<br>From 6.6p3 and 4 (constraints), none are violated.<br>From 6.6p6 has floating constants as immediate operands of casts which
applies if INFINITY is a floating constant.<b><br>From 6.6p8 has casts on converting arithmetic to arithmetic types which
fits this case as _Float16 is an interchange type which is a real floating
type which is a floating type which is an arithmetic type, and INFINITY
has a real floating type.</b><br>From 6.4.4.2 it says INFINITY is not directly a floating constant (from
the grammar). It needs to be constructed out of a digit-sequence or some
other means.<br>From 6.6p10, implementations can support other constant expressions. This
catch-all seems to allow nearly anything.<b><br>From 7.12p4 it says INFINITY IS a constant expression.</b></span><span style=" font-size:12pt"><br></span><span style=" font-size:10pt;font-family:sans-serif"><br>So given 7.12p4 + 6.6p8 I would say that casting to _Float16 will not cause
a problem.</span><span style=" font-size:12pt"><br></span><span style=" font-size:10pt;font-family:sans-serif"><br>Regards,<br><br>Rajan Bhakta<br>z/OS XL C/C++ Compiler Technical Architect<br>ISO C Standards Representative for Canada, PL22.11 Chair (USA)<br>C Compiler Development<br>Contact: rbhakta@us.ibm.com, Rajan Bhakta/Houston/IBM</span><tt><span style=" font-size:10pt">_______________________________________________<br>Cfp-interest mailing list<br>Cfp-interest@oakapple.net<br></span></tt><a href="http://mailman.oakapple.net/mailman/listinfo/cfp-interest"><tt><span style=" font-size:10pt">http://mailman.oakapple.net/mailman/listinfo/cfp-interest</span></tt></a><tt><span style=" font-size:10pt"><br></span></tt><br><br><BR>