title: Receiving NoClassDefFoundError when invoking generated serializer() method
body: <p>I’m getting a <code>NoClassDefFoundError</code> when trying to invoke the <code>Foo.serializer()</code> method on a <code>@Serializable</code> class.</p>
  
  <p>Here's my test case:</p>
  
  <pre class="lang-kotlin prettyprint-override"><code>@Serializable
  data class Foo(val data: String)
  
  val jsonString = json.stringify(
    Foo.serializer(), // &lt;= Error happens here
    Foo(data = "foo")
  )
  </code></pre>
  
  <p>Attempting to run the code results in the following stack trace:</p>
  
  <pre><code>java.lang.NoSuchMethodError: 'void kotlinx.serialization.internal.SerialClassDescImpl.&lt;init&gt;(java.lang.String, kotlinx.serialization.internal.GeneratedSerializer, int)'
      at com.example.Foo$$serializer.&lt;clinit&gt;(Foo.kt:7)
      at com.example.Foo$Companion.serializer(Foo.kt)
  </code></pre>