pike.git/
src/
testsuite.in
Branch:
Tag:
Non-build tags
All tags
No tags
1999-08-03
1999-08-03 21:31:05 by Fredrik Noring <noring@nocrew.org>
36e93dbc01668eb2899866152704a25cd0a6e1fe (
12
lines) (+
11
/-
1
)
[
Show
|
Annotate
]
Branch:
7.9
Test for a strange variable declaration bug.
Rev: src/testsuite.in:1.184
1:
-
stest_true([["$Id: testsuite.in,v 1.
183
1999/
07
/
30
23
:
43
:
06
mast
Exp $"]])
+
stest_true([["$Id: testsuite.in,v 1.
184
1999/
08
/
03
21
:
31
:
05
noring
Exp $"]])
cond([[all_constants()->_verify_internals]], [[ test_do(_verify_internals())
524:
test_eq([[lambda(int x) { return lambda() { return x; };}(17)()]],17) test_eq([[lambda(int x) { return lambda() { return lambda() { return x; };};}(17)()()]],17)
+
test_eq([[function f;
+
for(int i = 0; i < 2; i++)
+
{ {int _i = i; f = lambda(int j) { return _i+j; }; } }
+
return f(17);]],
+
[[function f;
+
for(int i = 0; i < 2; i++)
+
{ {int _i = i; f = lambda(int j) { return _i+j; }; } int FEL; }
+
return f(17);]]);
+
test_true([[lambda(function f) {return 1;}(object_program(this_object()));]]) test_eq([[class c { int `()(){ return 4711; } }()(); ]],4711) teste_eval_error(mixed foo=({}); sort(@foo); )