Either I'm remembering things wrong, or there is no such compile time variable available in PB to where you could check the status of the compile with a #IF and block out sections of code which don't need to be in the runtime version of the program.
Announcement
Collapse
No announcement yet.
Quirk Question: Compile Type Checking If Debugger
Collapse
X
-
???
#IF itself can do this for you
Code:%MY_DEBUG = 0|1 #IF %MY_DEBUG Code here only compiled when %MY_DEBUG is non-zero #ENDIF
Michael Mattias
Tal Systems (retired)
Port Washington WI USA
[email protected]
http://www.talsystems.com
-
There's the use of #IF as MCM has noted. If you are using PB9 (I did not go back and look at 8) then in the Help, Command Summary\Compiler Operations page are others that may be of use depending on how you may be "debugging". There, in addition to #IF, are #DEBUG CODE and #TOOLS directives which could be used as additional control methods for your needs.Rick Angell
Comment
-
THis appears in the help under ENVIRON$...
Code:IF LEN(ENVIRON$("PBDEBUG")) THEN _ CALL DisplayMyDebugData()
Of course, that is only "kind of like" compile-time. It's not runtime, but the program has already been compiled by the time you start executing. It's "tweener" time I guess.Michael Mattias
Tal Systems (retired)
Port Washington WI USA
[email protected]
http://www.talsystems.com
Comment
Comment