`Ident(::Ident)*`: a module name. */
| 537 | |
| 538 | /* `Ident(::Ident)*`: a module name. */ |
| 539 | static bool pl_is_module_name(const char *p) { |
| 540 | if (!(isalpha((unsigned char)p[0]) || p[0] == '_')) { |
| 541 | return false; |
| 542 | } |
| 543 | for (size_t i = 0; p[i]; i++) { |
| 544 | if (pl_word(p[i])) { |
| 545 | continue; |
| 546 | } |
| 547 | if (p[i] != ':' || p[i + SKIP_ONE] != ':' || !pl_word(p[i + PAIR_LEN])) { |
| 548 | return false; |
| 549 | } |
| 550 | i++; |
| 551 | } |
| 552 | return true; |
| 553 | } |
| 554 | |
| 555 | bool cbm_doclink_perl_parse_link(const char *raw, CBMPerlLink *out) { |
| 556 | if (!out) { |
no test coverage detected