ctubbsii commented on code in PR #2559:
URL: https://github.com/apache/thrift/pull/2559#discussion_r847957761


##########
compiler/cpp/src/thrift/generate/t_java_generator.cc:
##########
@@ -468,6 +469,10 @@ string t_java_generator::java_nullable_annotation() {
   return "@org.apache.thrift.annotation.Nullable";
 }
 
+string t_java_generator::java_override_annotation() {
+  return "@java.lang.Override";

Review Comment:
   Everything in `java.lang` is imported by default. You don't need the 
fully-qualified class names for anything in there. But, I see it's done 
elsewhere (for String). I suppose it doesn't hurt.
   
   ```suggestion
     return "@Override";
   ```



##########
compiler/cpp/src/thrift/generate/t_java_generator.cc:
##########
@@ -2108,8 +2117,8 @@ void 
t_java_generator::generate_java_struct_compare_to(ostream& out, t_struct* t
  *
  * @param tstruct The struct definition
  */
-void t_java_generator::generate_java_struct_reader(ostream& out, t_struct* 
tstruct) {
-  (void)tstruct;
+void t_java_generator::generate_java_struct_reader(ostream& out, t_struct* 
/*tstruct*/) {

Review Comment:
   You commented out the variable name, but left the variable's type. I'm 
mostly a Java dev. Is that a C++ quirk that's allowed for unused variables?



##########
compiler/cpp/src/thrift/generate/t_java_generator.cc:
##########
@@ -1273,7 +1280,6 @@ void 
t_java_generator::generate_tuple_scheme_read_value(ostream& out, t_struct*
   indent_up();
   indent(out) << "switch (setField) {" << endl;
   indent_up();
-

Review Comment:
   I think you lost a line in your change. I'm not sure if clang-format would 
re-add it. It'd be good to re-run it after your changes, just to be sure this 
PR is still well-formatted.



-- 
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]

Reply via email to