Correct analysis.
The test is to make sure you don't waste a lot of time on something that
turns out to be a dissect error; or to alert you to an error in special
code in the interpreter.
You can turn off the test:
(0 ;< 'check';'no') dissect '?10'
Henry Rich
On 1/9/2016 5:31 AM, Matthew Baulch wrote:
Looking at the source for dissect (addons/debug/dissect/dissect.ijs)
suggests a few things.
(1) dissect evaluates the input expression incrementally by following each
branch along the parse tree.
(2) it evaluates the expression a second time using the ". verb--reporting
an error if the two don't agree.
By design, '? y' will normally provide differing results for a fixed y.
Hence the error. Perhaps you could define a constant function (roll =: 5:
for instance) and substitute it for '?' when testing your expression.
N.B. Please consider local timber workers and print at least 10 copies of
this email.
On Sat, Jan 9, 2016 at 9:06 PM, William Szuch <[email protected]>
wrote:
I get the following error using dissect.
dissect '? 10'
dissect error: dissected sentence has incorrect result
whereas dissect'=10' is OK
Bill Szuch
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm