Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.forth > #14539
| From | Bernd Paysan <bernd.paysan@gmx.de> |
|---|---|
| Newsgroups | comp.lang.forth |
| Subject | Re: RfD: Make ENVIRONMENT? obsolescent |
| Date | 2012-07-30 00:50 +0200 |
| Organization | 1&1 Internet AG |
| Message-ID | <jv4enm$sau$1@online.de> (permalink) |
| References | (16 earlier) <juv0ic$iji$1@online.de> <7xboj0x0g1.fsf@ruckus.brouhaha.com> <XOCdndlRuvP2eo7NnZ2dnUVZ8mCdnZ2d@supernews.com> <jv1rav$744$1@online.de> <501522d3$0$285$14726298@news.sunsite.dk> |
Doug Hoffman wrote: > I believe that using objects without the bureaucracy of declaring > interfaces and having to remember which part of which class hierarchy > I'm in to be a simpler and more useful approach. One should be able > to let the object system figure all of this stuff out. In BerndOOF, I declare an object pointer instance variable somewhat like widget ptr button combined ptr box display ptr dpy All these three instance variables know in which part of the class hierarchy the objects bound to them are in. The syntax for a duck type binding pointer would probably be ptr foo without mentioning any class. I don't see declaring interfaces as buerocratic. The interface is the visible part of a class, it is the part which needs documentation (stack effect is usually common for all implementations of the same method, and also the "what it is for" is documented in the interface). Often enough, the base class is abstract, i.e. it does not actually implement the methods it declares. In this case, it's not possible to do without declaration. However, I see your point, that there are cases where you simply like to have m: <selector> which both declares and implements a selector - it's shorter, and you don't have to scroll around in your file. > Do you have a simple example of multiple inheritance in BerndOOF? No, BerndOOF can't do the things I've just described. It can do single inheritance and implement arbitrary interfaces (an interface is something like a class without instance variables). Multiple inheritance is not very flexible, because you declare exactly which classes you want to merge. I don't find much use for this. I usually stick objects together by object pointers, i.e. has-a relationships, not is-a relationships. Example: Every MINOS widget has an actor, an object which handles input (key strokes, mouse clicks). There are a number of actors, and you can combine them quite liberal with widgets - not every actor makes sense for every widget, though. A meta object protocol should allow people to implement multiple inheritance, of course. -- Bernd Paysan "If you want it done right, you have to do it yourself" http://bernd-paysan.de/
Back to comp.lang.forth | Previous | Next — Previous in thread | Next in thread | Find similar
Re: RfD: Make ENVIRONMENT? obsolescent Doug Hoffman <glidedog@gmail.com> - 2012-07-20 11:15 -0400
Re: RfD: Make ENVIRONMENT? obsolescent Bernd Paysan <bernd.paysan@gmx.de> - 2012-07-20 20:18 +0200
Re: RfD: Make ENVIRONMENT? obsolescent Doug Hoffman <glidedog@gmail.com> - 2012-07-20 16:27 -0400
Re: RfD: Make ENVIRONMENT? obsolescent Bernd Paysan <bernd.paysan@gmx.de> - 2012-07-21 00:21 +0200
Re: RfD: Make ENVIRONMENT? obsolescent Doug Hoffman <glidedog@gmail.com> - 2012-07-20 19:49 -0400
Re: RfD: Make ENVIRONMENT? obsolescent Bernd Paysan <bernd.paysan@gmx.de> - 2012-07-21 15:42 +0200
Re: RfD: Make ENVIRONMENT? obsolescent Doug Hoffman <glidedog@gmail.com> - 2012-07-23 21:02 -0400
Re: RfD: Make ENVIRONMENT? obsolescent Doug Hoffman <glidedog@gmail.com> - 2012-07-23 21:31 -0400
Re: RfD: Make ENVIRONMENT? obsolescent mhx@iae.nl - 2012-07-21 01:18 -0700
Re: RfD: Make ENVIRONMENT? obsolescent Albert van der Horst <albert@spenarnc.xs4all.nl> - 2012-07-21 11:59 +0000
Re: RfD: Make ENVIRONMENT? obsolescent Bernd Paysan <bernd.paysan@gmx.de> - 2012-07-21 14:43 +0200
Re: RfD: Make ENVIRONMENT? obsolescent Albert van der Horst <albert@spenarnc.xs4all.nl> - 2012-07-21 19:36 +0000
Re: RfD: Make ENVIRONMENT? obsolescent Bernd Paysan <bernd.paysan@gmx.de> - 2012-07-21 21:41 +0200
Re: RfD: Make ENVIRONMENT? obsolescent Albert van der Horst <albert@spenarnc.xs4all.nl> - 2012-07-22 14:13 +0000
Re: RfD: Make ENVIRONMENT? obsolescent mhx@iae.nl (Marcel Hendrix) - 2012-07-22 09:11 +0200
Re: RfD: Make ENVIRONMENT? obsolescent anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2012-07-23 15:34 +0000
Re: RfD: Make ENVIRONMENT? obsolescent Bernd Paysan <bernd.paysan@gmx.de> - 2012-07-23 20:05 +0200
Re: RfD: Make ENVIRONMENT? obsolescent anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2012-07-25 12:52 +0000
Re: RfD: Make ENVIRONMENT? obsolescent Bernd Paysan <bernd.paysan@gmx.de> - 2012-07-25 23:21 +0200
Re: RfD: Make ENVIRONMENT? obsolescent anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2012-07-26 14:16 +0000
Re: RfD: Make ENVIRONMENT? obsolescent Bernd Paysan <bernd.paysan@gmx.de> - 2012-07-27 23:18 +0200
Re: RfD: Make ENVIRONMENT? obsolescent Paul Rubin <no.email@nospam.invalid> - 2012-07-27 16:13 -0700
Re: RfD: Make ENVIRONMENT? obsolescent Andrew Haley <andrew29@littlepinkcloud.invalid> - 2012-07-28 08:21 -0500
Re: RfD: Make ENVIRONMENT? obsolescent Bernd Paysan <bernd.paysan@gmx.de> - 2012-07-29 01:07 +0200
Re: RfD: Make ENVIRONMENT? obsolescent Doug Hoffman <glidedog@gmail.com> - 2012-07-29 07:47 -0400
Re: RfD: Make ENVIRONMENT? obsolescent Bernd Paysan <bernd.paysan@gmx.de> - 2012-07-30 00:50 +0200
Re: RfD: Make ENVIRONMENT? obsolescent Doug Hoffman <glidedog@gmail.com> - 2012-07-23 21:10 -0400
Re: RfD: Make ENVIRONMENT? obsolescent Bernd Paysan <bernd.paysan@gmx.de> - 2012-07-24 13:38 +0200
Re: RfD: Make ENVIRONMENT? obsolescent anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2012-07-25 13:58 +0000
Re: RfD: Make ENVIRONMENT? obsolescent Bernd Paysan <bernd.paysan@gmx.de> - 2012-07-25 23:22 +0200
objects (was: RfD: Make ENVIRONMENT? obsolescent) anton@mips.complang.tuwien.ac.at (Anton Ertl) - 2012-07-26 14:49 +0000
Re: RfD: Make ENVIRONMENT? obsolescent Doug Hoffman <glidedog@gmail.com> - 2012-07-26 04:30 -0400
Re: RfD: Make ENVIRONMENT? obsolescent Doug Hoffman <glidedog@gmail.com> - 2012-07-26 04:48 -0400
Re: RfD: Make ENVIRONMENT? obsolescent Bernd Paysan <bernd.paysan@gmx.de> - 2012-07-27 23:31 +0200
Re: RfD: Make ENVIRONMENT? obsolescent Doug Hoffman <glidedog@gmail.com> - 2012-07-30 04:40 -0400
Re: RfD: Make ENVIRONMENT? obsolescent Albert van der Horst <albert@spenarnc.xs4all.nl> - 2012-07-21 10:57 +0000
Re: RfD: Make ENVIRONMENT? obsolescent Doug Hoffman <glidedog@gmail.com> - 2012-07-23 21:20 -0400
csiph-web