Hello everyone!

I try to compile this recipe with dmd (2.089.0), ldc2 (1.18.0):
https://wiki.dlang.org/Using_string_mixins_for_logging
but get the same error:

mixin_log.d(64): Error: basic type expected, not __FUNCTION__
mixin_log.d(64): Error: declaration expected, not __FUNCTION__

in that part of code:

mixin template set_func_name(string fn)
{
    enum __FUNCTION__ = fn;
}

There is no doubt that this recipe once worked. How to fix it now?

Reply via email to