// @(#)$Id: exercise.txt,v 1.2 1997/06/03 23:06:57 leavens Exp $ Larch/C++ provides a way to specify functions whose behavior falls into several cases. This is described under ``Case Analysis'' in the manual. Often this is useful when you wish to specify a function that can throw (C++ jargon for signal) an exception. See the section ``Exceptions'' in the manual. For this exercise you are to specify a C++ function multiply, which takes two int arguments, and returns their product. Suppose that we want multiply to throw an exception when its result cannot be represented (because it would be smaller than INT_MIN or larger than INT_MAX). That is, give a specification with the following C++ interface. (Use the type Overflow as the type of the exceptions thrown.) struct Overflow {int a; int b;}; int multiply(int i, int j) throw(Overflow);