title: Kotlin: how to pass array to Java annotation
body: <p>I want to use <code>@OneOf</code> annotation from <code>package io.dropwizard.validation;</code></p>
  
  <p>Java usage: </p>
  
  <pre><code>@OneOf(value = {"m", "f"})
  </code></pre>
  
  <p>Kotlin usage: ???</p>
  
  <p>I've tried this: </p>
  
  <pre><code> @OneOf(value = arrayOf("m", "f"))
  </code></pre>
  
  <p>and this:</p>
  
  <pre><code> @OneOf(value = ["m", "f"])
  </code></pre>
  
  <p>(EDIT: this example works since Kotlin 1.2, it supports array literal in annotation, thanks @BakaWaii)</p>
  
  <p>All i get is :</p>
  
  <blockquote>
    <p>Type inference failed. Expected type mismatch:</p>
    
    <p>required: String</p>
    
    <p>found: <code>Array&lt;String&gt;</code></p>
  </blockquote>
  
  <p>Kotlin version: 1.1.2-2</p>