Lines Matching refs:mp
276 Map_t* mp;
560 if (!(mp = newof(0, Map_t, 1, s - b + 1)))
565 b = (char*)(mp + 1);
566 mp->link.code = copy(&b, arg[0]);
572 if (!(mp->language = (Language_t*)lookup(&state.language, arg[1])))
577 if (!(mp->territory = (Territory_t*)lookup(&state.territory, arg[2])))
583 mp->charset = 0;
584 else if (!(mp->charset = (Charset_t*)lookup(&state.charset, arg[3])))
589 mp->attribute = 0;
592 for (al = mp->language->attributes; al; al = al->next)
595 mp->attribute = al->attribute;
598 if (!mp->attribute)
604 if (mp != (Map_t*)enter(&state.map, (Link_t*)mp))
606 fprintf(stderr, "%s: %d: %s: duplicate map\n", command, line, mp->link.code);
770 for (mp = (Map_t*)state.map.root; mp; mp = (Map_t*)mp->link.next)
772 fprintf(lf, "{\"%s\",", mp->link.code);
773 fprintf(lf, "&lc_languages[%d],", mp->language->link.index);
774 fprintf(lf, "&lc_territories[%d],", mp->territory->link.index);
775 fprintf(lf, "&lc_charsets[%d],", mp->charset ? mp->charset->link.index : 0);
776 if (mp->attribute)
777 fprintf(lf, "&attribute_%s[%d]", mp->language->link.code, mp->attribute->link.index);