Skip to content

Instantly share code, notes, and snippets.

@ronaldxs
Created August 18, 2012 16:47
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ronaldxs/3388310 to your computer and use it in GitHub Desktop.
Save ronaldxs/3388310 to your computer and use it in GitHub Desktop.
string to ByteBuffer example
.sub go :main
.local pmc b
.local int n
b = new ['ByteBuffer']
b = utf8:"\x{a2}"
n = elements b
say n
n = b[0]
say n
n = b[1]
say n
.end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment