This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug libstdc++/23781] Implicit conversion from NULL to list<T>::iterator
- From: "pcarlini at suse dot de" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 8 Sep 2005 21:06:28 -0000
- Subject: [Bug libstdc++/23781] Implicit conversion from NULL to list<T>::iterator
- References: <20050908155521.23781.Marc.Boyer@enseeiht.fr>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Additional Comments From pcarlini at suse dot de 2005-09-08 21:06 -------
(In reply to comment #2)
> We don't accept
>
> #include <vector>
> #include <string>
>
> int main()
> {
> using namespace std;
> vector<string>::iterator p = NULL;
> }
>
> for proper type checking. The list iterator constructor accepting a
> pointer should be explicit.
Agreed. Likewise for deque::iterator, I suppose. I will work on this.
--
What |Removed |Added
----------------------------------------------------------------------------
AssignedTo|unassigned at gcc dot gnu |pcarlini at suse dot de
|dot org |
Status|UNCONFIRMED |ASSIGNED
Ever Confirmed| |1
Last reconfirmed|0000-00-00 00:00:00 |2005-09-08 21:06:28
date| |
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=23781