iosched icon indicating copy to clipboard operation
iosched copied to clipboard

Make sure type parameter of Event class is non-null

Open kafumi opened this issue 6 years ago • 0 comments

  • null can't be used as a valid content of Event because Event uses null to indicate the event has been already handled
  • It means the type parameter T of Event should never be nullable
  • Expressed that constrain by giving upper bound Any to T
    • Reference: https://speakerdeck.com/npryce/the-kotlin-type-hierarchy-from-top-to-bottom?slide=27

kafumi avatar Nov 16 '18 20:11 kafumi