``` val attachments: Collection<Attachment?>...
# language-proposals
m
Copy code
val attachments: Collection<Attachment?> = ...

if (attachments.contains(null)) {
    return null
}
attachments as Collection<Attachment>
Looks like an (implicit) place for smart-cast… Isn’t it?