[cfe-dev] Roadmap for a Concepts implementation P0734R0, currently merged into C++20 draft

Saar Raz via cfe-dev cfe-dev at lists.llvm.org
Thu Nov 23 02:35:03 PST 2017


Awesome! I'll check it out later today

On Thu, Nov 23, 2017, 7:54 AM Changyu Li <changyu at ca.ibm.com> wrote:

> Hi Saar,
>
> I submitted the work I did for review.
>
> https://reviews.llvm.org/D40380
> https://reviews.llvm.org/D40381
>
> I broke it into two parts. The removing old code part is pretty much the
> same as yours.
>
>
>
> ----- Original message -----
> From: Changyu Li/Markham/IBM
> To: hubert.reinterpretcast at gmail.com
> Cc: cfe-dev at lists.llvm.org, nwilson20 at gmail.com, richard at metafoo.co.uk,
> saar at raz.email
> Subject: Re: [cfe-dev] Roadmap for a Concepts implementation P0734R0,
> currently merged into C++20 draft
> Date: Thu, Nov 23, 2017 12:50 AM
>
>
> Hi Saar,
>
> I submitted the work I did for review.
> https://reviews.llvm.org/D40381https://reviews.llvm.org/D40381
>
>
> ----- Original message -----
> From: Hubert Tong <hubert.reinterpretcast at gmail.com>
> To: Saar Raz <saar at raz.email>
> Cc: Richard Smith <richard at metafoo.co.uk>, Clang Dev <
> cfe-dev at lists.llvm.org>, Nathan Wilson <nwilson20 at gmail.com>, Changyu Li <
> changyu at ca.ibm.com>
> Subject: Re: [cfe-dev] Roadmap for a Concepts implementation P0734R0,
> currently merged into C++20 draft
> Date: Tue, Nov 21, 2017 4:32 PM
>
>
> On Tue, Nov 21, 2017 at 3:53 PM, Saar Raz <saar at raz.email> wrote:
>
> Agreed, I'll post a patch with fixed tests and the diagnostic removed
> soon.
>
> Richard - I heard from Andrew Sutton that constrained non-template
> functions had been cut out of the working draft when concepts was voted in
> because of name mangling issues - are they still left out? If so, was the
> trailing requires-clause cut out as well?
> Anyway I've noticed another problem/defect with constrained non-template
> functions as described in P0734R0, discussed here:
> https://groups.google.com/a/isocpp.org/forum/#!topic/std-discussion/CJAmcnFI86o
> <https://urldefense.proofpoint.com/v2/url?u=https-3A__groups.google.com_a_isocpp.org_forum_-23-21topic_std-2Ddiscussion_CJAmcnFI86o&d=DwMFaQ&c=jf_iaSHvJObTbx-siA1ZOg&r=_TppqN2XZ2ySkHq7c46FM6kKcTPHv0u9VoUI4-BYNJg&m=1qLy4xI-SfbJo7vTFWt4Xsmyc86lguLScArE_9EIhx8&s=IB0SL0sySfBcN7XrCExUpmnerOvqjKsWiJiTTVPs5Q8&e=> (Andrew
> also agreed that this probably should be fixed in the way I suggested)
>
> Yes, previous discussions on the issue you describe led to the same
> conclusion. There are still questions over what exactly is used to
> distinguish requires-clauses that are "different" without template
> dependent constructs. The constraint expression really just evaluates to a
> bool value, and all cases evaluating to "true" could be considered
> equivalent. [basic.link]/9 in N4700 is silent to the point of being wrong
> here, but I do not think we have an agreement on what the right words
> should look like.
>
>
>
>
> On Mon, Nov 20, 2017 at 7:15 PM Hubert Tong <
> hubert.reinterpretcast at gmail.com> wrote:
>
> On Sun, Nov 19, 2017 at 7:39 PM, Saar Raz <saar at raz.email> wrote:
>
> Attached is a patch file that implements point 1 with some comments as to
> what should be done next.
>
> Saar, I believe cfe-commits is the mailing list for patch reviews. I also
> find Phabricator to be helpful (but it is not mandatory).
>
> Some comments:
> The patch would obviously break tests, so test updates are needed. I would
> prefer to see if some tests are salvageable by modifying them to use the
> new syntax (and then leaving them disabled for now).
> The error message at line 132 of the patch still refers to "concept" as a
> specifier.
> This particular error message is also more likely to be orphaned than not
> depending on how the parsing is implemented.
>
> template <typename T>
> inline concept C = true;
> //     ^
> // error: expected unqualified-id
>
> template <typename T>
> concept constexpr C = true;
> //      ^
> // error: expected unqualified-id
>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-dev/attachments/20171123/ca30cc79/attachment.html>


More information about the cfe-dev mailing list