Check if any import with the given module path exists. */
| 44 | |
| 45 | /* Check if any import with the given module path exists. */ |
| 46 | static int __attribute__((unused)) has_import(CBMFileResult *r, const char *path_substr) { |
| 47 | for (int i = 0; i < r->imports.count; i++) { |
| 48 | if (r->imports.items[i].module_path && |
| 49 | strstr(r->imports.items[i].module_path, path_substr) != NULL) |
| 50 | return 1; |
| 51 | } |
| 52 | return 0; |
| 53 | } |
| 54 | |
| 55 | /* Count definitions with a given label. */ |
| 56 | /* Check for a definition with the given qualified name. Distinct from |