pike.git/
src/
testsuite.in
Branch:
Tag:
Non-build tags
All tags
No tags
2004-09-20
2004-09-20 12:12:13 by Martin Stjernholm <mast@lysator.liu.se>
eba075793bb40be887ebc57f8db9b7f992d5a786 (
11
lines) (+
10
/-
1
)
[
Show
|
Annotate
]
Branch:
7.9
Test casting on a destructed object.
Rev: src/testsuite.in:1.738
1:
START_MARKER
-
test_true([["$Id: testsuite.in,v 1.
737
2004/
07
/
16
14
:
38
:
36
grubba
Exp $"]]);
+
test_true([["$Id: testsuite.in,v 1.
738
2004/
09
/
20
12
:
12
:
13
mast
Exp $"]]);
// This triggered a bug only if run sufficiently early. test_compile_any([[#pike 7.2]])
6984:
test_equal([[ ({}) ]], [[ (array)([]) ]]) test_eval_error([[ mapping m=(mapping)({ ({1,2,3}), ({4,5,6}) }); ]])
+
test_any([[
+
object x = class {
+
mixed cast (string t) {return t == "string" && "foo";}
+
}();
+
destruct (x);
+
return (string) x;
+
]], "0")
+
// testing @ test_equal(({1,2,3}),lambda(mixed ... x) { return x; }(@a())) test_equal("foo"/"",lambda(mixed ... x) { return x; }(@a()))