On 10/27/2014 09:08 AM, Robert burner Schadek wrote:

And again I'm saying fixing the LogLevel at CT is not good enough. And
the other part of the solution uses class just like std.logger.

Right, a CT LogLevel only works for certain use-cases and I never claimed that it works for everything (that's why there is the loggerObject adapter). This not an argument to go solely with classes though. And you loose an important optimization by not making use of CT LogLevels. Introducing the concepts and providing the loggerObject adapter (structs to interface) is a very flexible solution that proved itself very successful for ranges.

And the hierarchy you're building is also at CT, which is just not gone
work, if you don't have ultimate control of all sources.

What's the problem here, a counterexample would be helpful.

Logger logger;
if (config.alsoLogToFile)
    logger = loggerObject(multiLogger(SysLogger(), FileLogger()));
else
    logger = loggerObject(SysLogger());

Reply via email to