title: Create a new object extending a trait and using early definition syntax
body: <p>How to create an objectthat extends a trait and uses early definition syntax?</p>
  
  <p>Let's say we have two traits:</p>
  
  <pre><code>trait Trait {
    val value : String
  }
  
  trait Simple
  </code></pre>
  
  <p>Let's say we have also a simple class:</p>
  
  <pre><code>class Class
  </code></pre>
  
  <p>We can create a new object of type <code>Class</code> and make it extend a <code>Simple</code> trait:</p>
  
  <pre><code>new Class extends Simple
  </code></pre>
  
  <p>Is it possible to create a new object of type <code>Class</code> that extends the <code>Trait</code> and uses the early definition syntax to set <code>value</code> member? I tried something like:</p>
  
  <pre><code>     new Class  extends { override val value = "42" } with Trait
  </code></pre>
  
  <p>But this gives a syntax error:</p>
  
  <blockquote>
    <p>Error:(12, 17) ';' expected but 'extends' found.<br>
           new Class extends { val value = "42" } with  Trait</p>
  </blockquote>