More undocumented programming limitations in the HP Prime



Post: #2

Well, I've found another undocumented limitation with PPL programming. It seems that the LOCAL declaration is limited to a paltry 7 entries, after which it will return a syntax error message when the program is checked. Beyond 7 entries it is necessary a add a second LOCAL declaration for the additional entries, and even more declarations if there are more than 14 entries. This limitation is neither mentioned in the Prime Help nor in the User Guide. Also, the calculator message "syntax error" is really not pertinent, since the statement is syntactically correct, and the message should be something like "exceeds maximum number of 7 entries". A lot of work is needed in documenting the usage of PPL.

Edit. Well after adding a second LOCAL statement, it now appears that the limitation has become 8 entries per LOCAL statement. This is totally confusing.


Edited: 3 Nov 2013, 1:36 p.m.


Post: #3

The limit is 8 for global EXPORTed, global non EXPORTed and LOCAL variables

I got an unofficial information that there is a limit of 16 parameters to functions.

and variables declaration use 2 parameter for each variable

The name and a value

So EXPORT ABC:=123;

use 2 parameters, thus the limit to 8.


An unusual thing is that the value of a program level variable is set only once at parse time. multiple runs of a program do not reset the global variable value until you go to program editor which reparse the program.

Post: #4

Hi,

Here is some info on LOCAL

http://www.hpmuseum.org/cgi-sys/cgiwrap/hpmuseum/archv021.cgi?read=252341#252341


Edited: 3 Nov 2013, 5:58 p.m.


Post: #5

Thanks, Alberto. I missed that earlier thread.


Forum Jump: