Re: Reprise: 'in out' parameters for functions

From: Randy Brukardt (randy_at_rrsoftware.com)
Date: 04/13/04


Date: Mon, 12 Apr 2004 17:02:23 -0500


"Dmitry A. Kazakov" <mailbox@dmitry-kazakov.de> wrote in message
news:c5b6pt$2pcs4d$2@ID-77047.news.uni-berlin.de...
...
> Provided that:
>
> 1) protected object and tasks would be tagged (inheritable from);
> 2) multiple inheritance would be supported;
> 3) entries, procedures and functions would be primitive operations;
> 4) functional notation would be permitted (instead of prefix notation)

See AI-345, which extends the interface mechanism (itself a Ada 200y
proposal) to cover task and protected types. (1) is true if the PT or TT
inherits from one or more interfaces; (2) follows from the definition of
interfaces; (3) is true for calls through interfaces (as opposed to directly
to the PO or TOs); (4) is true for calls through interfaces.

> one could have entries of multiple protected objects and tasks.

I don't see how this follows from (1) to (4), though. Each call is just a
dispatching call to a single operation; there is no implementation
inheritance.

> A call to such entry would start multiple protected actions (one per each
protected
> object parameter) and multiple rendezvous (one per each task object
> parameter). Could we agree that 1-4 is a damn *lot* of work?

Not really. *Interfaces* is a lot of work, but presuming that we're going to
have those anyway, adding protected and task support to them is not a
significant increment.

                 Randy.



Relevant Pages

  • Re: The Language I want
    ... inheritance of interfaces from concrete types. ... packages may import, ... multiple inheritance ...
    (comp.lang.misc)
  • Re: PInvokes with managed and unmanaged objects
    ... same inheritance as in C++ file, you get the priviledge of flattening the ... > to represented in C# for PInvoke marshalling?If not any way around it? ... > Because C# does not allow multiple inheritance, ... it is to use interfaces. ...
    (microsoft.public.dotnet.framework.interop)
  • Re: Extension methods almost allow multiple inheritance via mixins (but not quite)
    ... What you really want is true multiple inheritance ... not interfaces extended with fields. ... Anything you can do with extension methods you can do with static methods, ...
    (microsoft.public.dotnet.languages.csharp)
  • Re: High performance alternative to MI of virtual bases
    ... > modeling IS-A relationships is incorrect. ... candidates for interfaces, in either the pure ABC or HFront sense. ... inheritance hierarchy, at least conceptually. ... "People quite correctly say that you don't need multiple inheritance, ...
    (comp.lang.cpp)
  • Re: Supporting both access and sql
    ... >> with interfaces and polymorhphism in c++ before but I didn't make the ... What I showed applies to VB6. ... > doesn't support implementation inheritance only interface inheritance. ... It does support both Interfaces ...
    (microsoft.public.vb.database)