Uploaded image for project: 'Lucene - Core'
  1. Lucene - Core
  2. LUCENE-8969

Fix abusive usage of assert in ArrayUtil

Details

    • Improvement
    • Status: Open
    • Minor
    • Resolution: Unresolved
    • None
    • None
    • None
    • None
    • New

    Description

      Methods in o.a.l.util.ArrayUtil uses assert statements for argument checks.
      It would be suitable to throw {{IllegalArgumentExceptions}}s instead of assertions here, to improve traceability when the violations occur? Sometimes I had difficulty in identifying the cause of assertion errors...

      Attachments

        Activity

          People

            Unassigned Unassigned
            tomoko Tomoko Uchida
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated: