Run-Time Concepts

148 views
Skip to first unread message

Bryce Glover

unread,
Feb 22, 2016, 6:47:07 PM2/22/16
to conc...@isocpp.org, refle...@isocpp.org, sg...@isocpp.org
     I know that SG8 is hard at work on the current Concepts TS, but are there any long-term plans for it to look into whether or not it might be advantageous and/or feasible to find some intuitive way to improve C++’s support for run-time concepts?  Right now, one can, as I understand it, implement them in terms of type erasure, but wouldn’t it be rather neat if a C++ programmer could explicitly specify that such a type-erasing wrapper template `struct` or class is a run-time concept in the language itself?  On the other hand, might any of the pre-existing and/or current work on concepts already address this concern?  Either way, I think such functionality might be at least somewhat useful for SG7 and, consequently, also for SG14, both of which I have CCed this message to.  

— Bryce Glover

Bryce Glover

unread,
Feb 23, 2016, 3:17:43 PM2/23/16
to sg...@isocpp.org, conc...@isocpp.org, refle...@isocpp.org
Andrew Sutton <andrew....@gmail.com>: Feb 22 08:00PM -0500

Zach Laine and I have done a fair amount of thinking on this topic, but I haven’t been able to contribute anything to that work in quite a while. I'm not sure what the status is any more.

Andrew

I've been doing some work on it, but I had to drop it due to lack of time and lack of implementation skills (I can't compilers). I'm attaching a draft.
 
I talked about it with Zach Laine at CppCon last year. Zach sent me a draft of a paper he and Andrew Sutton were writing. Not sure I can share the draft, anyway our approaches are quite different.
 
If anyone with enough time and skills to hack on Clang and/or GCC is willing to help, I can consider investing more effort on this paper. Anyway this is definitely something beyond C++17.
 
Andy

     Thank you both a lot for the effort you’ve put into this!  I’m very glad to see that you have some new papers on this topic in the works, and I look forward to seeing them evolve even though the feature they propose probably won’t be added into C++17.  I do have one comment for you on the attachment you posted, though, Andy (Prowl, not Sutton:)  it seems that it has been truncated!  I was trying to follow one of the references from the beginning of the PDF to the bibliography, which is, if I remember correctly, on page 85 or so, but, strangely enough, the text seems to come to an end at page 71 or so, so could you look into fixing that?  Perhaps re-uploading the file might do the trick…

— Bryce Glover
Reply all
Reply to author
Forward
0 new messages