Function: puny-decode-string

puny-decode-string is a byte-compiled function defined in puny.el.gz.

Signature

(puny-decode-string STRING)

Documentation

Decode an IDNA/punycode-encoded string.

For instance "xn--bcher-kva" => "bücher".

Source Code

;; Defined in /usr/src/emacs/lisp/net/puny.el.gz
(defun puny-decode-string (string)
  "Decode an IDNA/punycode-encoded string.
For instance \"xn--bcher-kva\" => \"bücher\"."
  (if (string-match "\\`xn--" string)
      (condition-case nil
          (puny-decode-string-internal (substring string 4))
        ;; If the string is invalid Punycode, just return the string.
        (args-out-of-range string))
    string))