Re: [C++17] Implement N3928 - Extending static_assert

2015-08-04 Thread Paolo Carlini
Hi, On 06/24/2015 05:32 PM, Ed Smith-Rowland wrote: Index: testsuite/g++.dg/cpp1z/static_assert-nomsg.C === --- testsuite/g++.dg/cpp1z/static_assert-nomsg.C(revision 0) +++ testsuite/g++.dg/cpp1z/static_assert-nomsg.C

Re: [C++17] Implement N3928 - Extending static_assert

2015-06-24 Thread Ed Smith-Rowland
On 06/17/2015 03:22 PM, Jason Merrill wrote: On 06/17/2015 01:53 PM, Ed Smith-Rowland wrote: I tried the obvious: an error message with %qE and got 'false'. constexpr values are evaluated early on. Is there a possibility that late folding could help or is that completely different? Late foldi

Re: [C++17] Implement N3928 - Extending static_assert

2015-06-17 Thread Jason Merrill
On 06/17/2015 01:53 PM, Ed Smith-Rowland wrote: I tried the obvious: an error message with %qE and got 'false'. constexpr values are evaluated early on. Is there a possibility that late folding could help or is that completely different? Late folding could help, but I think handling it in libc

Re: [C++17] Implement N3928 - Extending static_assert

2015-06-17 Thread Ed Smith-Rowland
On 06/17/2015 10:23 AM, Jason Merrill wrote: On 06/15/2015 07:14 PM, Ed Smith-Rowland wrote: I wanted to fix it up as per your suggestion. If someone wants it now I can retest and commit. Otherwise give me a bit more time. Someone in LWG was asking about it, and I figured it wouldn't hurt to

Re: [C++17] Implement N3928 - Extending static_assert

2015-06-17 Thread Jason Merrill
On 06/15/2015 07:14 PM, Ed Smith-Rowland wrote: I wanted to fix it up as per your suggestion. If someone wants it now I can retest and commit. Otherwise give me a bit more time. Someone in LWG was asking about it, and I figured it wouldn't hurt to have this version in now. Glad to hear you'

Re: [C++17] Implement N3928 - Extending static_assert

2015-06-15 Thread Ed Smith-Rowland
On 06/15/2015 12:05 PM, Jason Merrill wrote: On 05/20/2015 11:28 AM, Jason Merrill wrote: On 05/02/2015 04:16 PM, Ed Smith-Rowland wrote: This extends' static assert to not require a message string. I elected to make this work also for C++11 and C++14 and warn only with -pedantic. I think many

Re: [C++17] Implement N3928 - Extending static_assert

2015-06-15 Thread Jason Merrill
On 05/20/2015 11:28 AM, Jason Merrill wrote: On 05/02/2015 04:16 PM, Ed Smith-Rowland wrote: This extends' static assert to not require a message string. I elected to make this work also for C++11 and C++14 and warn only with -pedantic. I think many people just write static_assert(thing, "");

Re: [C++17] Implement N3928 - Extending static_assert

2015-05-20 Thread Jason Merrill
On 05/02/2015 04:16 PM, Ed Smith-Rowland wrote: This extends' static assert to not require a message string. I elected to make this work also for C++11 and C++14 and warn only with -pedantic. I think many people just write static_assert(thing, ""); . I took the path of building an empty strin

[PING] [C++17] Implement N3928 - Extending static_assert

2015-05-19 Thread Ed Smith-Rowland
On 05/02/2015 04:16 PM, Ed Smith-Rowland wrote: This extends' static assert to not require a message string. I elected to make this work also for C++11 and C++14 and warn only with -pedantic. I think many people just write static_assert(thing, ""); . I took the path of building an empty stri

Re: [C++17] Implement N3928 - Extending static_assert

2015-05-04 Thread Marek Polacek
On Sat, May 02, 2015 at 04:16:18PM -0400, Ed Smith-Rowland wrote: > This extends' static assert to not require a message string. > I elected to make this work also for C++11 and C++14 and warn only with > -pedantic. > I think many people just write > static_assert(thing, ""); > . > > I took the

[C++17] Implement N3928 - Extending static_assert

2015-05-02 Thread Ed Smith-Rowland
This extends' static assert to not require a message string. I elected to make this work also for C++11 and C++14 and warn only with -pedantic. I think many people just write static_assert(thing, ""); . I took the path of building an empty string in the parser in this case. I wasn't sure if s