Skip to content

Conversation

KevinTCoughlin
Copy link

Believe I'm removing some unnecessary unboxing calls, but please correct me if I'm wrong.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could you turn these into a < b ? -1 : ((a > b) ? 1 : 0) instead?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

To avoid misunderstanding, don't use Long.compare() because we need to be Java 6 compatible and that method is not available in it.

@akarnokd
Copy link
Member

See the comment, otherwise 👍.

@stevegury
Copy link
Member

+1 for @akarnokd comment, otherwise 👍

@akarnokd akarnokd added this to the 1.0.x milestone Sep 21, 2015
@KevinTCoughlin
Copy link
Author

@akarnokd @stevegury used ternaries in-place of Long.compareTo for Java 6 support. Thanks!

@stevegury
Copy link
Member

👍

1 similar comment
@akarnokd
Copy link
Member

👍

akarnokd added a commit that referenced this pull request Sep 22, 2015
@akarnokd akarnokd merged commit 6121baf into ReactiveX:1.x Sep 22, 2015
@KevinTCoughlin KevinTCoughlin deleted the remove-unnecessary-unboxing branch September 22, 2015 11:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants