1
0
forked from Mirror/wren

More tests for invalid code points.

This commit is contained in:
Bob Nystrom
2015-06-27 08:11:58 -07:00
parent 7baef81a4e
commit bf730bb953
2 changed files with 7 additions and 3 deletions

View File

@ -1,3 +1,8 @@
// The first byte of a two-octet sequence.
IO.print("\xc0".codePointAt(0)) // expect: -1
// The first byte of a three-octet sequence.
IO.print("\xe0".codePointAt(0)) // expect: -1
// The first two bytes of a three-octet sequence.
var s = "\xe0\xae"
IO.print(s.codePointAt(0)) // expect: -1
IO.print("\xe0\xae".codePointAt(0)) // expect: -1