Debian Codegraph @

src/test/04-Stress/func-call-9-spork-m.ck

raw
1 // #2024-func-call-update verification
2
3 0 => int N;
4
5 // test spork member function from within class definition
6 class Foo
7 {
8 fun void foo() { N++; spork ~ bar(); me.yield(); }
9 fun void bar() { if( N >= 10000 ) <<< "success" >>>; }
10 }
11
12 // test for stack overflow
13 repeat(10000) { Foo foo; foo.foo(); }