title: Import not found outside of class scope
body: <p>I'm running the Scala code below in a Zeppelin notebook, on an Azure HDInsight instance. </p>
  
  <pre><code>%livy2.spark
  
  import breeze.linalg.DenseVector
  var foo: DenseVector[Double] = DenseVector.zeros[Double](1)
  
  class ClassBar() {
      var baz: DenseVector[Double] = DenseVector.zeros[Double](1,1)
  }
  </code></pre>
  
  <p>The error I get is:</p>
  
  <pre><code>&lt;console&gt;:13: error: not found: type DenseVector
      var baz: DenseVector[Double] = DenseVector.zeros[Double](1,1)
                  ^
  &lt;console&gt;:13: error: not found: value DenseVector
      var baz: DenseVector[Double] = DenseVector.zeros[Double](1,1)
                                        ^
  </code></pre>
  
  <p>It works if I import DenseVector again inside the class definition but I don't understand why this is necessary? Shouldn't it find the DenseVector definition that is outside the class definition?</p>