<div dir="ltr"><div>>„NaN“ is a special value for floating point numbers defined in IEEE 754. In Oberon, DIV and MOD are defined on positive INTEGERs. Hence, no "NaN".</div><div><br></div><div>Is that defined in the hardware Joerg?</div><div>Since The language specifies for O2 : that an integer is between MIN(INTEGER) and MAX(INTEGER). </div><div>For O7 it is not defined but there is an absolute value function in section 10.2:</div><div><br></div><div>ABS(x) x: numeric type | type of x | absolute value.<br></div><div><br></div><div>>Do the NaNs depend on the hardware support?</div><div><br></div><div>Yes.</div><div>And Texts.Mod has a routine that prints them out as "NaN"</div><div><br></div><div> Texts.WriteReal* (VAR W: Writer; x: REAL; n: INTEGER);<br></div><div><br></div><div>j.</div><div><br></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Wed, May 17, 2017 at 8:54 AM, Skulski, Wojciech <span dir="ltr"><<a href="mailto:skulski@pas.rochester.edu" target="_blank">skulski@pas.rochester.edu</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Joerg:<br>
<span class=""><br>
>> 1. Does Oberon support NaN? If not then maybe it should?<br>
>> 2. Could the "undefined" become "defined as NaN" in all numerical cases which are now undefined?<br>
<br>
>„NaN“ is a special value for floating point numbers defined in IEEE 754. In Oberon, DIV and MOD are defined on positive INTEGERs. Hence, no "NaN".<br>
<br>
</span>This is why I said "somewhat related". I understand the integer case, but how about the floating point?<br>
<br>
Do the NaNs depend on the hardware support? Is it wise to specify them in the language?<br>
<br>
Wojtek<br>
<div class="HOEnZb"><div class="h5">--<br>
<a href="mailto:Oberon@lists.inf.ethz.ch">Oberon@lists.inf.ethz.ch</a> mailing list for ETH Oberon and related systems<br>
<a href="https://lists.inf.ethz.ch/mailman/listinfo/oberon" rel="noreferrer" target="_blank">https://lists.inf.ethz.ch/<wbr>mailman/listinfo/oberon</a><br>
</div></div></blockquote></div><br></div>