def METHOD_NAME(self, data, tags, nds):
    if not "highway" in tags:
        return
    err = []
    for tag in tags:
        if tag[-5:] == ":both":
          tag_default = tag[0:-5] # special handling because :both_ways also exists
        else:
          tag_default = tag.replace(":both:", ":").replace(":left", "").replace(":right", "")
        if tag_default == tag:
            continue # tag does not contain :both/:left/:right
        allowedAlternativeValues = []
        if tag_default in tags:
            # Some tags allow left/right/both as values, e.g. sidewalk=both equals sidewalk:both=yes
            if self.simplifyValue(tags[tag]) == "no":
                allowedAlternativeValues = ["yes", "left", "right", "separate", "opposite"]
            else:
                allowedAlternativeValues = ["yes", "left", "right", "both"]
        else:
            tag_default = tag.replace(":left", ":both").replace(":right", ":both")
        if tag_default in tags:
            tt = self.simplifyValue(tags[tag])
            ttd = self.simplifyValue(tags[tag_default])
            if tag[0:5] == "name:" and tt in ttd:
                continue # 'name' probably equals "name:left" + "/" + name:right, handled by Name_Multiple
            if tt != ttd and not ttd in allowedAlternativeValues:
                err.append({"class": 33601, "subclass": 1 + stablehash64(tag), "text": T_("Conflicting values of \"{0}\" and \"{1}\"", tag_default, tag)})
    if err != []:
        return err