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

Improve static analysis to catch dead code and other potential bugs

Details

    • Improvement
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • None
    • 9.0
    • general/build
    • New

    Description

      When working on PR https://github.com/apache/lucene/pull/25, we noticed that some dead code is not being caught during static analysis in gradle build, such as the start variable in the following code: https://github.com/apache/lucene/blob/a5996dbecd4a6b4147d961260711a2cb6aeab3d3/lucene/facet/src/java/org/apache/lucene/facet/FacetsConfig.java#L446-L456 

      We may need to look at if additional javac compiler flag, or configuration for error prone, should be added to catch such bug as well as other potential ones.

      Attachments

        1. LUCENE-9856.patch
          0.9 kB
          Robert Muir

        Issue Links

          Activity

            People

              Unassigned Unassigned
              zacharymorn Zach Chen
              Votes:
              0 Vote for this issue
              Watchers:
              5 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0h
                  0h
                  Logged:
                  Time Spent - 7h 20m
                  7h 20m