Lines Matching refs:sn
1492 str_node_split_last_char(StrNode* sn, OnigEncoding enc) in str_node_split_last_char() argument
1497 if (sn->end > sn->s) { in str_node_split_last_char()
1498 p = onigenc_get_prev_char_head(enc, sn->s, sn->end); in str_node_split_last_char()
1499 if (p && p > sn->s) { /* can be split. */ in str_node_split_last_char()
1500 n = node_new_str(p, sn->end); in str_node_split_last_char()
1501 if ((sn->flag & NSTR_RAW) != 0) in str_node_split_last_char()
1504 sn->end = (UChar* )p; in str_node_split_last_char()
1511 str_node_can_be_split(StrNode* sn, OnigEncoding enc) in str_node_can_be_split() argument
1513 if (sn->end > sn->s) { in str_node_can_be_split()
1514 return ((enclen(enc, sn->s) < sn->end - sn->s) ? 1 : 0); in str_node_can_be_split()
1521 node_str_head_pad(StrNode* sn, int num, UChar val) in node_str_head_pad() argument
1526 len = sn->end - sn->s; in node_str_head_pad()
1527 onig_strcpy(buf, sn->s, sn->end); in node_str_head_pad()
1528 onig_strcpy(&(sn->s[num]), buf, buf + len); in node_str_head_pad()
1529 sn->end += num; in node_str_head_pad()
1532 sn->s[i] = val; in node_str_head_pad()
4796 StrNode* sn = NSTR(target); in set_quantifier() local
4797 if (str_node_can_be_split(sn, env->enc)) { in set_quantifier()
4798 Node* n = str_node_split_last_char(sn, env->enc); in set_quantifier()