dlaboss commented on a change in pull request #8: cleanup warnings in 
plc4j-api, plc4j-core, dummy-driver
URL: https://github.com/apache/incubator-plc4x/pull/8#discussion_r171087658
 
 

 ##########
 File path: 
plc4j/api/src/main/java/org/apache/plc4x/java/api/messages/PlcWriteResponse.java
 ##########
 @@ -37,6 +37,7 @@ public PlcWriteResponse(PlcWriteRequest request, List<? 
extends WriteResponseIte
 
     @SuppressWarnings("unchecked")
     public <T> Optional<WriteResponseItem<T>> getValue(WriteRequestItem<T> 
item) {
-        return (Optional) super.getValue(item);
+        Optional<WriteResponseItem<?>> value = super.getValue(item); 
+        return (Optional<WriteResponseItem<T>>) ((Object) value); 
 
 Review comment:
   Fwiw, actually, directly casting to Optional<WriteResponseItem<T>> is an 
error.  First casting to Object eliminates it. Will add comment.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services

Reply via email to