DESCRIPTION

Bug 515394 - Remove unnecessary null checks



Change-Id: I422cde5ed69551b46618599c05746d5a8f0bfd62
Signed-off-by: Nevaeh Wu Ellison xxx@xxx.xxx

COMMENTS

author: Nevaeh Wu Ellison
date: 2017-04-19 09:36:25.000000000

Uploaded patch set 3.

-------------------------------------
author: Zaid Mosley
date: 2017-04-19 09:39:04.000000000

Patch Set 3: Code-Review+2 Verified+1

Looks good to me, I wait a bit with the merge to give Andrey the time to give feedback.

-------------------------------------
author: Jayvion Booth
date: 2017-04-19 09:42:49.000000000

Patch Set 3: Code-Review-1

(2 comments)

See comments

Line:172, bundles/org.eclipse.ui.workLeon Ochoach/Eclipse UI/org/eclipse/ui/internal/dialogs/WorkingSetTypePage.java -> I don't have the code now but if the contract od sselection is to return null on getFirstElement() if sselection is empty, the code can be changed to simply return the first element, without the if.

Line:305, bundles/org.eclipse.ui.workLeon Ochoach/Eclipse UI/org/eclipse/ui/internal/dialogs/WorkingSetSelectionDialog.java -> I'm not sure what does the sselection but I doubt it will return null in that case, so you are changing behavior of the method, which previously returned null. Please check all invariants where this method return value was used and compared with null.

-------------------------------------
author: Brenden Conley
date: 2017-04-19 09:57:54.000000000

Patch Set 3:

Build Started https://hudson.eclipse.org/platform/job/eclipse.platform.ui-Gerrit/12499/

-------------------------------------
author: Nevaeh Wu Ellison
date: 2017-04-19 10:10:46.000000000

Patch Set 3:

(1 comment)

Line:305, bundles/org.eclipse.ui.workLeon Ochoach/Eclipse UI/org/eclipse/ui/internal/dialogs/WorkingSetSelectionDialog.java -> getStructuredSelection never returns null, see its Javadoc. So the null is redundant, it will never the null, hence this method can never null.

-------------------------------------
author: Brenden Conley
date: 2017-04-19 10:45:51.000000000

Patch Set 3: Verified+1

Build Successful 

https://hudson.eclipse.org/platform/job/eclipse.platform.ui-Gerrit/12499/ : SUCCESS

-------------------------------------
author: Gerrit Code Review
date: 2017-04-19 14:24:20.000000000

Change has been successfully merged into the git repository by Zaid Mosley

-------------------------------------
