Object obj = new Object();
// ...
if (obj != null) {
}
Do you really want someone working for you at Oracle who designs a language where you must use a binary operator to check whether a reference is null? Consider the obvious alternative:
Object obj = new Object();
//...
if (obj) {
}
Don't you agree that this is more Zen-like? Me, too. I'm so glad you're in charge now.
That is all.
Best wishes,
Jon
No comments:
Post a Comment