|
Advertisement
|
Forum posts by Bill Venners:Posted in Articles Forum, Sep 22, 2008, 10:00 PM
In this article, Scott Meyers describes a technique that enables the specification of arbitrary combinations of user-defined code features on a per-function basis and that detects violations of feature constraints during compilation.
Posted in ScalaTest/ScalaUtils Forum, Sep 22, 2008, 7:56 PM
Hi Channing,Yes, I need to do another release for 2.7.2. 2.7.2 is a release candidate right now, but I'll go ahead and do the build for it and put it on the website. I'll try and get that on there later today. I'll just update it once it is released for real.Thanks.Bill
Posted in Programming in Scala Forum, Sep 20, 2008, 2:16 AM
Hi Kris,I think I just killed two birds with one stone. On rereading your post, I realized you were talking about something different than the other post I pointed you to. And your complaint is more deserved I think. I do think that people should strive to make things as readable as possible, but refactoring away one of the list traversals I...
Posted in Programming in Scala Forum, Sep 18, 2008, 11:53 PM
Hi Kris,Thanks for the feedback. That's the second time this reaction has shown up in this forum. The first one was here:http://www.artima.com/forums/flat.jsp?forum=282&thread=237049The problem is to run through the list just once would require using a "pattern" in the for expression, which hasn't been introduced yet. But I think that I...
Posted in Programming in Scala Forum, Sep 13, 2008, 5:41 PM
Hi Daniel,Easy to miss. There's a note in the Preface that some of the ScalaTest stuff in the Unit testing chapter will not be released until after the book goes to the printer. It is in the trunk, but not in the current release. Sorry. The problem is if I take a week to do the next ScalaTest release, the book will be delayed by another week...
Posted in Programming in Scala Forum, Sep 9, 2008, 9:41 AM
HI Vladimir,Sorry, I think our examples are a bit too contrived here. Basically the most significant difference between a symbol literal and a string literal is that you can't have spaces in a symbol literal. You also can't have spaces in Scala identifiers, like method names, variables names, class names, etc. That's really the main thing they...
Posted in ScalaTest/ScalaUtils Forum, Sep 7, 2008, 12:33 AM
Hi Jan,Sorry, I didn't get to this yet. But I'll try and figure it out on Sunday. What version of ScalaCheck are you using? The other possibility is a mismatch with ScalaCheck.Thanks.Bill
Posted in Programming in Scala Forum, Sep 3, 2008, 10:24 PM
Hi Leif,I think this is caused by the interpreter guessing wrongly where the end of your phrase is. If you put these things as is in a file and compile them, they will work. Or if you reformat them so the else is on the same line as the previous line, it should work in the interpreter too.Bill
Posted in ScalaTest/ScalaUtils Forum, Sep 3, 2008, 10:21 PM
Now that's what I call a stack trace! Quite impressive. I suspect the problem is caused by a mismatch in compiler versions. I'll recompile the current ScalaTest release under the latest release candidate Scala compiler, and release a new JAR.
Posted in Programming in Scala Forum, Sep 2, 2008, 3:22 AM
By the way, the best way to report errata is by clicking on the Suggest link at the bottom of the page.Thanks.
Posted in Programming in Scala Forum, Sep 2, 2008, 3:21 AM
Oops. Good catch. Too many stripDots is better than not enough, but I'd rather we just had one.Thanks.
Posted in Programming in Scala Forum, Sep 2, 2008, 3:19 AM
Hi Jan,Yes, sorry, I updated it to September 30.Bill
Posted in Programming in Scala Forum, Aug 30, 2008, 3:40 AM
> Hi> > Is there any way to buy the book/pdf without having a> credit card?>Please email me at bv AT artima.com.Thanks.Bill
Posted in ScalaTest/ScalaUtils Forum, Aug 30, 2008, 3:32 AM
> I just brought Programming in Scala on-line. Does anyone> know where can I download source code chapters in the> book?>Unfortunately, we don't have the zip file ready yet. Once the book goes to the printer, which will be very soon, we'll get the zip file out the door too.Bill
Posted in Programming in Scala Forum, Aug 24, 2008, 9:33 PM
Hi Alan,Here's how I'd avoid calculating widthOfLength twice: import scala.io.Sourcedef widthOfLength(s: String) = s.length.toString.lengthif (args.length > 0) { val lines = Source.fromFile(args(0)).getLines.toList val widths = lines.map(widthOfLength) val maxWidth = widths.reduceLeft((a, b) => a.max(b)) val zipped = lines zip widths for...
|