【发布时间】:2013-10-16 20:35:49
【问题描述】:
我知道
debug writeln("Some good debug message")
在pure 函数中,但是我仔细标记为@safe 或@trusted 的函数呢? DMD 目前不允许 debug writeln 在其中,因为 writeln 和类似的当前是 @system。恕我直言,这非常令人沮丧。有没有巧妙的方法来逃避安全,还是我必须暂时注释掉我所有的 @safe 和 @trusted 标签?
【问题讨论】:
标签: d pure-function debug-print memory-safety