Path: utzoo!utgpu!watserv1!watmath!att!dptg!ulysses!andante!mit-eddie!snorkelwacker!usc!cs.utexas.edu!uunet!mcsun!ukc!pyrltd!tetrauk!rick From: rick@tetrauk.UUCP (Rick Jones) Newsgroups: comp.lang.eiffel Subject: Re: Should a constructor do "work"? Message-ID: <518@tetrauk.UUCP> Date: 16 Jul 90 09:31:07 GMT References: <55236@microsoft.UUCP> <519@tetrauk.UUCP> <364@eiffel.UUCP> Reply-To: rick@tetrauk.UUCP (Rick Jones) Organization: Tetra Ltd., Maidenhead, UK Lines: 21 In article <364@eiffel.UUCP> bertrand@eiffel.UUCP (Bertrand Meyer) writes: > > If invariants are checked and a creation operation raises >an exception, the target of the Create should remain void, >excluding any creation of an inconsistent object. > > This should definitely be part of the language specification. I agree, it SHOULD, but at the moment Eiffel doesn't do it that way! If a rescue clause traps an exception which results from a Create, the reference on which the Create was called is not Void. This is true for whatever reason the exception ocurred, including violating the Create's preconditions . Is this little inconsistency going to be corrected in future? -- Rick Jones You gotta stand for something Tetra Ltd. Maidenhead, Berks Or you'll fall for anything rick@tetrauk.uucp (...!ukc!tetrauk.uucp!rick) - John Cougar Mellencamp