Comment Lines interfere with continuation lines

dunbarx at dunbarx at
Wed Jun 27 19:12:58 EDT 2012


This goes back to HC. You cannot interrupt a line-continued, er, line, with a comment.

Once committed, you have to complete the whole thing in one shot.

Logically, this seems counterintuitive. It just must be how the parser thinks.

Craig Newman

-----Original Message-----
From: Peter Haworth <pete at>
To: How to use LiveCode <use-livecode at>
Sent: Wed, Jun 27, 2012 6:45 pm
Subject: Comment Lines interfere with continuation lines

I've got into the habit of surrounding changes to my scripts with a couple
of comment lines that include a reference to the bug/enhancement request
that cuased them to be changed.

I recently ran into this interesting situation.

My original code looked like:

dispatch function "xyz" to button "123" \
    with p1,p2

After commenting, the code looked like this:

dispatch function "xyz" to button "123" \
  --Bug# 567
    with p1,p3
  --/Bug# 567

The "with p1,p3" line was colored correctly, not as a green comment line

When testing the bug fix, I put a breakpoint at the start of funtion "xyz"
and found that the paramaters to it were all empty, depstite the fact that
when checked right at the dispatch command they had non-empty values in

After spending some time trying to figure this out and totally exhausting
my arsenal of swear words that usually fix this type of problem, I
desparately moved the comment lines to before the dispatch command and
after the "with p1,p3" line and all resumed working as expected.

It seems that inserting a comment line after a continued line causes the
remainder of the continued line to be ignored.

Not really very interesting but I thought reporting this may avoid some
unnecessary frustrations.

lcSQL Software <>
use-livecode mailing list
use-livecode at
Please visit this url to subscribe, unsubscribe and manage your subscription 


More information about the use-livecode mailing list