<div class="gmail_quote">On Fri, Apr 22, 2011 at 12:34 AM, dennis luehring <span dir="ltr"><<a href="mailto:dl.soluz@gmx.net">dl.soluz@gmx.net</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">

On 17.04.2011 22:45, Andrew Wiley wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
On Sun, Apr 17, 2011 at 3:30 PM, dennis luehring<<a href="mailto:dl.soluz@gmx.net" target="_blank">dl.soluz@gmx.net</a>>  wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
On 11.04.2011 23:27, bearophile wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br>
  From what I am seeing, in a D2 program if I have many (tens or more) pure<br>
functions that call to each other, and I want to add (or activate) a<br>
printf/writeln inside one (or few) of those functions to debug it, I may<br>
need to temporarily comment out the "pure" attribute of many functions<br>
(because printing can't be allowed in pure functions).<br>
<br>
As more and more D2 functions become pure in my code and in Phobos,<br>
something like a -disablepure compiler switch (and printf/writeln inside<br>
debug{}) may allow more handy debugging with prints (if the purity is well<br>
managed by the compiler then I think disabling the pure attributes doesn't<br>
change the program output).<br>
<br>
Bye,<br>
bearophile<br>
</blockquote>
<br>
sounds a little bit like the need to see an private/protected part of an<br>
interface in unittest scenarios - just to be able to test it in a<br>
whitebox-testing without changing the attributes of the productive-code<br>
</blockquote>
<br>
Isn't this already there because "private" makes things visible to all<br>
other code in the same module?<br>
</blockquote>
<br>
ok - but what about protected? as a whitebox tester im not able(allowed) to change productive code,but i need to test through all the code (especially when doing code-coverage stuff)<br></blockquote><div><br></div><div>As far as I'm aware, all the visibility levels make things visible to code in the same module. </div>

</div><br>