Paste: a bug in help-lint tool

Author: dmsh
Mode: factor
Date: Sun, 27 Jun 2010 14:56:04
Plain Text |
( scratchpad ) USING: help.markup help.syntax ;
( scratchpad ) : foo ( x -- x ) drop 1 ;
( scratchpad ) HELP: foo { $values { "x" object } { "x" object } } { $description "bar baz" } ;
( scratchpad ) "scratchpad" help-lint
Checking scratchpad...
:lint-failures - show 1 help lint failures
( scratchpad ) :lint-failures

==== <Listener input>

<Listener input>

Asset: T{ link f foo }

$values don't match stack effect
:lint-failures - show 1 help lint failures
( scratchpad ) 

Annotation: looks like this would fix the problem

Author: dmsh
Mode: factor
Date: Sun, 27 Jun 2010 15:04:38
Plain Text |
( help.lint.checks ) \ effect-values see
USING: accessors arrays effects kernel sequences ;
IN: help.lint.checks
: effect-values ( word -- seq )
    stack-effect [ in>> ] [ out>> ] bi append
    [ dup pair? [ first ] when effect>string ] map ;
( help.lint.checks ) 

New Annotation

Summary:
Author:
Mode:
Body: