Grammalecte  Check-in [05090f91ec]

Overview
Comment:[core][js] small code cleaning
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | core | rg
Files: files | file ages | folders
SHA3-256: 05090f91ec572058ad1dcb837c5a390943700affc4ae6d120e8580de9bb5b9c2
User & Date: olr on 2018-09-12 09:49:08
Other Links: branch diff | manifest | tags
Context
2018-09-12
10:38
[core] rename parameter tags -> aTags check-in: 5a15898d11 user: olr tags: core, rg
09:49
[core][js] small code cleaning check-in: 05090f91ec user: olr tags: core, rg
09:46
[core][build][js] fix several issues, better debugging information, create RegExp at runtime instead of preprocessing them at build check-in: 50bef581ca user: olr tags: build, core, rg
Changes

Modified gc_core/js/lang_core/gc_engine.js from [fb072c0f7f] to [225ec72077].

1029
1030
1031
1032
1033
1034
1035
1036
1037
1038
1039
1040
1041
1042
1043
1044
1045
1046
1047
    let m = zPattern.gl_exec2(s, null);
    if (!m) {
        return false;
    }
    try {
        let sWord = m[1];
        let nPos = m.start[1] + nOffset;
        if (sNegPatternGroup1) {
            return morph(dTokenPos, [nPos, sWord], sPatternGroup1, sNegPatternGroup1);
        }
        return morph(dTokenPos, [nPos, sWord], sPatternGroup1, false);
    }
    catch (e) {
        console.error(e);
        return false;
    }
}









<
|
|
<
<







1029
1030
1031
1032
1033
1034
1035

1036
1037


1038
1039
1040
1041
1042
1043
1044
    let m = zPattern.gl_exec2(s, null);
    if (!m) {
        return false;
    }
    try {
        let sWord = m[1];
        let nPos = m.start[1] + nOffset;

        return morph(dTokenPos, [nPos, sWord], sPatternGroup1, sNegPatternGroup1);
    }


    catch (e) {
        console.error(e);
        return false;
    }
}