diff options
Diffstat (limited to 'core/src/test/resources/com/google/googlejavaformat/java/testdata/SwitchGuardClause.input')
-rw-r--r-- | core/src/test/resources/com/google/googlejavaformat/java/testdata/SwitchGuardClause.input | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/core/src/test/resources/com/google/googlejavaformat/java/testdata/SwitchGuardClause.input b/core/src/test/resources/com/google/googlejavaformat/java/testdata/SwitchGuardClause.input new file mode 100644 index 0000000..25df580 --- /dev/null +++ b/core/src/test/resources/com/google/googlejavaformat/java/testdata/SwitchGuardClause.input @@ -0,0 +1,9 @@ +class SwitchGuardClause { + boolean test(Object x) { + return switch (x) { + case String s when s.length() < 5 -> true; + case Integer i -> false; + default -> true; + }; + } +} |