Closed Abscissa closed 10 years ago
Changing issue's title:
What's really needed here is a callback function, not an OutputRange. Anything taking an arbitrary OutputRange needs to be templated: So using an OutputRange for echoing won't work unless everything that echoes is in a template that's instantiated by the user, which would make a mess of Scriptlike's API.
Instead, the optional custom sink for echoing should be a callback. The user can always provide a custom callback that sinks into whatever OutputRange they want, should they so desire.
Setting scriptlikeTraceCommands to true will echo commands to stdout, but there should be a way to override using stdout and allow to user to provide an OutputRange sink instead.