some cleanup.

db4
John Benediktsson 2012-07-17 08:53:40 -07:00
parent 2f7e8c0352
commit 4eeafea8be
2 changed files with 4 additions and 4 deletions

View File

@ -5,7 +5,7 @@ biassocs ascii namespaces arrays make assocs interval-maps sets ;
IN: simple-flat-file
: drop-comments ( seq -- newseq )
[ "#@" split first ] map harvest ;
[ "#@" split1 drop ] map harvest ;
: split-column ( line -- columns )
" \t" split harvest 2 short head 2 f pad-tail ;

View File

@ -20,10 +20,10 @@ M: readline-reader prompt.
>>prompt drop ;
: word-names ( -- strs )
all-words [ name>> ] map ;
all-words [ name>> ] map! ;
: vocab-names ( -- strs )
all-vocabs-recursive filter-vocabs [ name>> ] map ;
all-vocabs-recursive filter-vocabs [ name>> ] map! ;
: prefixed-words ( prefix -- words )
'[ _ head? ] word-names swap filter ;
@ -36,7 +36,7 @@ M: readline-reader prompt.
: get-completions ( prefix -- completions )
completions tget dup [ nip ] [
drop current-line " " split first
drop current-line " " split1 drop
"USING:" = [
prefixed-vocabs
] [