Invalid utf?

angerangel edited this page Jan 4, 2013 · 1 revision
Clone this wiki locally

USAGE

   INVALID-UTF? data /utf num

DESCRIPTION

Checks UTF encoding; if correct, returns none else position of error.

INVALID-UTF? is a native value.

ARGUMENTS

  • data (binary!)

REFINEMENTS

  • /utf -- Check encodings other than UTF-8
    • num -- Bit size - positive for BE negative for LE (integer!)

#SOURCE

invalid-utf?: make native! [  [
    {Checks UTF encoding; if correct, returns none else position of error.}
    data [binary!]
    /utf "Check encodings other than UTF-8"
    num [integer!] "Bit size - positive for BE negative for LE"
] ]