void setParameterNames(MethodSymbol sym, Type jvmType) {
        // if no names were found in the class file, there's nothing more to do
        if (!haveParameterNameIndices)
            return;

        int firstParam = ((sym.flags() & STATIC) == 0) ? 1 : 0;
        // the code in readMethod may have skipped the first parameter when
        // setting up the MethodType. If so, we make a corresponding allowance
        // here for the position of the first parameter.  Note that this
        // assumes the skipped parameter has a width of 1 -- i.e. it is not
        // a double width type (long or double.)
        if (sym.name == names.init && currentOwner.hasOuterInstance()) {
            // Sometimes anonymous classes don't have an outer
            // instance, however, there is no reliable way to tell so
            // we never strip this$n
            if (!currentOwner.name.isEmpty())
                firstParam += 1;
        }

        if (sym.type != jvmType) {
            // reading the method attributes has caused the symbol's type to
            // be changed. (i.e. the Signature attribute.)  This may happen if
            // there are hidden (synthetic) parameters in the descriptor, but
            // not in the Signature.  The position of these hidden parameters
            // is unspecified; for now, assume they are at the beginning, and
            // so skip over them. The primary case for this is two hidden
            // parameters passed into Enum constructors.
            int skip = Code.width(jvmType.getParameterTypes())
                    - Code.width(sym.type.getParameterTypes());
            firstParam += skip;
        }
        List<Name> paramNames = List.nil();
        int index = firstParam;
        for (Type t: sym.type.getParameterTypes()) {
            int nameIdx = (index < parameterNameIndices.length
                    ? parameterNameIndices[index] : 0);
            Name name = nameIdx == 0 ? names.empty : readName(nameIdx);
            paramNames = paramNames.prepend(name);
            index += Code.width(t);
        }
        sym.savedParameterNames = paramNames.reverse();
    }