mirror of https://github.com/svaarala/duktape.git
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
26 lines
401 B
26 lines
401 B
|
|
/*===
|
|
false
|
|
false
|
|
true
|
|
false
|
|
true
|
|
false
|
|
===*/
|
|
|
|
/* Testcase for a bug in comparing strings with embedded NULs.
|
|
* strncmp(), which stops comparing at NULs, was used.
|
|
*/
|
|
|
|
try {
|
|
print('foo\u0000f' < 'foo\u0000e');
|
|
print('foo\u0000f' < 'foo\u0000f');
|
|
print('foo\u0000f' < 'foo\u0000g');
|
|
|
|
print('' < '');
|
|
print('' < '\u0000');
|
|
print('\u0000' < '');
|
|
} catch (e) {
|
|
print(e);
|
|
}
|
|
|
|
|