C++ Logo

std-proposals

Advanced search

Re: [std-proposals] Paper on Interfaces (5 Pages)

From: Ville Voutilainen <ville.voutilainen_at_[hidden]>
Date: Fri, 24 Feb 2023 15:14:58 +0200
On Fri, 24 Feb 2023 at 13:16, Frederick Virchanza Gotham via
Std-Proposals <std-proposals_at_[hidden]> wrote:
>
> I've written Draft No. 2 today. Here are the changes I've made:
>
> 1) Replace ‘interface’ with ‘using new interface’ because it’s such a
> commonly used identifier.
> 2) Remove erroneous use of ‘public’ on Page 2 – you never use this
> keyword with an interface.
> 3) Add in shorthand for methods with the same signature.
> 4) Add in the use of the ‘delete’ keyword to deny access to a member.
>
> The PDF is attached to this email, and also you can download the
> latest draft from here:
>
> http://www.virjacode.com/download/interface_latest_draft.pdf

Okay then. The production of this paper is ignoring feedback,
especially including examples where the goal of this facility can just
be achieved with the existing language,
so we don't need any of this. Furthermore, in the proposal,

1) this isn't an interface, this is a downcast target, that's not what
'interface' means.
2) interface is a keyword-lookalike macro extension in some sizeable
C++ codebases in use today
3) there's nothing 'new' in what it does
4) it's not an alias, so 'using' is just wrong
5) delete clear; already has meaning elsewhere, and it's just
nonsensical to write a deleted declaration that way,
we already have a syntax for deleted declarations. If we want a
negation of a using-declaration, which would selectively
removes one declaration, that should be proposed as a language feature
of its own, but given that there's hardly
any convincing rationale, I don't think that's a good use of our time.

This paper should be burned, not sent to WG21 to spend time on.

Received on 2023-02-24 13:15:12