Skip to content

Elvis ?: [enhacement] #28

Open
Open
@pablogrisafi1975

Description

@pablogrisafi1975

Thanks again for your extraordinary work.
You said that adding new operator is difficult because of no extension points at that stage. What about the elvis ?: operator, better known as null coalescing operator ? you know, instead of

String firstName = user == null ? null : user.getFirstName()

i'd like to write

String firstName = user?:getFirstName()

I don't know if that counts as a new operator, since both chars already have a meaning

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions