From: Robert Dober Date: 2007-02-08T08:00:48+09:00 Subject: Patterns of semantic contradictions? ------=_Part_13034_7384616.1170889245717 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Content-Disposition: inline Hi list I just could not resist to post a stupid remark - which was taken very gracefully ty ;) - to a thread where somebody corrected his typo with the well known sub idiom, only that he did something like "abcdefghijklmnop".gsub(/a/,"A") I am kind of troubled with this, of course this is equivalent to using #sub, and the question that arose in my head is the following. Is this a pattern to avoid? Can there be good reasons to do this and furthermore and most importantly are there some publications about "Antipatterns" like that. Maybe on much grater scale than my fun example. Well it is time to explain why it is an Antipattern to me, maybe you do not agree at all. being a code reviewer and seeing 5 lines later "abcda".gsub(/a/,"A") I will be troubled, or should I not? Is it sound to assume that the coder knows what she is doing? Long live extreme programming ;) Cheers Robert -- We have not succeeded in answering all of our questions. In fact, in some ways, we are more confused than ever. But we feel we are confused on a higher level and about more important things. -Anonymous ------=_Part_13034_7384616.1170889245717--