Error shows wrong file. (triggered by control code i guess)

Forum for discussion about the Windows IDE of Hollywood
Post Reply
Bugala
Posts: 1329
Joined: Sun Feb 14, 2010 7:11 pm

Error shows wrong file. (triggered by control code i guess)

Post by Bugala »

This is a very minor bug, more of inconvenience than actual trouble.

I have two different files named "Main", which have nothing to do with each other, and which reside in different folders.

Thing is, when I add these lines:

Code: Select all

Local NewTable = {}
ForEach(T_Brush, Function(ID, Content)
		NewTable[Content] = ID
	EndFunction)

ForEach(LoadingBar.LoadBrushes, Function(ID, Content)
	Local String="GFX.AddBrush(\""..NewTable[Content.ID].."\", \""..Content.File.."\")"
	If HasItem(Content, "alpha") = True Then String=""..String..", True"
	DebugPrint(""..String..")")
	EndFunction)	
The error I receive is right, it tells the correct error and correct line. BUT, strangely it shows the wrong MAIN file.

As lets say they are MAIN1 and MAIN2.

I add these lines to MAIN2, execute, and when error comes, it tells the error line on MAIN2 right, but it shows up the MAIN1.

I suppose I have accidentally used some IDE control code, but do you know which in these two trigger it?

I do know it is in lines between the Foreach FUNCTION() and ENDFUNCTION, those are causing it, since if I remove them, everything works normally.
Bugala
Posts: 1329
Joined: Sun Feb 14, 2010 7:11 pm

Re: Error shows wrong file. (triggered by control code i guess)

Post by Bugala »

Not sure the code I posted is the one that triggered it, since now I closed Hollywood IDE and things work normal again, so might be errorenous version was control code and it stayed that way until I restarted Hollywood IDE.

I had an error something like this:

Code: Select all

NewTable[Content] = ID)
an extra ")" at end of this line, and this line:

Code: Select all

Local String="GFX.AddBrush(\""..NewTable[Content.ID].."\", \""..Content.File.."\")")
So those might have been the control codes.
User avatar
airsoftsoftwair
Posts: 5673
Joined: Fri Feb 12, 2010 2:33 pm
Location: Germany
Contact:

Re: Error shows wrong file. (triggered by control code i guess)

Post by airsoftsoftwair »

Is this error clearly reproducible or did it show only once?
Bugala
Posts: 1329
Joined: Sun Feb 14, 2010 7:11 pm

Re: Error shows wrong file. (triggered by control code i guess)

Post by Bugala »

Not reproducible since Im not sure what triggered it, so cant test it anymore.

Point being that suddenly it happened that it showed the error in wrong main file, but I first didn't realise that it was only opening the wrong main file, but still telling the correct error.

It continued doing this way, which is why I thought that something kept triggering it again, and again, but because even after having corrected the code it kept doing this way, I suppose it could have been only in the first version of the code, that it maybe triggered some IDE control code, which stayed on.

This is also why I cant remember what exactly was the original version that triggered it.
Post Reply