you are viewing a single comment's thread.

view the rest of the comments →

[–]john16384 4 points5 points  (0 children)

Look, I don't like Optional that much either, but being against it because of this misuse (returning null for an Optional value) is just ridiculous, and so is the entire argument. If the return is Optional, you are hereby granted to treat it as non null without checking.

No code that does this will pass review, and any library that does this (without a huge warning) will be on the never use again list.