Skip to content

indexer: load all xml files in memory to simplify and fix the checkers

jonathan poelen requested to merge jpoelen/syntax-highlighting:indexer into master

Now there are 2348 warnings...

$ ninja | rg '^"[^"]+" (?:line \d+ )?([^:]+ ).*' -r '$1' | sort | uniq -c
     89 column="0" or firstNonSpace="1" missing with RegExpr
     86 depends on a language "XXX" in version "YYY" . Please, increase kateversion.
      9 "firstNonSpace" must be 1 or true
      2 "includeAttrib" must be 1 or true
     51 "insensitive" must be 1 or true
      7 invalid context in "#popCharEnd"
      2 invalid context in "#popCharSyntaxError"
     16 invalid context in "#pop#CheckForString"
      1 invalid context in "#popMathModeMacro"
      1 invalid context in "#popMathModeText"
      1 invalid context in "#pop#pop#popString"
      5 is empty
   1524 keyword with delimiter
      6 "minimal" must be 1 or true
     26 RegExpr should be replaced by DetectSpaces / DetectChar
    520 RegExpr with a capture, but does not refer to any dynamic rules. Please, replace '(...)' with '(?:...)'
      2 unused context

There are some fixes to the existing verifiers (kateversion, context not used, hardening of the format for the context) and some improvements (mainly on RegExpr). I have mixed feelings about attributes with an unnecessary 0 value (firstNonSpace, minimal, etc), I would like some opinions :)

I have not looked at everything, there may be errors (especially for RegExpr).

Edited by Christoph Cullmann

Merge request reports

Loading