code: @Override
    protected void visitFieldAccessNode(FieldAccessNode node) {
      // simplify children first
      visitChildren(node);
      ExprNode baseExpr = node.getChild(0);
      if (baseExpr instanceof RecordLiteralNode) {
        RecordLiteralNode recordLiteral = (RecordLiteralNode) baseExpr;
        for (int i = 0; i < recordLiteral.numChildren(); i++) {
          if (recordLiteral.getKey(i).identifier().equals(node.getFieldName())) {
            node.getParent().replaceChild(node, recordLiteral.getChild(i));
            return;
          }
        }
        // replace with null?  this should have been a compiler error.
      } else if (baseExpr instanceof ProtoInitNode) {
        ProtoInitNode protoInit = (ProtoInitNode) baseExpr;
        int fieldIndex = -1;
        for (int i = 0; i < protoInit.getParamNames().size(); i++) {
          if (protoInit.getParamNames().get(i).identifier().equals(node.getFieldName())) {
            fieldIndex = i;
            break;
          }
        }
        if (fieldIndex != -1) {
          node.getParent().replaceChild(node, protoInit.getChild(fieldIndex));
        } else {
          // here we could replace with a default value or null, but for now, do nothing, rather than
          // implement proto default field semantics.
        }
      }
    }
docs: this code since it desugars into a record literal.