Exclude cachedSize when printing fields.

Change-Id: I85563b74237d38c1e447b7286f5f6e62d57e3d63
pull/315/head
Brian Duff 10 years ago
parent d099a88685
commit 714dba3ab8
  1. 4
      javanano/src/main/java/com/google/protobuf/nano/MessageNanoPrinter.java

@ -109,6 +109,10 @@ public final class MessageNanoPrinter {
for (Field field : clazz.getFields()) {
int modifiers = field.getModifiers();
String fieldName = field.getName();
if ("cachedSize".equals(fieldName)) {
// TODO(bduff): perhaps cachedSize should have a more obscure name.
continue;
}
if ((modifiers & Modifier.PUBLIC) == Modifier.PUBLIC
&& (modifiers & Modifier.STATIC) != Modifier.STATIC

Loading…
Cancel
Save