Function
do_exist
(file_name, lines, imported)
Source from the content-addressed store, hash-verified
| 8 | import itertools |
| 9 | |
| 10 | def do_exist(file_name, lines, imported): |
| 11 | if not any(not re.match(fr'using \w+::{imported};', line) and |
| 12 | re.search(fr'\b{imported}\b', line) for line in lines): |
| 13 | print(f'File "{file_name}" does not use "{imported}"') |
| 14 | return False |
| 15 | return True |
| 16 | |
| 17 | |
| 18 | def is_valid(file_name): |
Tested by
no test coverage detected
Used in the wild real call sites across dependent graphs
searching dependent graphs…