// DO NO EDIT! - This file was generated by C:/Users/admin/dev/Jenkins/workspace/WebCore_master/Source/JavaScriptCore/Scripts/generateIntlCanonicalizeLanguage.py
// language-subtag-registry file date: 2018-04-23

#pragma once

#if ENABLE(INTL)

namespace JSC {

static String intlPreferredLanguageTag(const String& tag)
{
    // 78 possible replacements
    if (tag == "aam")
        return "aas"_s;
    if (tag == "adp")
        return "dz"_s;
    if (tag == "aue")
        return "ktz"_s;
    if (tag == "ayx")
        return "nun"_s;
    if (tag == "bgm")
        return "bcg"_s;
    if (tag == "bjd")
        return "drl"_s;
    if (tag == "ccq")
        return "rki"_s;
    if (tag == "cjr")
        return "mom"_s;
    if (tag == "cka")
        return "cmr"_s;
    if (tag == "cmk")
        return "xch"_s;
    if (tag == "coy")
        return "pij"_s;
    if (tag == "cqu")
        return "quh"_s;
    if (tag == "drh")
        return "khk"_s;
    if (tag == "drw")
        return "prs"_s;
    if (tag == "gav")
        return "dev"_s;
    if (tag == "gfx")
        return "vaj"_s;
    if (tag == "ggn")
        return "gvr"_s;
    if (tag == "gti")
        return "nyc"_s;
    if (tag == "guv")
        return "duz"_s;
    if (tag == "hrr")
        return "jal"_s;
    if (tag == "ibi")
        return "opa"_s;
    if (tag == "ilw")
        return "gal"_s;
    if (tag == "in")
        return "id"_s;
    if (tag == "iw")
        return "he"_s;
    if (tag == "jeg")
        return "oyb"_s;
    if (tag == "ji")
        return "yi"_s;
    if (tag == "jw")
        return "jv"_s;
    if (tag == "kgc")
        return "tdf"_s;
    if (tag == "kgh")
        return "kml"_s;
    if (tag == "koj")
        return "kwv"_s;
    if (tag == "krm")
        return "bmf"_s;
    if (tag == "ktr")
        return "dtp"_s;
    if (tag == "kvs")
        return "gdj"_s;
    if (tag == "kwq")
        return "yam"_s;
    if (tag == "kxe")
        return "tvd"_s;
    if (tag == "kzj")
        return "dtp"_s;
    if (tag == "kzt")
        return "dtp"_s;
    if (tag == "lii")
        return "raq"_s;
    if (tag == "lmm")
        return "rmx"_s;
    if (tag == "meg")
        return "cir"_s;
    if (tag == "mo")
        return "ro"_s;
    if (tag == "mst")
        return "mry"_s;
    if (tag == "mwj")
        return "vaj"_s;
    if (tag == "myt")
        return "mry"_s;
    if (tag == "nad")
        return "xny"_s;
    if (tag == "ncp")
        return "kdz"_s;
    if (tag == "nnx")
        return "ngv"_s;
    if (tag == "nts")
        return "pij"_s;
    if (tag == "oun")
        return "vaj"_s;
    if (tag == "pcr")
        return "adx"_s;
    if (tag == "pmc")
        return "huw"_s;
    if (tag == "pmu")
        return "phr"_s;
    if (tag == "ppa")
        return "bfy"_s;
    if (tag == "ppr")
        return "lcq"_s;
    if (tag == "pry")
        return "prt"_s;
    if (tag == "puz")
        return "pub"_s;
    if (tag == "sca")
        return "hle"_s;
    if (tag == "skk")
        return "oyb"_s;
    if (tag == "tdu")
        return "dtp"_s;
    if (tag == "thc")
        return "tpo"_s;
    if (tag == "thx")
        return "oyb"_s;
    if (tag == "tie")
        return "ras"_s;
    if (tag == "tkk")
        return "twm"_s;
    if (tag == "tlw")
        return "weo"_s;
    if (tag == "tmp")
        return "tyj"_s;
    if (tag == "tne")
        return "kak"_s;
    if (tag == "tnf")
        return "prs"_s;
    if (tag == "tsf")
        return "taj"_s;
    if (tag == "uok")
        return "ema"_s;
    if (tag == "xba")
        return "cax"_s;
    if (tag == "xia")
        return "acn"_s;
    if (tag == "xkh")
        return "waw"_s;
    if (tag == "xsj")
        return "suj"_s;
    if (tag == "ybd")
        return "rki"_s;
    if (tag == "yma")
        return "lrr"_s;
    if (tag == "ymt")
        return "mtm"_s;
    if (tag == "yos")
        return "zom"_s;
    if (tag == "yuu")
        return "yug"_s;
    return String();
}

static String intlPreferredExtlangTag(const String& tag)
{
    // 235 possible replacements
    if (tag == "aao")
        return "ar"_s;
    if (tag == "abh")
        return "ar"_s;
    if (tag == "abv")
        return "ar"_s;
    if (tag == "acm")
        return "ar"_s;
    if (tag == "acq")
        return "ar"_s;
    if (tag == "acw")
        return "ar"_s;
    if (tag == "acx")
        return "ar"_s;
    if (tag == "acy")
        return "ar"_s;
    if (tag == "adf")
        return "ar"_s;
    if (tag == "ads")
        return "sgn"_s;
    if (tag == "aeb")
        return "ar"_s;
    if (tag == "aec")
        return "ar"_s;
    if (tag == "aed")
        return "sgn"_s;
    if (tag == "aen")
        return "sgn"_s;
    if (tag == "afb")
        return "ar"_s;
    if (tag == "afg")
        return "sgn"_s;
    if (tag == "ajp")
        return "ar"_s;
    if (tag == "apc")
        return "ar"_s;
    if (tag == "apd")
        return "ar"_s;
    if (tag == "arb")
        return "ar"_s;
    if (tag == "arq")
        return "ar"_s;
    if (tag == "ars")
        return "ar"_s;
    if (tag == "ary")
        return "ar"_s;
    if (tag == "arz")
        return "ar"_s;
    if (tag == "ase")
        return "sgn"_s;
    if (tag == "asf")
        return "sgn"_s;
    if (tag == "asp")
        return "sgn"_s;
    if (tag == "asq")
        return "sgn"_s;
    if (tag == "asw")
        return "sgn"_s;
    if (tag == "auz")
        return "ar"_s;
    if (tag == "avl")
        return "ar"_s;
    if (tag == "ayh")
        return "ar"_s;
    if (tag == "ayl")
        return "ar"_s;
    if (tag == "ayn")
        return "ar"_s;
    if (tag == "ayp")
        return "ar"_s;
    if (tag == "bbz")
        return "ar"_s;
    if (tag == "bfi")
        return "sgn"_s;
    if (tag == "bfk")
        return "sgn"_s;
    if (tag == "bjn")
        return "ms"_s;
    if (tag == "bog")
        return "sgn"_s;
    if (tag == "bqn")
        return "sgn"_s;
    if (tag == "bqy")
        return "sgn"_s;
    if (tag == "btj")
        return "ms"_s;
    if (tag == "bve")
        return "ms"_s;
    if (tag == "bvl")
        return "sgn"_s;
    if (tag == "bvu")
        return "ms"_s;
    if (tag == "bzs")
        return "sgn"_s;
    if (tag == "cdo")
        return "zh"_s;
    if (tag == "cds")
        return "sgn"_s;
    if (tag == "cjy")
        return "zh"_s;
    if (tag == "cmn")
        return "zh"_s;
    if (tag == "coa")
        return "ms"_s;
    if (tag == "cpx")
        return "zh"_s;
    if (tag == "csc")
        return "sgn"_s;
    if (tag == "csd")
        return "sgn"_s;
    if (tag == "cse")
        return "sgn"_s;
    if (tag == "csf")
        return "sgn"_s;
    if (tag == "csg")
        return "sgn"_s;
    if (tag == "csl")
        return "sgn"_s;
    if (tag == "csn")
        return "sgn"_s;
    if (tag == "csq")
        return "sgn"_s;
    if (tag == "csr")
        return "sgn"_s;
    if (tag == "czh")
        return "zh"_s;
    if (tag == "czo")
        return "zh"_s;
    if (tag == "doq")
        return "sgn"_s;
    if (tag == "dse")
        return "sgn"_s;
    if (tag == "dsl")
        return "sgn"_s;
    if (tag == "dup")
        return "ms"_s;
    if (tag == "ecs")
        return "sgn"_s;
    if (tag == "esl")
        return "sgn"_s;
    if (tag == "esn")
        return "sgn"_s;
    if (tag == "eso")
        return "sgn"_s;
    if (tag == "eth")
        return "sgn"_s;
    if (tag == "fcs")
        return "sgn"_s;
    if (tag == "fse")
        return "sgn"_s;
    if (tag == "fsl")
        return "sgn"_s;
    if (tag == "fss")
        return "sgn"_s;
    if (tag == "gan")
        return "zh"_s;
    if (tag == "gds")
        return "sgn"_s;
    if (tag == "gom")
        return "kok"_s;
    if (tag == "gse")
        return "sgn"_s;
    if (tag == "gsg")
        return "sgn"_s;
    if (tag == "gsm")
        return "sgn"_s;
    if (tag == "gss")
        return "sgn"_s;
    if (tag == "gus")
        return "sgn"_s;
    if (tag == "hab")
        return "sgn"_s;
    if (tag == "haf")
        return "sgn"_s;
    if (tag == "hak")
        return "zh"_s;
    if (tag == "hds")
        return "sgn"_s;
    if (tag == "hji")
        return "ms"_s;
    if (tag == "hks")
        return "sgn"_s;
    if (tag == "hos")
        return "sgn"_s;
    if (tag == "hps")
        return "sgn"_s;
    if (tag == "hsh")
        return "sgn"_s;
    if (tag == "hsl")
        return "sgn"_s;
    if (tag == "hsn")
        return "zh"_s;
    if (tag == "icl")
        return "sgn"_s;
    if (tag == "iks")
        return "sgn"_s;
    if (tag == "ils")
        return "sgn"_s;
    if (tag == "inl")
        return "sgn"_s;
    if (tag == "ins")
        return "sgn"_s;
    if (tag == "ise")
        return "sgn"_s;
    if (tag == "isg")
        return "sgn"_s;
    if (tag == "isr")
        return "sgn"_s;
    if (tag == "jak")
        return "ms"_s;
    if (tag == "jax")
        return "ms"_s;
    if (tag == "jcs")
        return "sgn"_s;
    if (tag == "jhs")
        return "sgn"_s;
    if (tag == "jls")
        return "sgn"_s;
    if (tag == "jos")
        return "sgn"_s;
    if (tag == "jsl")
        return "sgn"_s;
    if (tag == "jus")
        return "sgn"_s;
    if (tag == "kgi")
        return "sgn"_s;
    if (tag == "knn")
        return "kok"_s;
    if (tag == "kvb")
        return "ms"_s;
    if (tag == "kvk")
        return "sgn"_s;
    if (tag == "kvr")
        return "ms"_s;
    if (tag == "kxd")
        return "ms"_s;
    if (tag == "lbs")
        return "sgn"_s;
    if (tag == "lce")
        return "ms"_s;
    if (tag == "lcf")
        return "ms"_s;
    if (tag == "liw")
        return "ms"_s;
    if (tag == "lls")
        return "sgn"_s;
    if (tag == "lsg")
        return "sgn"_s;
    if (tag == "lsl")
        return "sgn"_s;
    if (tag == "lso")
        return "sgn"_s;
    if (tag == "lsp")
        return "sgn"_s;
    if (tag == "lst")
        return "sgn"_s;
    if (tag == "lsy")
        return "sgn"_s;
    if (tag == "ltg")
        return "lv"_s;
    if (tag == "lvs")
        return "lv"_s;
    if (tag == "lws")
        return "sgn"_s;
    if (tag == "lzh")
        return "zh"_s;
    if (tag == "max")
        return "ms"_s;
    if (tag == "mdl")
        return "sgn"_s;
    if (tag == "meo")
        return "ms"_s;
    if (tag == "mfa")
        return "ms"_s;
    if (tag == "mfb")
        return "ms"_s;
    if (tag == "mfs")
        return "sgn"_s;
    if (tag == "min")
        return "ms"_s;
    if (tag == "mnp")
        return "zh"_s;
    if (tag == "mqg")
        return "ms"_s;
    if (tag == "mre")
        return "sgn"_s;
    if (tag == "msd")
        return "sgn"_s;
    if (tag == "msi")
        return "ms"_s;
    if (tag == "msr")
        return "sgn"_s;
    if (tag == "mui")
        return "ms"_s;
    if (tag == "mzc")
        return "sgn"_s;
    if (tag == "mzg")
        return "sgn"_s;
    if (tag == "mzy")
        return "sgn"_s;
    if (tag == "nan")
        return "zh"_s;
    if (tag == "nbs")
        return "sgn"_s;
    if (tag == "ncs")
        return "sgn"_s;
    if (tag == "nsi")
        return "sgn"_s;
    if (tag == "nsl")
        return "sgn"_s;
    if (tag == "nsp")
        return "sgn"_s;
    if (tag == "nsr")
        return "sgn"_s;
    if (tag == "nzs")
        return "sgn"_s;
    if (tag == "okl")
        return "sgn"_s;
    if (tag == "orn")
        return "ms"_s;
    if (tag == "ors")
        return "ms"_s;
    if (tag == "pel")
        return "ms"_s;
    if (tag == "pga")
        return "ar"_s;
    if (tag == "pgz")
        return "sgn"_s;
    if (tag == "pks")
        return "sgn"_s;
    if (tag == "prl")
        return "sgn"_s;
    if (tag == "prz")
        return "sgn"_s;
    if (tag == "psc")
        return "sgn"_s;
    if (tag == "psd")
        return "sgn"_s;
    if (tag == "pse")
        return "ms"_s;
    if (tag == "psg")
        return "sgn"_s;
    if (tag == "psl")
        return "sgn"_s;
    if (tag == "pso")
        return "sgn"_s;
    if (tag == "psp")
        return "sgn"_s;
    if (tag == "psr")
        return "sgn"_s;
    if (tag == "pys")
        return "sgn"_s;
    if (tag == "rms")
        return "sgn"_s;
    if (tag == "rsi")
        return "sgn"_s;
    if (tag == "rsl")
        return "sgn"_s;
    if (tag == "rsm")
        return "sgn"_s;
    if (tag == "sdl")
        return "sgn"_s;
    if (tag == "sfb")
        return "sgn"_s;
    if (tag == "sfs")
        return "sgn"_s;
    if (tag == "sgg")
        return "sgn"_s;
    if (tag == "sgx")
        return "sgn"_s;
    if (tag == "shu")
        return "ar"_s;
    if (tag == "slf")
        return "sgn"_s;
    if (tag == "sls")
        return "sgn"_s;
    if (tag == "sqk")
        return "sgn"_s;
    if (tag == "sqs")
        return "sgn"_s;
    if (tag == "ssh")
        return "ar"_s;
    if (tag == "ssp")
        return "sgn"_s;
    if (tag == "ssr")
        return "sgn"_s;
    if (tag == "svk")
        return "sgn"_s;
    if (tag == "swc")
        return "sw"_s;
    if (tag == "swh")
        return "sw"_s;
    if (tag == "swl")
        return "sgn"_s;
    if (tag == "syy")
        return "sgn"_s;
    if (tag == "szs")
        return "sgn"_s;
    if (tag == "tmw")
        return "ms"_s;
    if (tag == "tse")
        return "sgn"_s;
    if (tag == "tsm")
        return "sgn"_s;
    if (tag == "tsq")
        return "sgn"_s;
    if (tag == "tss")
        return "sgn"_s;
    if (tag == "tsy")
        return "sgn"_s;
    if (tag == "tza")
        return "sgn"_s;
    if (tag == "ugn")
        return "sgn"_s;
    if (tag == "ugy")
        return "sgn"_s;
    if (tag == "ukl")
        return "sgn"_s;
    if (tag == "uks")
        return "sgn"_s;
    if (tag == "urk")
        return "ms"_s;
    if (tag == "uzn")
        return "uz"_s;
    if (tag == "uzs")
        return "uz"_s;
    if (tag == "vgt")
        return "sgn"_s;
    if (tag == "vkk")
        return "ms"_s;
    if (tag == "vkt")
        return "ms"_s;
    if (tag == "vsi")
        return "sgn"_s;
    if (tag == "vsl")
        return "sgn"_s;
    if (tag == "vsv")
        return "sgn"_s;
    if (tag == "wbs")
        return "sgn"_s;
    if (tag == "wuu")
        return "zh"_s;
    if (tag == "xki")
        return "sgn"_s;
    if (tag == "xml")
        return "sgn"_s;
    if (tag == "xmm")
        return "ms"_s;
    if (tag == "xms")
        return "sgn"_s;
    if (tag == "yds")
        return "sgn"_s;
    if (tag == "ygs")
        return "sgn"_s;
    if (tag == "yhs")
        return "sgn"_s;
    if (tag == "ysl")
        return "sgn"_s;
    if (tag == "yue")
        return "zh"_s;
    if (tag == "zib")
        return "sgn"_s;
    if (tag == "zlm")
        return "ms"_s;
    if (tag == "zmi")
        return "ms"_s;
    if (tag == "zsl")
        return "sgn"_s;
    if (tag == "zsm")
        return "ms"_s;
    return String();
}

static String intlPreferredRegionTag(const String& tag)
{
    // 6 possible replacements
    if (tag == "BU")
        return "MM"_s;
    if (tag == "DD")
        return "DE"_s;
    if (tag == "FX")
        return "FR"_s;
    if (tag == "TP")
        return "TL"_s;
    if (tag == "YD")
        return "YE"_s;
    if (tag == "ZR")
        return "CD"_s;
    return String();
}

static String intlRedundantLanguageTag(const String& tag)
{
    // 24 possible replacements
    if (tag == "hy-arevela")
        return "hy"_s;
    if (tag == "hy-arevmda")
        return "hyw"_s;
    if (tag == "ja-Latn-hepburn-heploc")
        return "ja-Latn-alalc97"_s;
    if (tag == "sgn-BR")
        return "bzs"_s;
    if (tag == "sgn-CO")
        return "csn"_s;
    if (tag == "sgn-DE")
        return "gsg"_s;
    if (tag == "sgn-DK")
        return "dsl"_s;
    if (tag == "sgn-ES")
        return "ssp"_s;
    if (tag == "sgn-FR")
        return "fsl"_s;
    if (tag == "sgn-GB")
        return "bfi"_s;
    if (tag == "sgn-GR")
        return "gss"_s;
    if (tag == "sgn-IE")
        return "isg"_s;
    if (tag == "sgn-IT")
        return "ise"_s;
    if (tag == "sgn-JP")
        return "jsl"_s;
    if (tag == "sgn-MX")
        return "mfs"_s;
    if (tag == "sgn-NI")
        return "ncs"_s;
    if (tag == "sgn-NL")
        return "dse"_s;
    if (tag == "sgn-NO")
        return "nsl"_s;
    if (tag == "sgn-PT")
        return "psr"_s;
    if (tag == "sgn-SE")
        return "swl"_s;
    if (tag == "sgn-US")
        return "ase"_s;
    if (tag == "sgn-ZA")
        return "sfs"_s;
    if (tag == "zh-cmn-Hans")
        return "cmn-Hans"_s;
    if (tag == "zh-cmn-Hant")
        return "cmn-Hant"_s;
    return String();
}

static String intlGrandfatheredLanguageTag(const String& tag)
{
    // 26 possible replacements
    if (tag == "art-lojban")
        return "jbo"_s;
    if (tag == "cel-gaulish")
        return "cel-gaulish"_s;
    if (tag == "en-gb-oed")
        return "en-GB-oxendict"_s;
    if (tag == "i-ami")
        return "ami"_s;
    if (tag == "i-bnn")
        return "bnn"_s;
    if (tag == "i-default")
        return "i-default"_s;
    if (tag == "i-enochian")
        return "i-enochian"_s;
    if (tag == "i-hak")
        return "hak"_s;
    if (tag == "i-klingon")
        return "tlh"_s;
    if (tag == "i-lux")
        return "lb"_s;
    if (tag == "i-mingo")
        return "i-mingo"_s;
    if (tag == "i-navajo")
        return "nv"_s;
    if (tag == "i-pwn")
        return "pwn"_s;
    if (tag == "i-tao")
        return "tao"_s;
    if (tag == "i-tay")
        return "tay"_s;
    if (tag == "i-tsu")
        return "tsu"_s;
    if (tag == "no-bok")
        return "nb"_s;
    if (tag == "no-nyn")
        return "nn"_s;
    if (tag == "sgn-be-fr")
        return "sfb"_s;
    if (tag == "sgn-be-nl")
        return "vgt"_s;
    if (tag == "sgn-ch-de")
        return "sgg"_s;
    if (tag == "zh-guoyu")
        return "cmn"_s;
    if (tag == "zh-hakka")
        return "hak"_s;
    if (tag == "zh-min")
        return "zh-min"_s;
    if (tag == "zh-min-nan")
        return "nan"_s;
    if (tag == "zh-xiang")
        return "hsn"_s;
    return String();
}

} // namespace JSC

#endif // ENABLE(INTL)

