HP Forums
[BUG] Stack Pollution by PPL PRINT Statement - Printable Version

+- HP Forums (https://www.hpmuseum.org/forum)
+-- Forum: HP Calculators (and very old HP Computers) (/forum-3.html)
+--- Forum: HP Prime (/forum-5.html)
+--- Thread: [BUG] Stack Pollution by PPL PRINT Statement (/thread-755.html)



[BUG] Stack Pollution by PPL PRINT Statement - John R. Graham - 02-23-2014 10:21 PM

Still experimenting with PPL, trying to get the feel of it before porting any of my apps from the 50g. I encountered this:
Code:
EXPORT CHARLIE()
BEGIN
  PRINT("Entry mode is "+Entry);
END;
When run, this displays, as you might expect:
Code:
Entry mode is 2
on a separate scrolling screen (I'm an RPN junkie). What was unexpected was that the same text ended up on the lowest level of the stack as a quoted string. A little more experimentation revealed that this behavior only manifests with PPL programs that do not return a value.

- John