Return 1 if any extracted import has module_path containing path_substr. */
| 87 | |
| 88 | /* Return 1 if any extracted import has module_path containing path_substr. */ |
| 89 | static int imp_has(CBMFileResult *r, const char *path_substr) { |
| 90 | for (int i = 0; i < r->imports.count; i++) { |
| 91 | if (r->imports.items[i].module_path && |
| 92 | strstr(r->imports.items[i].module_path, path_substr) != NULL) |
| 93 | return 1; |
| 94 | } |
| 95 | return 0; |
| 96 | } |
| 97 | |
| 98 | /* Return 1 if any extracted import has local_name equal to local. */ |
| 99 | static int imp_local(CBMFileResult *r, const char *local) { |