Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8161639

javac, duplicate keys are added to maps binaryOperators and unaryOperators at Operators

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Not an Issue
    • Icon: P3 P3
    • 9
    • 9
    • tools
    • None

      At class Operators we have the following maps:

          /** Unary operators map. */
          private Map<Name, List<UnaryOperatorHelper>> unaryOperators = new HashMap<>(Tag.getNumberOfOperators());

          /** Binary operators map. */
          private Map<Name, List<BinaryOperatorHelper>> binaryOperators = new HashMap<>(Tag.getNumberOfOperators());

      for both the key is a name, there are several operator groups with the same name, as a result the last one to be added overrides all the preceding ones.

            vromero Vicente Arturo Romero Zaldivar
            vromero Vicente Arturo Romero Zaldivar
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: