Scan the index of 'as' and build the map for all alias
(toks)
| 177 | |
| 178 | |
| 179 | def scan_alias(toks): |
| 180 | """Scan the index of 'as' and build the map for all alias""" |
| 181 | as_idxs = [idx for idx, tok in enumerate(toks) if tok == 'as'] |
| 182 | alias = {} |
| 183 | for idx in as_idxs: |
| 184 | alias[toks[idx + 1]] = toks[idx - 1] |
| 185 | return alias |
| 186 | |
| 187 | |
| 188 | def get_tables_with_alias(schema, toks): |
no outgoing calls
no test coverage detected