klyn.CodeUnit.CodeUnit
constructor
public native CodeUnit(value as Char)
Description

Narrows a Basic Multilingual Plane Char to one UTF-16 code unit.

Parameters
ParameterDescription
valueChar to convert.
Throws
  • ValueException if value is supplementary and therefore needs two UTF-16 code units.
Example
assert CodeUnit('K') == `K`