 ! Copyright (C) 2021 Doug Coleman.
 ! See http://factorcode.org/license.txt for BSD license.
 USING: accessors arrays constructors growable kernel math
-sequences vectors ;
+multiline sequences vectors ;
 IN: cursors2
 
 TUPLE: cursor ;

    [ >input-cursor ] dip (find2) ; inline


: (each2) ( cursor quot: ( cursor obj -- ) -- )
    over cursor-at [
        [ swap call ] 3keep drop
        [ cursor-inc-input ] dip (each2)
    ] [
        3drop
    ] if ; inline recursive

TUPLE: sequence-output-cursor < cursor seq n ;
CONSTRUCTOR: <sequence-output-cursor> sequence-output-cursor ( seq n -- obj ) ;

TUPLE: mapping-cursor < cursor output input ;
CONSTRUCTOR: <mapping-cursor> mapping-cursor ( output input -- obj ) ;

TUPLE: alist-cusor < cursor alist n ;

