[fpc-pascal] Wince+DebugLn

Denis Golovan denisgolovan at yandex.ru
Sun Mar 2 18:05:33 CET 2008


Hi, all!

  When trying to debug LCL DebugLn is rather useful.
  AFAIU, decision about logging is carried out on initialization of LCLProc unit.
  Debugging ordinary progs is quite comfortable :).

  Wince progs is the other story. As we don't have console on Wince (I mean standart M$-made console), I cannot turn on and off debugging on fly 
(as command-line args). Now I must path LCLProc unit to unconditionally enable logging. So I have a proposition:

  As we have debugging code included whether debugging turned off or on, maybe we can add one argument to InitializeDebugOutput and move it into 
interface section?
  
  For example:

  ...
  procedure InitializeDebugOutput(const FileName:string='');
  ...

  Now I'll be able to call it directly from lpr unit before any other statements or even make a unit with initialization calling it and insert it 
before any other unit use (like Memchk in Delphi).

  How do you think?

-- 
Best regards,
Denis Golovan aka MageSlayer



More information about the fpc-pascal mailing list