Requests for j enhancement based on j64-602, discovered while
investigating project Euler problem 277.
0) Define inverses for linear polynomial evaluation.
0 p.^:_1(0)
|domain error
| 0 p.^:_1(0)
0 1 p.^:_1(8)
|domain error
| 0 1 p.^:_1(8)
1) Improve error messages.
Domain error does not isolate "@". The interpreter COULD identify
the problem.
%&3...@_1 2&p.
|domain error
| %&3...@_1 2&p.
jforc/parsing_and_execution_ii.htm#_Toc191734586
unprocessedWords stackTopFour restOfStack
$vcncncv
$vcncnc v
$vcncn cv
$vcnc ncv
$vcn cncv
$vc ncnc v
$v cncn cv
$ vcnc ncv
$vcn cncv conj rule 4, replace for "vcn" "v" $v cncv
$vcn cv conj rule 4, replace for "vcn" "v" $v cv
$vcv conj rule 4, replace for "vcv" "v" $v
$v
Result is a verb. Consider the data types.
$vcn cncv conj rule 4, replace for "vcn" "v" $v cncv
%&3 verb & noun works
$vcn cv conj rule 4, replace for "vcn" "v" $v cv
anonymousVerb @ noun
Domain error, v...@n is illegal.
Arguments to atop cause the problem.
Thanks,
Dave.
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm