RFR: 8079136: Accessing a nested sublist leads to StackOverflowError (original) (raw)
Martin Buchholz martinrb at google.com
Thu May 7 22:30:12 UTC 2015
- Previous message: RFR: 8079136: Accessing a nested sublist leads to StackOverflowError
- Next message: RFR: 8079136: Accessing a nested sublist leads to StackOverflowError
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
On Thu, May 7, 2015 at 3:07 PM, Martin Buchholz <martinrb at google.com> wrote:
if ((fromIndex < 0) | (toIndex > size) | (fromIndex > toIndex)) slowpath();
Yeah, the refined proposal would be
if ((fromIndex | (size - toIndex) | (toIndex - fromIndex)) < 0) slowpath();
considering that here performance is more important than the small loss of readability.
- Previous message: RFR: 8079136: Accessing a nested sublist leads to StackOverflowError
- Next message: RFR: 8079136: Accessing a nested sublist leads to StackOverflowError
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]