Igor Stasenko wrote:

Sometimes you want to stub out a tools to make them inaccessible. Or
replace them with different ones.
For instance, one would like to redirect Transcript output to file, or
suppress debugger / browser / inspector.

The proposed solution is more a symptom fix than a real solution.

You want to make the number of access points as small as possible, so you have e.g. one point where to turn off the debugger. By that I mean turning off the debugger and not trick the system by stubbing it out.

Same for access to Transcript. There shouldn't really be *any* direct reference to Transcript to begin with, but rather a small but effective logging API, e.g. Josef's toothpick.

We Smalltalkers (I just happen to reply to Igor here, I'm including myself in this remark too ;-) ) tend to use magic tricks just because we can, but that doesn't mean it is good engineering.

Michael

_______________________________________________
Pharo-project mailing list
[email protected]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project

Reply via email to