UNPKG

tree-sitter-cg

Version:
103 lines (91 loc) 2.39 kB
================= pathological qtag ================= SET MARK = COMMA | ("\") | ("\;") ; #" --- (source_file (set (SET) name: (setname) (eq) value: (inlineset (inlineset_single (setname)) (set_op) (inlineset_single (taglist (tag (qtag))))) (semicolon)) (comment)) ============= WITH grouping ============= WITH NOPARENT (n) IF (-1* (det)) { SETCHILD REPEAT (*) TO (-1* (adj) LINK -1* _C1_) ; SETCHILD (*) TO (jC1 (*)) ; } ; --- (source_file (rule_with type: (ruletype_with) flag: (ruleflag (ruleflag_name)) trg: (rule_target target: (inlineset (inlineset_single (taglist (tag (ntag)))))) (IF) context: (contexttest pos: (contextpos (ctx_negative) (ctx_number) (ctx_scan_first)) set: (inlineset (inlineset_single (taglist (tag (ntag)))))) children: (rule_parentchild type: (ruletype_parentchild) flag: (ruleflag (ruleflag_name)) trg: (rule_target target: (inlineset (inlineset_single (taglist (tag (ntag)))))) (TO) to_from: (contexttest pos: (contextpos (ctx_negative) (ctx_number) (ctx_scan_first)) set: (inlineset (inlineset_single (taglist (tag (ntag))))) (LINK) link: (contexttest pos: (contextpos (ctx_negative) (ctx_number) (ctx_scan_first)) set: (inlineset (inlineset_single (setname))))) (semicolon)) children: (rule_parentchild type: (ruletype_parentchild) trg: (rule_target target: (inlineset (inlineset_single (taglist (tag (ntag)))))) (TO) to_from: (contexttest pos: (contextpos (ctx_jump_context)) set: (inlineset (inlineset_single (taglist (tag (ntag)))))) (semicolon)) (semicolon))) ========== regex ntag ========== LIST FinCL = /((S|V|O2?|PP?|ADV)-)+(S|V|O2?|PP?|ADV)/r ; LIST FinCLPP = /((S|V|O2?|PP?|ADV)-)+PP/r ; LIST EllpCL = /^((S|O2?|PP|ADV)-)+(S|O2?|PP|ADV)$/r ; LIST VerbCL = /^V-|-V-|-V$/r ; --- (source_file (list (LIST) name: (setname) (eq) value: (taglist (tag (ntag))) (semicolon)) (list (LIST) name: (setname) (eq) value: (taglist (tag (ntag))) (semicolon)) (list (LIST) name: (setname) (eq) value: (taglist (tag (ntag))) (semicolon)) (list (LIST) name: (setname) (eq) value: (taglist (tag (ntag))) (semicolon)))