Differences From Artifact [c796a47a03]:
- File gc_core/py/lang_core/gc_engine.py — part of check-in [57b72370f1] at 2020-03-25 23:41:12 on branch trunk — [build][core][fr] include line id for actions, stricter syntax for rules (user: olr, size: 56416) [annotate] [blame] [check-ins using]
To Artifact [612611c197]:
- File gc_core/py/lang_core/gc_engine.py — part of check-in [2f5ece5979] at 2020-04-11 19:24:19 on branch trunk — [core] gc engine: fix multi-tagging (user: olr, size: 56490) [annotate] [blame] [check-ins using]
︙ | ︙ | |||
635 636 637 638 639 640 641 | for i in range(nTokenStart, nTokenEnd+1): if "aTags" in self.lToken[i]: self.lToken[i]["aTags"].update(sWhat.split("|")) else: self.lToken[i]["aTags"] = set(sWhat.split("|")) if bDebug: echo(" TAG: {} > [{}:{}]".format(sWhat, self.lToken[nTokenStart]["sValue"], self.lToken[nTokenEnd]["sValue"])) | > | | | | | | 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 | for i in range(nTokenStart, nTokenEnd+1): if "aTags" in self.lToken[i]: self.lToken[i]["aTags"].update(sWhat.split("|")) else: self.lToken[i]["aTags"] = set(sWhat.split("|")) if bDebug: echo(" TAG: {} > [{}:{}]".format(sWhat, self.lToken[nTokenStart]["sValue"], self.lToken[nTokenEnd]["sValue"])) for sTag in sWhat.split("|"): if sTag not in self.dTags: self.dTags[sTag] = [nTokenStart, nTokenEnd] else: self.dTags[sTag][0] = min(nTokenStart, self.dTags[sTag][0]) self.dTags[sTag][1] = max(nTokenEnd, self.dTags[sTag][1]) elif cActionType == "!": # immunity if bDebug: echo(" IMMUNITY: " + sLineId + " / " + sRuleId) nTokenStart = nTokenOffset + eAct[0] if eAct[0] > 0 else nLastToken + eAct[0] nTokenEnd = nTokenOffset + eAct[1] if eAct[1] > 0 else nLastToken + eAct[1] if nTokenEnd - nTokenStart == 0: |
︙ | ︙ |