nastra commented on code in PR #16881:
URL: https://github.com/apache/iceberg/pull/16881#discussion_r3457731906
##########
core/src/main/java/org/apache/iceberg/deletes/DeleteGranularity.java:
##########
@@ -48,14 +48,10 @@ public enum DeleteGranularity {
@Override
public String toString() {
- switch (this) {
- case FILE:
- return "file";
- case PARTITION:
- return "partition";
- default:
- throw new IllegalArgumentException("Unknown delete granularity: " +
this);
- }
+ return switch (this) {
+ case FILE -> "file";
+ case PARTITION -> "partition";
Review Comment:
we should probably keep the default branch here
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]