pike.git / lib / modules / Calendar.pmod / Language.pmod

version» Context lines:

pike.git/lib/modules/Calendar.pmod/Language.pmod:58:    return month_n2s[n];    }       string month_shortname_from_number(int n)    {    return month_n2ss[n];    }       int month_number_from_name(string name)    { -  int j=(month_s2n[lower_case(name)]); +  int j=(month_s2n[flat(name)]);    if (!j) error("no such month of year: %O\n",name);    return j;    }       string week_day_name_from_number(int n)    {    return week_day_n2s[n];    }       string week_day_shortname_from_number(int n)    {    return week_day_n2ss[n];    }       int week_day_number_from_name(string name)    { -  int j=(week_day_s2n[lower_case(name)]); +  int j=(week_day_s2n[flat(name)]);    if (!j) error("no such day of week: %O\n",name);    return j;    }       string week_name_from_number(int n)    {    return sprintf("w%d",n);    }       int week_number_from_name(string s)
pike.git/lib/modules/Calendar.pmod/Language.pmod:134:    return week_day_n2s[(n+5)%7+1];    }       string gregorian_week_day_shortname_from_number(int n)    {    return week_day_n2ss[(n+5)%7+1];    }       int gregorian_week_day_number_from_name(string name)    { -  int j=(week_day_s2n[lower_case(name)]); +  int j=(week_day_s2n[flat(name)]);    if (!j) error("no such day of week: %O\n",name);    return j%7+1;    }       string gregorian_year_name_from_number(int y)    {    if (y<1) return sprintf("%d BC",1-y);    return sprintf("%d AD",y);    }   
pike.git/lib/modules/Calendar.pmod/Language.pmod:163:    string discordian_month_shortname_from_number(int n)    {    return ({0,"Chs","Dsc","Cfn","Bcy","Afm"})[n];    }       int discordian_month_number_from_name(string name)    {    return (["chaos":1,"discord":2,"confusion":3,    "bureaucracy":4,"the aftermath":5,    "chs":1,"dsc":2,"cfn":3,"bcy":4,"afm":5]) -  [lower_case(name)]; +  [flat(name)];    }       string discordian_week_day_shortname_from_number(int n)    {    return ({0,"SM","BT","PD","PP","SO","ST"})[n];    }       string discordian_week_day_name_from_number(int n)    {    return ({0,"Sweetmorn","Boomtime","Pungenday","Prickle-Prickle",    "Setting Orange","St. Tib's day"})[n];    }       int discordian_week_day_number_from_name(string name)    {    return (["sweetmorn":1,"boomtime":2,"pungenday":3,"prickle-prickle":4,    "setting orange":5,"st. tib's day":6,    "prickleprickle":4,"setting":5,"orange":5,"tib":6,"tibs":6,    "sttib":6,"sttibs":6,"saint tib's day":6,    "sm":1,"bt":2,"pd":3,"pp":4,"so":5,"st":6]) -  [lower_case(name)]; +  [flat(name)];    }       string discordian_week_name_from_number(int n)    {    return "w"+n;    }       string discordian_year_name_from_number(int y)    {    return (string)y;
pike.git/lib/modules/Calendar.pmod/Language.pmod:221:    }       int coptic_month_number_from_name(string name)    {    return (["tout":1,"baba":2,"hator":3,"kiahk":4,"toba":5,    "amshir":6,"baramhat":7,"baramouda":8,"pakho":9,    "paona":10,"epep":11,"mesra":12,"nasie":13,    "tou":1,"bab":2,"hat":3,"kia":4,"tob":5,    "ams":6,"bar":7,"bar":8,"pak":9,    "pao":10,"epe":11,"mes":12,"nas":13]) -  [lower_case(name)]; +  [flat(name)];    }       string coptic_year_name_from_number(int y)    {    return (string)y;    }       int x;      // islamic defaults