Got another problem for ya (don't hate me). Using PerfAnDBPro v0_2_1beta.
It looks as though PerfAnDBPro loops the code removing REM lines. It is, however, missing REM lines that are ONLY REM lines:
REM *** Include File: Basic_Subs.dba ***
REM Created: 11/5/2008 4:59:48 PM
REM
REM Included in Project: E:\My Documents\My Projects\Project1\Project1.dbpro
REM
Edit: Even the forum syntax highlighter doesn't recognize those lines.
It removes the first, second, and fourth line, but the third and fifth stay in the project and Performance code is added to it. Might be a problem there since the performance code before it is run, but the code after most likely is not since it follows a REM statement:
Write DataFile Integer filePerfDat, 0 : Write Datafile Integer filePerfDat, 1452 : diPerfAnTimerStart = PerfTimer() : REM : diPerfAnTimer = PerfTimer() : diPerfAnRes = PerfTimer() : diPerfAnDBPTimer = Timer() : Write DataFile Double Integer filePerfDat, diPerfAnTimerStart : Write DataFile Double Integer filePerfDat, diPerfAnTimer : Write DataFile Double Integer filePerfDat, diPerfAnRes : Write DataFile Double Integer filePerfDat, diPerfAnDBPTimer : Write DataFile Integer filePerfDat, 0 : Write Datafile Integer filePerfDat, 1452
Write DataFile Integer filePerfDat, 0 : Write Datafile Integer filePerfDat, 1454 : diPerfAnTimerStart = PerfTimer() : REM : diPerfAnTimer = PerfTimer() : diPerfAnRes = PerfTimer() : diPerfAnDBPTimer = Timer() : Write DataFile Double Integer filePerfDat, diPerfAnTimerStart : Write DataFile Double Integer filePerfDat, diPerfAnTimer : Write DataFile Double Integer filePerfDat, diPerfAnRes : Write DataFile Double Integer filePerfDat, diPerfAnDBPTimer : Write DataFile Integer filePerfDat, 0 : Write Datafile Integer filePerfDat, 1454
Then I have the problem of the Randomly Moved REM lines. This is part of my GUI system, making a dialog box to allow the user to set the options:
FUNCTION XP_MainMenu_AdvOptions_Display()
` 40+ lines of code here, emitted
inc cY, 16
chk13 = MyGUIMakeWindow(MG_CLASS_RADIOBOX, 1, "Host", 25, cY, 18, 18, wnd1, 9) : if bit get(OPT_STATCHANGE_BIN,0) = 1 then MyGUISetWindowData(chk13,1)
chk14 = MyGUIMakeWindow(MG_CLASS_RADIOBOX, 1, "Players", 100, cY, 18, 18, wnd1, 9) : if bit get(OPT_STATCHANGE_BIN,1) = 1 then MyGUISetWindowData(chk14,1)
chk15 = MyGUIMakeWindow(MG_CLASS_RADIOBOX, 1, "FFA", 200, cY, 18, 18, wnd1, 9) : if bit get(OPT_STATCHANGE_BIN,2) = 1 then MyGUISetWindowData(chk15,1)
inc cY, 95
btn1 = MyGUIMakeWindow(MG_CLASS_BUTTON, 0, "Save Changes", 16, cY, 125, 20, wnd1, 4)
btn2 = MyGUIMakeWindow(MG_CLASS_BUTTON, 0, "Standard", 32+125, cY, 125, 20, wnd1, 4)
endfunction
FUNCTION XP_MainMenu_AdvOptions_Hide()
` 30+ lines of code here, emmitted
endfunction
FUNCTION XP_MainMenu_Options_Hide()
` 4 lines of code here, emitted
ENDFUNCTION
function Set_Fullscreen()
` 15 lines of code here emitted
endfunction
OK, so I have the function XP_MainMenu_AdvOptions_Display(), followed by 3 more functions. The next source file in compile order is the file that actually creates the window, XP_GUI.dba. It begins with:
REM *** Include File: XP_GUI.dba ***
REM Created: 11/10/2008 7:11:27 PM
REM
REM Included in Project: E:\My Documents\My Projects\Project1\Project1.dbpro
REM
Now, take a gander at this code after PerfAnDBPro has it's way with it:
Write DataFile Integer filePerfDat, 0 : Write Datafile Integer filePerfDat, 2562 : diPerfAnTimerStart = PerfTimer() : chk14 = MyGUIMakeWindow(MG_CLASS_RADIOBOX, 1, "Players", 100, cY, 18, 18, wnd1, 9) : diPerfAnTimer = PerfTimer() : diPerfAnRes = PerfTimer() : diPerfAnDBPTimer = Timer() : Write DataFile Double Integer filePerfDat, diPerfAnTimerStart : Write DataFile Double Integer filePerfDat, diPerfAnTimer : Write DataFile Double Integer filePerfDat, diPerfAnRes : Write DataFile Double Integer filePerfDat, diPerfAnDBPTimer : Write DataFile Integer filePerfDat, 0 : Write Datafile Integer filePerfDat, 2562
Write DataFile Integer filePerfDat, 1 : Write Datafile Integer filePerfDat, 2563 : diPerfAnTimerStart = PerfTimer() : if bit get(OPT_STATCHANGE_BIN,1) = 1 : diPerfAnTimer = PerfTimer() : diPerfAnRes = PerfTimer() : diPerfAnDBPTimer = Timer() : Write DataFile Double Integer filePerfDat, diPerfAnTimerStart : Write DataFile Double Integer filePerfDat, diPerfAnTimer : Write DataFile Double Integer filePerfDat, diPerfAnRes : Write DataFile Double Integer filePerfDat, diPerfAnDBPTimer : Write DataFile Integer filePerfDat, 2 : Write Datafile Integer filePerfDat, 2563
Write DataFile Integer filePerfDat, 0 : Write Datafile Integer filePerfDat, 2564 : diPerfAnTimerStart = PerfTimer() : MyGUISetWindowData(chk14,1) : diPerfAnTimer = PerfTimer() : diPerfAnRes = PerfTimer() : diPerfAnDBPTimer = Timer() : Write DataFile Double Integer filePerfDat, diPerfAnTimerStart : Write DataFile Double Integer filePerfDat, diPerfAnTimer : Write DataFile Double Integer filePerfDat, diPerfAnRes : Write DataFile Double Integer filePerfDat, diPerfAnDBPTimer : Write DataFile Integer filePerfDat, 0 : Write Datafile Integer filePerfDat, 2564
Write DataFile Integer filePerfDat, 5 : Write Datafile Integer filePerfDat, 2565 : diPerfAnTimerStart = PerfTimer() : EndIf : diPerfAnTimer = PerfTimer() : diPerfAnRes = PerfTimer() : diPerfAnDBPTimer = Timer() : Write DataFile Double Integer filePerfDat, diPerfAnTimerStart : Write DataFile Double Integer filePerfDat, diPerfAnTimer : Write DataFile Double Integer filePerfDat, diPerfAnRes : Write DataFile Double Integer filePerfDat, diPerfAnDBPTimer : Write DataFile Integer filePerfDat, 6 : Write Datafile Integer filePerfDat, 2565
Write DataFile Integer filePerfDat, 0 : Write Datafile Integer filePerfDat, 2566 : diPerfAnTimerStart = PerfTimer() : chk15 = MyGUIMakeWindow(MG_CLASS_RADIOBOX, 1, "FFA", 200, cY, 18, 18, wnd1, 9) : diPerfAnTimer = PerfTimer() : diPerfAnRes = PerfTimer() : diPerfAnDBPTimer = Timer() : Write DataFile Double Integer filePerfDat, diPerfAnTimerStart : Write DataFile Double Integer filePerfDat, diPerfAnTimer : Write DataFile Double Integer filePerfDat, diPerfAnRes : Write DataFile Double Integer filePerfDat, diPerfAnDBPTimer : Write DataFile Integer filePerfDat, 0 : Write Datafile Integer filePerfDat, 2566
Write DataFile Integer filePerfDat, 1 : Write Datafile Integer filePerfDat, 2567 : diPerfAnTimerStart = PerfTimer() : if bit get(OPT_STATCHANGE_BIN,2) = 1 REM *** Include File: XP_GUI.dba ***REM Created: 11/10/2008 7:11:27 PMREM Included in Project: E:\My Documents\My Projects\Project1\Project1.dbpro : diPerfAnTimer = PerfTimer() : diPerfAnRes = PerfTimer() : diPerfAnDBPTimer = Timer() : Write DataFile Double Integer filePerfDat, diPerfAnTimerStart : Write DataFile Double Integer filePerfDat, diPerfAnTimer : Write DataFile Double Integer filePerfDat, diPerfAnRes : Write DataFile Double Integer filePerfDat, diPerfAnDBPTimer : Write DataFile Integer filePerfDat, 2 : Write Datafile Integer filePerfDat, 2567
Write DataFile Integer filePerfDat, 0 : Write Datafile Integer filePerfDat, 2568 : diPerfAnTimerStart = PerfTimer() : MyGUISetWindowData(chk15,1) : diPerfAnTimer = PerfTimer() : diPerfAnRes = PerfTimer() : diPerfAnDBPTimer = Timer() : Write DataFile Double Integer filePerfDat, diPerfAnTimerStart : Write DataFile Double Integer filePerfDat, diPerfAnTimer : Write DataFile Double Integer filePerfDat, diPerfAnRes : Write DataFile Double Integer filePerfDat, diPerfAnDBPTimer : Write DataFile Integer filePerfDat, 0 : Write Datafile Integer filePerfDat, 2568
Write DataFile Integer filePerfDat, 5 : Write Datafile Integer filePerfDat, 2569 : diPerfAnTimerStart = PerfTimer() : EndIf : diPerfAnTimer = PerfTimer() : diPerfAnRes = PerfTimer() : diPerfAnDBPTimer = Timer() : Write DataFile Double Integer filePerfDat, diPerfAnTimerStart : Write DataFile Double Integer filePerfDat, diPerfAnTimer : Write DataFile Double Integer filePerfDat, diPerfAnRes : Write DataFile Double Integer filePerfDat, diPerfAnDBPTimer : Write DataFile Integer filePerfDat, 6 : Write Datafile Integer filePerfDat, 2569
Write DataFile Integer filePerfDat, 0 : Write Datafile Integer filePerfDat, 2571 : diPerfAnTimerStart = PerfTimer() : inc cY, 95 : diPerfAnTimer = PerfTimer() : diPerfAnRes = PerfTimer() : diPerfAnDBPTimer = Timer() : Write DataFile Double Integer filePerfDat, diPerfAnTimerStart : Write DataFile Double Integer filePerfDat, diPerfAnTimer : Write DataFile Double Integer filePerfDat, diPerfAnRes : Write DataFile Double Integer filePerfDat, diPerfAnDBPTimer : Write DataFile Integer filePerfDat, 0 : Write Datafile Integer filePerfDat, 2571
Write DataFile Integer filePerfDat, 0 : Write Datafile Integer filePerfDat, 2572 : diPerfAnTimerStart = PerfTimer() : btn1 = MyGUIMakeWindow(MG_CLASS_BUTTON, 0, "Save Changes", 16, cY, 125, 20, wnd1, 4) : diPerfAnTimer = PerfTimer() : diPerfAnRes = PerfTimer() : diPerfAnDBPTimer = Timer() : Write DataFile Double Integer filePerfDat, diPerfAnTimerStart : Write DataFile Double Integer filePerfDat, diPerfAnTimer : Write DataFile Double Integer filePerfDat, diPerfAnRes : Write DataFile Double Integer filePerfDat, diPerfAnDBPTimer : Write DataFile Integer filePerfDat, 0 : Write Datafile Integer filePerfDat, 2572
Write DataFile Integer filePerfDat, 0 : Write Datafile Integer filePerfDat, 2573 : diPerfAnTimerStart = PerfTimer() : btn2 = MyGUIMakeWindow(MG_CLASS_BUTTON, 0, "Standard", 32+125, cY, 125, 20, wnd1, 4) : diPerfAnTimer = PerfTimer() : diPerfAnRes = PerfTimer() : diPerfAnDBPTimer = Timer() : Write DataFile Double Integer filePerfDat, diPerfAnTimerStart : Write DataFile Double Integer filePerfDat, diPerfAnTimer : Write DataFile Double Integer filePerfDat, diPerfAnRes : Write DataFile Double Integer filePerfDat, diPerfAnDBPTimer : Write DataFile Integer filePerfDat, 0 : Write Datafile Integer filePerfDat, 2573
Write DataFile Integer filePerfDat, 12 : Write Datafile Integer filePerfDat, 2575 : diPerfAnTimerStart = PerfTimer()
endfunction
Edit: Added syntax highlighting so you can find the problem. Look for green text
This code starts off in XP_MainMenu_AdvOptions_Display() shown above, but right at the end you will see the first comment line from the next source file...
Hope this helps.
Edit: This same thing happens at the end of each source file that precedes a source file with comments like the ones above.
What is really strange is the the 2 empty REM lines inside each of those blocks remain where they should be in the code file, but the REM lines with actual data fly up 60+ lines of code.:
` Last function of source file:
function Set_Fullscreen() : diPerfAnTimer = PerfTimer() : diPerfAnRes = PerfTimer() : diPerfAnDBPTimer = Timer() : Write DataFile Double Integer filePerfDat, diPerfAnTimerStart : Write DataFile Double Integer filePerfDat, diPerfAnTimer : Write DataFile Double Integer filePerfDat, diPerfAnRes : Write DataFile Double Integer filePerfDat, diPerfAnDBPTimer : Write DataFile Integer filePerfDat, 14 : Write Datafile Integer filePerfDat, 2622
` code emitted
endfunction
` The two EMPTY REM lines from the next.
Write DataFile Integer filePerfDat, 0 : Write Datafile Integer filePerfDat, 2638 : diPerfAnTimerStart = PerfTimer() : REM : diPerfAnTimer = PerfTimer() : diPerfAnRes = PerfTimer() : diPerfAnDBPTimer = Timer() : Write DataFile Double Integer filePerfDat, diPerfAnTimerStart : Write DataFile Double Integer filePerfDat, diPerfAnTimer : Write DataFile Double Integer filePerfDat, diPerfAnRes : Write DataFile Double Integer filePerfDat, diPerfAnDBPTimer : Write DataFile Integer filePerfDat, 0 : Write Datafile Integer filePerfDat, 2638
Write DataFile Integer filePerfDat, 0 : Write Datafile Integer filePerfDat, 2640 : diPerfAnTimerStart = PerfTimer() : REM : diPerfAnTimer = PerfTimer() : diPerfAnRes = PerfTimer() : diPerfAnDBPTimer = Timer() : Write DataFile Double Integer filePerfDat, diPerfAnTimerStart : Write DataFile Double Integer filePerfDat, diPerfAnTimer : Write DataFile Double Integer filePerfDat, diPerfAnRes : Write DataFile Double Integer filePerfDat, diPerfAnDBPTimer : Write DataFile Integer filePerfDat, 0 : Write Datafile Integer filePerfDat, 2640