LinqLover / SimulationStudio

A growing suite of applications and tools using code simulation in Squeak/Smalltalk

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Add support for coroutines

LinqLover opened this issue · comments

Example:

(Simulator evaluate: [Generator on: [:s | s nextPutAll: #(1 2 3)]]) next.

This currently raises a Computation has been terminated! from this stack:

image

The VM refuses to execute the simulation context. One approach would be to override swapSender: and continue the execution in the simulator when a simulation context is inserted. However, it might be hard to detect all possible context manipulations and execute not more than a reasonable part of the stack in the simulator.