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

Make GrowableArray capacity management work without default constructor

    XMLWordPrintable

Details

    • Enhancement
    • Resolution: Unresolved
    • P4
    • tbd
    • 21
    • hotspot

    Description

      GrowableArray assumes that all data has a default ctr, see line 491:

        for ( ; i < this->_capacity; i++) ::new ((void*)&newData[i]) E();

      This is an unnecessary limitation which you hit when you try to limit your data structure to valid states.

      Attachments

        Activity

          People

            Unassigned Unassigned
            jsjolen Johan Sjölen
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated: