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

Multi-line comments in build scripts need curly braces

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: P4
    • Resolution: Fixed
    • Affects Version/s: 8u20
    • Fix Version/s: 8u40
    • Component/s: javafx
    • Labels:

      Description

      While reviewing another fix, I noticed several places in build.gradle that use the following anti-pattern:

      if (A)
          B;

      This is not an acceptable coding style and can lead to bugs. The target statement(s) of multi-line conditional statements like this must be surrounded by curly braces or moved onto the same line as the conditional.

        Attachments

          Activity

            People

            Assignee:
            kcr Kevin Rushforth
            Reporter:
            kcr Kevin Rushforth
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved:
              Imported: