Not sure if this one has come up yet, but I have been experiencing some strange behavior in that some of my strings seem to disappear when used as parameters for procedure calls.
I'm not in a position to offer a demo program, and unfortunately, this does not seem to happen in every situation, but here is in essence what is happening. Consider:
TYPE STRING63 = STRING(63);
FUNCTION x : STRING63; { returns a nonempty string }
PROCEDURE y(z, t : STRING63); { ... }
VAR a, b : STRING63;
BEGIN a := 'hi'; y(x, a); <..>
Now if I try to use t within y, I should get the string 'hi', but it turns out to be an empty string (even if I WRITE(t) immediately after the opening BEGIN in the procedure). However, if I do this:
a := 'hi'; b := x; y(b, a);
then it works correctly.
There seems to be a problem with using a function returning a string (maybe just one with no parameters?) directly as an argument to a procedure. Storing the result in a variable then using the variable as the parameter solves the problem.
Obviously this creates a simple workaround, but it is still a bug...
----------------------------------------------------------- Frank D. Engel, Jr. fde101@fjrhome.net
____________________________________________________________ Free 20 MB Bannerless Domain Hosting, 1000 MB Data Transfer 10 Personalized POP and Web E-mail Accounts, and more. Get It Now At www.doteasy.com