title: How to pass directly a lambda where an interface is expected
body: <p>In Lwjgl there is a function such as:</p>
  
  <pre><code>public static void glDebugMessageCallback(
  @Nullable @NativeType("GLDEBUGPROC") GLDebugMessageCallbackI callback, 
  @NativeType("void const *") long userParam) {
      nglDebugMessageCallback(memAddressSafe(callback), userParam);
  }
  </code></pre>
  
  <p>and in Kotlin I can call it directly in the following way:</p>
  
  <pre><code>glDebugMessageCallback({ _, _, _, _, _, message, _ -&gt; Unit }, NULL)
  </code></pre>
  
  <p>Now, I'd like to overwrite this call omitting the last parameter.</p>
  
  <p>But if I type:</p>
  
  <pre><code>fun glDebugMessageCallback(callback: GLDebugMessageCallbackI) {
  
  }
  </code></pre>
  
  <p>Then the same call without <code>NULL</code>:</p>
  
  <pre><code>glDebugMessageCallback({ _, _, _, _, _, message, _ -&gt; Unit })
  </code></pre>
  
  <p>will get a Type mismatch:</p>
  
  <pre><code>Required: GLDebugMessageCallbackI
  
  Found: (???, ???, ???, ???, ???, ???, ???) → Unit
  </code></pre>
  
  <p>Why and how can I solve it?</p>