Uploaded image for project: 'FishEye'
  1. FishEye
  2. FE-3939

PHP syntax highlighting incorrectly matches keywords at the end of function names

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • Low
    • 2.7.11
    • None
    • None
    • None
    • Fisheye 2.7.10 standalone

    Description

      The PHP syntax highlighting was incorrectly matching keywords when they appeared at the end of a function name. For example, when displaying "trigger_error(…)", the "or" at the end of the function name was highlighted as a keyword.

      I've fixed this in our syntax highlighting by adding
      b to the beginning of the regexp as well as the end:

      /\b(abstract|and|array|as|break|case|catch|cfunction|class|clone|const|continue|declare|default|do|else|elseif|enddeclare|endfor|endforeach|endif|endswitch|endwhile|extends|final|for|foreach|function|global|goto|if|implements|interface|instanceof|namespace|new|old_function|or|private|protected|public|static|switch|throw|try|use|var|while|xor|_CLASS|DIR|FILE|FUNCTION|METHOD|NAMESPACE_|die|exit|eval|include|include_once|require|require_once|return)\b/

      Attachments

        Activity

          People

            bhumphreys BrendanA
            d88397a76b24 Chris Butler
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: