aokolnychyi commented on a change in pull request #226: Apply Baseline plugin 
to iceberg-spark
URL: https://github.com/apache/incubator-iceberg/pull/226#discussion_r296473115
 
 

 ##########
 File path: 
spark/src/main/java/org/apache/iceberg/spark/PruneColumnsWithReordering.java
 ##########
 @@ -72,7 +72,7 @@ public Type schema(Schema schema, Supplier<Type> 
structResult) {
   public Type struct(Types.StructType struct, Iterable<Type> fieldResults) {
     Preconditions.checkNotNull(struct, "Cannot prune null struct. Pruning must 
start with a schema.");
     Preconditions.checkArgument(current instanceof StructType, "Not a struct: 
%s", current);
-    StructType s = (StructType) current;
+    StructType requestedStruct = (StructType) current;
 
 Review comment:
   I was inspired by other existing places such as 
[this](https://github.com/apache/incubator-iceberg/blob/master/spark/src/main/java/org/apache/iceberg/spark/PruneColumnsWithReordering.java#L107).
 It was a bit unclear what `current` means until I saw that `current = 
requestedType` initially. Since this class is about pruning `requested` made 
sense to me.
   
   If we keep `requested` in the name, conditions are self-descriptive 
`requestedDecimal.scale() == decimal.scale()`. 

----------------------------------------------------------------
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.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to