pike.git / lib / modules / Calendar.pmod / tzdata / checktab.awk

version» Context lines:

pike.git/lib/modules/Calendar.pmod/tzdata/checktab.awk:119:    FS = " "   }      $1 ~ /^#/ { next }      {    tz = rules = ""    if ($1 == "Zone") {    tz = $2    ruleUsed[$4] = 1 -  if ($5 ~ /%/) rulePercentUsed[$4] = 1 +     } else if ($1 == "Link" && zone_table == "zone.tab") {    # Ignore Link commands if source and destination basenames    # are identical, e.g. Europe/Istanbul versus Asia/Istanbul.    src = $2    dst = $3    while ((i = index(src, "/"))) src = substr(src, i+1)    while ((i = index(dst, "/"))) dst = substr(dst, i+1)    if (src != dst) tz = $3    } else if ($1 == "Rule") {    ruleDefined[$2] = 1 -  if ($10 != "-") ruleLetters[$2] = 1 +     } else {    ruleUsed[$2] = 1 -  if ($3 ~ /%/) rulePercentUsed[$2] = 1 +     }    if (tz && tz ~ /\//) {    if (!tztab[tz]) {    printf "%s: no data for '%s'\n", zone_table, tz \    >>"/dev/stderr"    status = 1    }    zoneSeen[tz] = 1    }   }      END {    for (tz in ruleDefined) {    if (!ruleUsed[tz]) {    printf "%s: Rule never used\n", tz    status = 1    }    } -  for (tz in ruleLetters) { -  if (!rulePercentUsed[tz]) { -  printf "%s: Rule contains letters never used\n", tz -  status = 1 -  } -  } +     for (tz in tztab) {    if (!zoneSeen[tz]) {    printf "%s:%d: no Zone table for '%s'\n", \    zone_table, tz2NR[tz], tz >>"/dev/stderr"    status = 1    }    }    if (0 < want_warnings) {    for (cc in cc2name) {    if (!cc_used[cc]) {    printf "%s:%d: warning: " \    "no Zone entries for %s (%s)\n", \    iso_table, cc2NR[cc], cc, cc2name[cc]    }    }    }       exit status   }