Comment /* */ generates errors
Posted by PRogman on
URL: http://spssx-discussion.165.s1.nabble.com/Comment-generates-errors-tp5740837.html
I have discovered some strange behavior when commenting syntax. A comment using the '/* text */' format generates errors or makes the syntax color coding fail in some cases. It seems to be the closing '*/' that triggers the error.
Has it always been like this, or is my system flaky?
/PR
*********************.
DATA LIST LIST /
A B (2F8.0).
BEGIN DATA
1 1
END DATA.
DATASET NAME CommentErrors.
COMPUTE C = A * B.
EXECUTE. /* error: EXECUTE Unrecognized text appears on the EXECUTE command. This command allows no subcommands. */.
EXECUTE.
COMPUTE D = A * B. /*error: COMPUTE Incorrect variable name: either the name is more than 64 characters, or it is not defined by a previous command. */.
EXECUTE.
COMPUTE E = A * B. /*works.
EXECUTE.
COMPUTE F = A * B.
/*works*/.
EXECUTE.
IF (A EQ 1) G = A * B. /*works.
EXECUTE.
IF (A EQ 1) H = A * B. /*error*/.
EXECUTE.
COMPUTE J = 0.
LOOP # = 1 TO 10. /*loop works, syntax check 'loop-end loop' works */.
COMPUTE J = J + A.
END LOOP.
EXECUTE.
COMPUTE J = 0.
LOOP # = 1 TO 10.
COMPUTE J = J + A.
END LOOP. /*loop works, but comment make syntax color coding 'loop-end loop' fail, also 'do if-end if'...*/.
EXECUTE.
*********************.