// KT-313 Bug in substitutions in a function returning its type parameter T fun Iterable.join(separator : String?) : String { return separator.npe() } fun T?.npe() : T { if (this == null) throw NullPointerException() return this; }