Page 1 of 1

Error message Illegal Natural Number

Posted: Sat Sep 29, 2012 4:59 am
by DeFleur
With this

Code: Select all

startshape SM_CURve

Re1=840	         
Re2=580

shape SQU
{SQUARE [s 25 1 y .5] }

shape RUNsm(natural REC) 
{
if(REC>=Re1)
{SQU [ ]
RUNsm(REC--1) [y 1 r 1]}
else if (REC>=Re2)
{SQU [ ]
RUNsm(REC--1) [y 1 r -1]}
}
shape SM_CURve 
{RUNsm(1001) [ ]}
I am getting an error message on REC with REC >1000
quote Expression does not evaluate to a legal natural number
unquote. However, if parameter REC is chosen <= 1000
there is no such error message. It seems this appears since v30
and was not with preceeding v29. Any help available ?

Re: Error message Illegal Natural Number

Posted: Sat Sep 29, 2012 7:32 am
by MtnViewJohn
This is a new feature in the latest release. In the previous version the maximum natural number is 9007199254740992. In the current release it is set by the CF::MaxNatural variable. The default value for CF::MaxNatural is 1000, but you can set it to anything you want between 1 and 9007199254740992.

Re: Error message Illegal Natural Number

Posted: Sat Sep 29, 2012 8:45 am
by DeFleur
Thank you for prompt reply. The 9007199254740992 will just make it then for my need....