(toks, cols)
| 122 | return new_toks |
| 123 | |
| 124 | def join_by_col(toks, cols): |
| 125 | new_toks = [] |
| 126 | _len = len(toks) |
| 127 | i = 0 |
| 128 | while i < _len-1: |
| 129 | merge = False |
| 130 | for j in range(10): |
| 131 | if ''.join(toks[i:i+j]) in cols: |
| 132 | new_toks.append(''.join(toks[i:i+j])) |
| 133 | i += j |
| 134 | merge = True |
| 135 | if not merge: |
| 136 | new_toks.append(toks[i]) |
| 137 | i += 1 |
| 138 | new_toks.append(toks[-1]) |
| 139 | return new_toks |
| 140 | |
| 141 | tokens_tmp = _extract_value(string) |
| 142 |
no test coverage detected