Uploaded image for project: 'SonarQube'
  1. SonarQube
  2. SONAR-7664

Fail on empty TextRange

    XMLWordPrintable

    Details

    • Type: Improvement
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 6.0
    • Component/s: Plugin API, Scanner
    • Labels:
      None

      Description

      In most API trying to create an empty range is a mistake. We should fail fast in this case. The only exception is when trying to create an issue on an empty line. That's why only InputFile::selectLine(int) should allow to return empty text range.

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              julien.henry Julien Henry
              Reporter:
              julien.henry Julien Henry
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

                Dates

                Due:
                Created:
                Updated:
                Resolved: