title: toList on Range with suffix notation causes type mismatch
body: <p>I am just starting with Scala, and trying out some things on Range and List, I get something very strange with a very simple snippet. I use sublime to edit and execute these snippets:</p>
  
  <pre class="lang-scala prettyprint-override"><code>val a = 1 to 10
  println(a)
  </code></pre>
  
  <p>yields</p>
  
  <pre><code>Range(1, 2, 3, 4, 5, 6, 7, 8, 9, 10)
  </code></pre>
  
  <p>while </p>
  
  <pre><code>val a = 1 to 10
  val b = a toList
  println(a)
  </code></pre>
  
  <p>gives me the error:</p>
  
  <pre><code>/home/olivier/Dropbox/Projects/ProjectEuler/misc/scala/ch05_ex02.scala:5:     error: type mismatch;
   found   : Unit
   required: Int
  println(a)
         ^
  one error found
  </code></pre>
  
  <p>In the REPL, on the contrary, I do not get any error.  Scala version is 2.9.2</p>