unsigned char is not undefined. That being the case, if adopted, this proposal would continue to consider it a special case and would thus permit unsigned char a; auto b = a; in constexpr. Doesn't this imply that multiple calls to a constexpr function at compile-time with the same exact arguments, can lead to different results? I believe this is novel for constexpr functions (other supposed tricks that do so do not actually have this property). Would we disallow this from actually forming a core constant expression, or perhaps make it so that it produces consistent results if being constant evaluated?
On Wed, Nov 28, 2018 at 11:56 AM 'CJ Johnson' via ISO C++ Standard - Future Proposals <std-pr...@isocpp.org> wrote:I mistakenly distributed this as P1331R0 before it was ready for the P designation. It was/is still in draft state and so I've changed it to D1331. Here's the new link: https://gist.github.com/CJ-Johnson/18485d3c5d60bdd0d2d5cae4fba7a045
On Sunday, November 11, 2018 at 10:51:59 AM UTC-5, CJ Johnson wrote:Hi everyone! I'd really appreciate feedback on this EWG/CWG feature/bug fix paper. You can view the Markdown file via Github Gist here: https://gist.github.com/CJ-Johnson/cc5cf8ce5b6eba0114e23182daa8e6deAny comments, concerns, edits or whatever else would be very much appreciated. I'm a library developer and new to ISO Cpp standards work so I'm learning as I go.I am fond of this paper, however there is an interesting note at the end:Note: Reading uninitialized instances ofunsigned charis not undefined. That being the case, if adopted, this proposal would continue to consider it a special case and would thus permitunsigned char a; auto b = a;in constexpr.Doesn't this imply that multiple calls to a constexpr function at compile-time with the same exact arguments, can lead to different results?
I believe this is novel for constexpr functions (other supposed tricks that do so do not actually have this property). Would we disallow this from actually forming a core constant expression, or perhaps make it so that it produces consistent results if being constant evaluated?
--
You received this message because you are subscribed to the Google Groups "ISO C++ Standard - Future Proposals" group.
To unsubscribe from this group and stop receiving emails from it, send an email to std-proposal...@isocpp.org.
To post to this group, send email to std-pr...@isocpp.org.
To view this discussion on the web visit https://groups.google.com/a/isocpp.org/d/msgid/std-proposals/CANh8DEmy9uUrNp4yAX7f%3DOc4p%3DqVqeS0fN11bFVBwtaZ%3Dbu%3DdQ%40mail.gmail.com.
To view this discussion on the web visit https://groups.google.com/a/isocpp.org/d/msgid/std-proposals/790ba68a-bdbd-48bc-8f84-d71a44ba5c77%40isocpp.org.