[Bug c++/10541] [DR 354] Is NULL a valid pointer-type template argument?

2017-02-27 Thread msebor at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=10541

Martin Sebor  changed:

   What|Removed |Added

 Status|NEW |RESOLVED
  Known to work||5.3.0, 6.3.0, 7.0
 Resolution|--- |FIXED

--- Comment #13 from Martin Sebor  ---
I believe this now works correctly.  In C++ 11 mode and beyond the test case
from comment #6 is accepted and in C++ 98 mode it's rejected with the error
below.  Resolving as fixed.

$ cat t.C && gcc -S -Wall -Wextra -Wpedantic -std=c++98 t.C
template  class T {};
T t;
t.C:2:28: error: a cast to a type other than an integral or enumeration type
cannot appear in a constant-expression
 T t;
^
t.C:2:29: error: template argument 1 is invalid
 T t;
 ^

[Bug c++/10541] [DR 354] Is NULL a valid pointer-type template argument?

2013-11-15 Thread paolo.carlini at oracle dot com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=10541

Paolo Carlini paolo.carlini at oracle dot com changed:

   What|Removed |Added

 CC||jeffp at doomsday dot org

--- Comment #12 from Paolo Carlini paolo.carlini at oracle dot com ---
*** Bug 26205 has been marked as a duplicate of this bug. ***


[Bug c++/10541] [DR 354] Is NULL a valid pointer-type template argument?

2013-09-02 Thread paolo.carlini at oracle dot com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=10541

Paolo Carlini paolo.carlini at oracle dot com changed:

   What|Removed |Added

 Status|ASSIGNED|NEW


[Bug c++/10541] [DR 354] Is NULL a valid pointer-type template argument?

2012-12-05 Thread paolo.carlini at oracle dot com


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=10541



Paolo Carlini paolo.carlini at oracle dot com changed:



   What|Removed |Added



 CC|gcc-bugs at gcc dot gnu.org |



--- Comment #11 from Paolo Carlini paolo.carlini at oracle dot com 2012-12-05 
18:46:11 UTC ---

In C++11 mode we now accept these expressions. Not sure if we still want to

implement this old special case in C++98 mode.


[Bug c++/10541] [DR 354] Is NULL a valid pointer-type template argument?

2011-05-05 Thread rguenth at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=10541

Richard Guenther rguenth at gcc dot gnu.org changed:

   What|Removed |Added

 CC||boostcpp at gmail dot com

--- Comment #10 from Richard Guenther rguenth at gcc dot gnu.org 2011-05-05 
10:29:50 UTC ---
*** Bug 48871 has been marked as a duplicate of this bug. ***


[Bug c++/10541] [DR 354] Is NULL a valid pointer-type template argument?

2009-11-25 Thread jason at gcc dot gnu dot org


-- 

jason at gcc dot gnu dot org changed:

   What|Removed |Added

 AssignedTo|unassigned at gcc dot gnu   |jason at gcc dot gnu dot org
   |dot org |
 Status|NEW |ASSIGNED
   Last reconfirmed|2007-09-03 17:29:38 |2009-11-25 22:43:39
   date||


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=10541



[Bug c++/10541] [DR 354] Is NULL a valid pointer-type template argument?

2007-09-03 Thread mec at google dot com


--- Comment #8 from mec at google dot com  2007-09-03 15:47 ---
DR 354 has been in state WP since October 2005.  Is that good enough to
unsuspend this issue?

http://www.open-std.org/jtc1/sc22/wg21/docs/cwg_defects.html#354


-- 

mec at google dot com changed:

   What|Removed |Added

 CC||mec at google dot com


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=10541



[Bug c++/10541] [DR 354] Is NULL a valid pointer-type template argument?

2007-09-03 Thread pinskia at gcc dot gnu dot org


--- Comment #9 from pinskia at gcc dot gnu dot org  2007-09-03 17:29 ---
 DR 354 has been in state WP since October 2005.  Is that good enough to
 unsuspend this issue?

Yes.


-- 

pinskia at gcc dot gnu dot org changed:

   What|Removed |Added

 Status|SUSPENDED   |NEW
   Last reconfirmed|2005-12-11 23:08:05 |2007-09-03 17:29:38
   date||


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=10541