Bear in mind that such generators will have poor performance (relative
to an iteration loop) because of Factor's naive implementation of
continuations. This may or may not be a problem, depending on what you
are doing with generators. For toy examples it will be OK but for
anything performance-sensitive I'd recommend writing your code in a
different style, until (or if :-)) continuations are sped up.

Slava

On Thu, Jul 16, 2009 at 9:54 PM, Chris Double<[email protected]> wrote:
> Yes, Factor has continuations and this can be used to build
> generators. See the extra/coroutines and extra/partial-continuations
> vocabs for example. For a description on how to use the latter:
>
> http://www.bluishcoder.co.nz/2006/03/partial-continuations-and-factor.html
> http://www.bluishcoder.co.nz/2006/03/factor-partial-continuation-updates.html
>
> Some of the code was inspired by Icon generator usage.
>
> Chris.
> --
> http://www.bluishcoder.co.nz
>
> ------------------------------------------------------------------------------
> Enter the BlackBerry Developer Challenge
> This is your chance to win up to $100,000 in prizes! For a limited time,
> vendors submitting new applications to BlackBerry App World(TM) will have
> the opportunity to enter the BlackBerry Developer Challenge. See full prize
> details at: http://p.sf.net/sfu/Challenge
> _______________________________________________
> Factor-talk mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/factor-talk
>

------------------------------------------------------------------------------
Enter the BlackBerry Developer Challenge  
This is your chance to win up to $100,000 in prizes! For a limited time, 
vendors submitting new applications to BlackBerry App World(TM) will have
the opportunity to enter the BlackBerry Developer Challenge. See full prize  
details at: http://p.sf.net/sfu/Challenge
_______________________________________________
Factor-talk mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/factor-talk

Reply via email to