-
Notifications
You must be signed in to change notification settings - Fork 744
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix an NPE in MultipleUnaryOperatorsInMethodCall
Discovered while validating 2.4.0 release (#1639) ------------- Created by MOE: https://github.com/google/moe MOE_MIGRATED_REVID=313711584
- Loading branch information
Showing
2 changed files
with
9 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -17,14 +17,15 @@ | |
|
||
/** @author [email protected] (Marsela Sulku) */ | ||
public class MultipleUnaryOperatorsInMethodCallNegativeCases { | ||
public static void tests(int a, int b) { | ||
public static void tests(int a, int b, int[] xs) { | ||
testMethod(a, b); | ||
testMethod(a + 1, b); | ||
testMethod(b, a + 1); | ||
testMethod(a++, b); | ||
testMethod(--a, b); | ||
testMethod(a, b--); | ||
testMethod(a, ++b); | ||
testMethod(xs[0]++, xs[0]++); | ||
} | ||
|
||
public static void testMethod(int one, int two) {} | ||
|