Steven Schveighoffer: > Well, yes. So? How does the compiler establish rules to separate "safe > debug printing" from "all code that isn't pure"? If you did that, how > does the compiler know it's safe? The only way I can think of is to treat > writeln specially, which doesn't sound like the right thing to do.
In the first post in this thread I have suggested a possible solution that avoids that unsafety, a compilation switch to disable all pure annotations in the program/compilation unit. Then you are able to add printing statements in a version{} relative to this compilation switch. Bye, bearophile