Details

      Description

      Incorrect things that are allowed:

      • minus ("-") in variable names

      Correct things that are not allowed:

      • empty xml tag "<></>"
      • xml binding on the xml tag name "<{name}/>"
      • xml binding on an xml attribute "<test {name}='something'/>"
      • switch statement requires default case to be last but should be allowed at any position
      • use namespace directive should be allowed in any statement
      • imports and includes should be allowed in any block
      • imports/use namespace/includes are not required to have semicolons at the end (or any other statement)

      Fix is in this pull request: https://github.com/SonarCommunity/sonar-flex/pull/1

        Issue Links

          Activity

          Hide
          godin OLD - Evgeny Mandrikov added a comment -

          Hi Jeffrey,

          First of all thanks for your feedback, investigations and contribution - for sure we will do our best to integrate it into upcoming version.

          Regarding issue with minus in variable name - I created separate ticket SONARPLUGINS-2195 and added comment to it, which shows that fix not trivial as proposed. And that's why we prefer small separate patches. So I'm going to split your issue and pull-request on smaller pieces and verify each change by our integration tests.

          Show
          godin OLD - Evgeny Mandrikov added a comment - Hi Jeffrey, First of all thanks for your feedback, investigations and contribution - for sure we will do our best to integrate it into upcoming version. Regarding issue with minus in variable name - I created separate ticket SONARPLUGINS-2195 and added comment to it, which shows that fix not trivial as proposed. And that's why we prefer small separate patches. So I'm going to split your issue and pull-request on smaller pieces and verify each change by our integration tests.
          Hide
          jbarrus Jeffrey Barrus added a comment -

          Sorry for the large request. I'm happy to split it up into separate branches/pull requests if you would like.

          Show
          jbarrus Jeffrey Barrus added a comment - Sorry for the large request. I'm happy to split it up into separate branches/pull requests if you would like.
          Hide
          godin OLD - Evgeny Mandrikov added a comment - - edited

          Hi Jeffrey,

          I close this ticket, because everything except empty xml tag was fixed - see related tickets. And according to ECMAScript for XML (E4X) Specification (2nd edition, december 2005) XMLTagName can't be empty.

          P.S. In future please prefer creation of a small tickets (one per problem).

          Show
          godin OLD - Evgeny Mandrikov added a comment - - edited Hi Jeffrey, I close this ticket, because everything except empty xml tag was fixed - see related tickets. And according to ECMAScript for XML (E4X) Specification (2nd edition, december 2005) XMLTagName can't be empty. P.S. In future please prefer creation of a small tickets (one per problem).
          Hide
          freddy.mallet Freddy Mallet added a comment -

          Manually tested !

          Show
          freddy.mallet Freddy Mallet added a comment - Manually tested !

            People

            • Assignee:
              godin OLD - Evgeny Mandrikov
              Reporter:
              jbarrus Jeffrey Barrus
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: