Path: news.daimi.aau.dk!news-feed.inet.tele.dk!news.algonet.se!hammer.uoregon.edu!arclight.uoregon.edu!su-news-hub1.bbnplanet.com!cam-news-hub1.bbnplanet.com!news.bbnplanet.com!uunet!in3.uu.net!192.174.65.41!01-newsfeed.univie.ac.at!CARNet.hr!jagor.srce.hr!kmajor From: kmajor@jagor.srce.hr (Kazimir Majorinc) Newsgroups: comp.lang.beta Subject: Ellipse - Circle dilemma in Beta? Date: 12 Feb 1997 20:57:11 GMT Organization: Public host at University Computing Centre, Zagreb, CROATIA Lines: 35 Distribution: world Message-ID: <5dtar7$bik@bagan.srce.hr> NNTP-Posting-Host: jagor.srce.hr Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Newsreader: TIN [version 1.2 PL2] Xref: news.daimi.aau.dk comp.lang.beta:10964 Hello! Do you have ELlipse Circle dilemma in Beta? Is someone do not know, that is problem in C++, described on this name in their comp.lang.c++ FAQ. Shortly: if you make class Circle childe of class Ellipse, than Ellipse::SetXYoses(a,b) will be inherited in Circle::SetXY(a,b) what appear nonsence. There are several answers on this question, and most constructive answers say you should not derive Circle from Ellipse. My opinion is slightly more pesimistic: it is disaster of C++ and many other OO languages. My question is of course, how Beta deal with it? My solution is that inheritance in classes should be upside down for (simple) modifiers, because there have very different semantic, although similar syntax. So, modifiers should be inherited from childe to parents. I have FAQ here, but it will be easier if someone know, is it possible with your patterns or so to make such hierarchy. Or, in any other language, if you know. Sincerely, _______________________________________________ Author: Kazimir Majorinc, Zagreb, Croatia E-mail: Kazimir.Majorinc@public.srce.hr kmajor@public.srce.hr (slightly better) http: //public.srce.hr/~kmajor (~7min to USA) ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ One who knows the secret of the 7th stair