pike.git/
src/
testsuite.in
Branch:
Tag:
Non-build tags
All tags
No tags
2014-12-04
2014-12-04 19:26:15 by Martin Nilsson <nilsson@opera.com>
4ec59a89226c7be4afd55ec57ef5ed8d7f330e1f (
41
lines) (+
16
/-
25
)
[
Show
|
Annotate
]
Branch:
bill/master_archive_support
Make incorrect escape sequences an error instead of a warning.
83:
test_true(1e1000<=1e10000) test_true(1e10000<=1e100000000000000000000000000000000000000000000000000000000000)
-
test_compile_
warning
('\3434523423423523423423423423')
-
test_compile_
warning
("\3434523423423523423423423423")
-
test_compile_
warning
("\d109827346981234561823743412654")
-
test_compile_
warning
("\x109a27bc69e256c83deaa34c26b4")
+
test_compile_
error
('\3434523423423523423423423423')
+
test_compile_
error
("\3434523423423523423423423423")
+
test_compile_
error
("\d109827346981234561823743412654")
+
test_compile_
error
("\x109a27bc69e256c83deaa34c26b4")
test_compile_error('\u17fo')
-
test_compile_
warning
("\u17fo")
-
test_
compile_error
('\uu117f')
+
test_compile_
error
("\u17fo")
+
test_
eq
('\uu117f'
, 0x5c7531313766
)
test_eq("\uuuu17fo", "\\uuu17fo") test_eq('\u117f', 0x117f) test_eq("\u117foo", "\10577oo") test_eq("\u1117foo", "\10427foo") test_eq("\uuuu117foo", "\\uuu117foo") test_compile_error('\U117f')
-
test_compile_
warning
("\U117f")
-
test_compile_
warning
("\UdEaDbEaT")
+
test_compile_
error
("\U117f")
+
test_compile_
error
("\UdEaDbEaT")
test_eq("\UUdEaDbEaT", "\\UdEaDbEaT") test_eq('\UDeaDBeEF', -559038737) test_eq("\UDeaDBeEFFF", "\33653337357FF") test_eq("\UUDeaDBeEFFF", "\\UDeaDBeEFFF")
-
test_
any([[
-
// Suppress warnings.
-
class handler {
-
void
compile_
warning
(
string file, int line, string err) {};
-
};
-
return compile_string(
"
string s = \
"
\\3434523423423523423423423423\";",
-
"-", handler(
)
)()->s;
-
]], "\37777777777")
-
test_
any([[
-
// Suppress warnings.
-
class handler {
-
void
compile_
warning
(
string file, int line, string err) {};
-
};
-
return compile_string("int i =
'
\\3434523423423523423423423423
'
;",
-
"-", handler(
)
)()->i;
-
]], -1)
+
test_compile_
error
("
\3434523423423523423423423423
")
+
test_compile_
error
('
\3434523423423523423423423423
')
test_do([[ // bug 2677
8004:
test_eq(16,"\020"[0]) test_eq(255,"\377"[0]) test_eq(4,'\4')
-
test_true("\r"[
0
]!='r')
+
test_
eq('a',0x61)
+
test_eq('ab',0x6162)
+
test_eq('abc',0x616263)
+
test_eq('abcd',0x61626364)
+
test_
true("\r"[
-1
]!='r')
test_eq("\r"[0],'\r') test_eq("\n"[0],'\n')