No, I see your point. And a slightly changed example. f=: 4 : 0 try. try. 3+y catch. *:x catchd. %:x end. catch. 'x and y are both bad' end. ) 13 f 'a' 169 13!:0[0 13 f 'a' 169 13!:0[1 13 f 'a' |domain error: f | 3 +y |f[:1]
On Sat, 10 Feb 2007, Brian Schott wrote: + Bill, + + I do not read any precedence into the catch.es . + Rather as I read it, if the catchd. does not apply + because 13!:0]1 then the error will not be caught and + therefore it will trigger a system error message rather than + performing the alternative action. + + + On Sat, 10 Feb 2007, bill lam wrote: + + + for the verb, + + + + f=: 4 : 0 + + try. + + try. 3+y catchd. *:x catch. %:x end. + + catch. + + 'x and y are both bad' + + end. + + ) + + + + 13 f 'a' + + 3.60555 + + 13!:0[1 + + 13 f 'a' + + |domain error: f + + | 3 +y + + |f[:1] + + + + If I read correctly, precedence is: catch > catchd > catcht, so that the catch + + clause alone will trap all error no matter if there are catchd or catcht or + + debug flag. Also, at most one catch/catchd/catcht clause will be invoked. Am I + + missing thing? + + + + -- + + regards, + + bill + + ---------------------------------------------------------------------- + + For information about J forums see http://www.jsoftware.com/forums.htm + + + + (B=) <----------my "sig" + + Brian Schott + Atlanta, GA, USA + schott DOT bee are eye eh en AT gee em ae eye el DOT com + http://schott.selfip.net/~brian/ + (B=) <----------my "sig" Brian Schott Atlanta, GA, USA schott DOT bee are eye eh en AT gee em ae eye el DOT com http://schott.selfip.net/~brian/ ---------------------------------------------------------------------- For information about J forums see http://www.jsoftware.com/forums.htm
