Path: utzoo!attcan!uunet!mcsun!hp4nl!phigate!prle!prles2!cstw56!roosen From: roosen@cstw56.prl.philips.nl (Monique Roosen) Newsgroups: comp.lang.eiffel Subject: Re: Eiffel on the NeXT? Message-ID: <1744@prles2.prl.philips.nl> Date: 15 Jun 90 13:18:35 GMT References: <76571@srcsip.UUCP> Sender: news@prles2.prl.philips.nl Reply-To: roosen@cst.prl.philips.nl (Monique Roosen) Organization: Centre for Software Technology, Philips Eindhoven Lines: 33 This is a follow-up to a previous message with respect to the extension of a STRING class. It can be placed in the same context. I want to make a class POS_REAL like : class POS_REAL inherit FLOAT -- maybe some extra features -- class invariant invariant Current >= 0.0 end -- class POS_REAL Of course I get the following error-message with respect to the invariant line : Type mismatch: REAL is not a descendant class of POS_REAL Incorrect type for argument number 1 of _infix_ge I suppose the following assignment won't work either : x : POS_REAL ; x := 1.2 The work-around for the STRING class was the share-feature, but this feature is not available within the FLOAT class. Is there anybody out there who knows a solution for this problem ?? Is ISE thinking of a change for these basic class types ?? Thanks in advance. Monique