On 6/25/15 7:10 AM, Vladimir Panteleev wrote:
And, IMHO, this:fileName.readText.lowerCased.detabbed.toFile(fileName.withExtension(".foo")) looks much better than this: fileName.readText.lowerCaser.detabber.toFile(fileName.extensionSetter(".foo"))
I agree with Jonathan that the latter is clearer as to what the method is doing--constructing something that will do the work. However, I agree that the former reads much better. My bikeshed is painted the former way, mainly because it encourages people to use the range-based style because it reads so well.
With that said I'm hopeful that Adam's trick will obviate at least some of this discussion.
