Hi Craig, I kind of see why it doesn't work. The main surprise was that the line after the comment was correctly colored, seems like it should have been colored like a comment, then the problem would have been obvious.
However, it has made me realise that I should really be doing more validation of parameters at the start of a function/command. That would have detected it right away. Pete lcSQL Software <http://www.lcsql.com> On Wed, Jun 27, 2012 at 4:12 PM, <dunb...@aol.com> wrote: > Hi. > > > 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 <p...@lcsql.com> > To: How to use LiveCode <use-livecode@lists.runrev.com> > 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 > them. > > 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. > > Pete > lcSQL Software <http://www.lcsql.com> > _______________________________________________ > use-livecode mailing list > use-livecode@lists.runrev.com > Please visit this url to subscribe, unsubscribe and manage your > subscription > preferences: > http://lists.runrev.com/mailman/listinfo/use-livecode > > > _______________________________________________ > use-livecode mailing list > use-livecode@lists.runrev.com > Please visit this url to subscribe, unsubscribe and manage your > subscription preferences: > http://lists.runrev.com/mailman/listinfo/use-livecode > _______________________________________________ use-livecode mailing list use-livecode@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-livecode