code: int writeParameterAttrs(MethodSymbol m) {
          boolean hasVisible = false;
          boolean hasInvisible = false;
          if (m.params != null) {
              for (VarSymbol s : m.params) {
                  for (Attribute.Compound a : s.getRawAttributes()) {
                      switch (types.getRetention(a)) {
                      case SOURCE: break;
                      case CLASS: hasInvisible = true; break;
                      case RUNTIME: hasVisible = true; break;
                      default: ;// /* fail soft */ throw new AssertionError(vis);
                      }
                  }
              }
          }
  
          int attrCount = 0;
          if (hasVisible) {
              int attrIndex = writeAttr(names.RuntimeVisibleParameterAnnotations);
              databuf.appendByte(m.params.length());
              for (VarSymbol s : m.params) {
                  ListBuffer<Attribute.Compound> buf = new ListBuffer<Attribute.Compound>();
                  for (Attribute.Compound a : s.getRawAttributes())
                      if (types.getRetention(a) == RetentionPolicy.RUNTIME)
                          buf.append(a);
                  databuf.appendChar(buf.length());
                  for (Attribute.Compound a : buf)
                      writeCompoundAttribute(a);
              }
              endAttr(attrIndex);
              attrCount++;
          }
          if (hasInvisible) {
              int attrIndex = writeAttr(names.RuntimeInvisibleParameterAnnotations);
              databuf.appendByte(m.params.length());
              for (VarSymbol s : m.params) {
                  ListBuffer<Attribute.Compound> buf = new ListBuffer<Attribute.Compound>();
                  for (Attribute.Compound a : s.getRawAttributes())
                      if (types.getRetention(a) == RetentionPolicy.CLASS)
                          buf.append(a);
                  databuf.appendChar(buf.length());
                  for (Attribute.Compound a : buf)
                      writeCompoundAttribute(a);
              }
              endAttr(attrIndex);
              attrCount++;
          }
          return attrCount;
      }
docs: Write method parameter annotations;
  return number of attributes written.