Exceptions: Difference between revisions

Content deleted Content added
Underscore (talk | contribs)
→‎{{header|Perl}}: Reverted 56483 (yes, those are exceptions). Added lang tags.
Line 531: Line 531:


=={{header|J}}==
=={{header|J}}==

===Tacit===
Program<tt> u :: v </tt>executes <tt>u</tt> and provides its result as output unless an error occurs. In case of error, the result of <tt>v</tt> is provided instead.<br>
Program<tt> u :: v </tt>executes <tt>u</tt> and provides its result as output unless an error occurs. In case of error, the result of <tt>v</tt> is provided instead.<br>


===Explicit===
An exception in an explicit definition can be detected with <tt>try.</tt> and <tt>catcht.</tt> and can be thrown with <tt> throw. </tt> as seen below.
An exception in an explicit definition can be detected with <tt>try.</tt> and <tt>catcht.</tt> and can be thrown with <tt> throw. </tt> as seen below.