Re: [GD-General] runtime error logging
Brought to you by:
vexxed72
From: Andras B. <bn...@ma...> - 2003-07-15 17:00:08
|
Monday, July 14, 2003, 6:11:21 PM, Stefan Boberg wrote: >> Any ideas on how I could do "singleton" logging of errors? >> Can't think of any simple solution :( > Would this work ok in your case? > #define Singleton_Log(x) { static bool bSeen = false; \ > if (bSeen == false) { bSeen = true; LogMessage(x) } } No, not really. :( The problem is that I handle errors at one place, and I would like to report many different errors and warnings, but only once each. b |