On 5/30/11 3:48 PM, Vincent wrote:
On Mon, 30 May 2011 14:24:10 +0200, David Nadlinger <[email protected]>
wrote:

First, please note that Jose turned verbose logging on just for IO as
well, you might want to have a closer look at his post.

Oh, really? This is cite from his library:

vlog(0)("Verbosity 0 message");
vlog(1)("Verbosity 1 message");

Can you point me where is any logical separation between modules?

In his post you originally replied to, he wrote: »So QA reruns the app with the command line option --vmodule=io=3« – note the »io« part there. In terms of code, e.g. here:

https://github.com/jsancio/phobos/blob/master/std/log.d#L864


Second, your proposal doesn't allow enabling/disabling verbose logging...

My realisation have no any 'verbosity' at all due to helpless.
But yes, to completely remove logging (from binaries) you have to
recompile the program. Or you can do it at runtime, just 1 line of code.
And look please at second version: http://pastebin.com/fd3UCgjv - it
doesn't force you to use version(log) anymore.

I was referring to the post of you I actually cited, where you wrote:

---
In this case I prefer snippets like this:

// some IO logic
version(log_io) logDbg(`SENT: ` ~ line);
---

Clearly, you can't activate/deactivate logging at runtime here, but you proposed that directly in answer to a post where the merits of being able to enable verbose logging in an existing application were discussed.

No offense intended, but could you please try to respect common newsgroup/mailing list etiquette and actually read the posts you are replying to?

David

Reply via email to