2014-04-04 18:24:55 -07:00
|
|
|
var fiber = new Fiber {
|
2014-01-12 11:02:07 -08:00
|
|
|
IO.print("fiber")
|
2014-04-02 17:31:58 -07:00
|
|
|
}
|
2014-01-12 11:02:07 -08:00
|
|
|
|
|
|
|
|
// The first value passed to the fiber is ignored, since there's no yield call
|
|
|
|
|
// to return it.
|
2014-04-14 07:23:05 -07:00
|
|
|
IO.print("before") // expect: before
|
2014-01-12 11:02:07 -08:00
|
|
|
fiber.run("ignored") // expect: fiber
|
2014-04-14 07:23:05 -07:00
|
|
|
|
|
|
|
|
// This does not get run since we exit when the run fiber completes.
|
|
|
|
|
IO.print("nope")
|