This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/79950] G++ cannot detect simple off by one error in STL classes
- From: "redi at gcc dot gnu.org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Wed, 08 Mar 2017 14:30:52 +0000
- Subject: [Bug c++/79950] G++ cannot detect simple off by one error in STL classes
- Auto-submitted: auto-generated
- References: <bug-79950-4@http.gcc.gnu.org/bugzilla/>
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=79950
--- Comment #2 from Jonathan Wakely <redi at gcc dot gnu.org> ---
The C++ front-end could be taught about std::vector::size() as a special case,
but that would only help that special case, it wouldn't help for
std::deque::size(), or boost::vector::size() or other types.