Changes between Initial Version and Version 1 of Ticket #9525, comment 1
- Timestamp:
- Dec 31, 2013, 2:28:46 PM (9 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
Ticket #9525, comment 1
initial v1 4 4 > Not to mention this isn't reflected anywhere in the documentation. 5 5 6 Do you use std::vector? If yes, I'm wondering what you get when you run something to the effect of *std::vector::end()? Last time I accidentally did that I got an assertion in DEBUG mode. I RELEASE mode, on most platforms the aforementioned statement would have done the wrong thing and returned the contents of an invalid memory location. IIRC, the standardsays that the iterator you get from vector::end() must not be dereferenced.6 Do you use std::vector? If yes, I'm wondering what you get when you dereference the return value of std::vector::end()? Last time I accidentally did that I got an assertion in DEBUG mode. I RELEASE mode, on most platforms dereferencing the return value of std::vector::end() does the wrong thing and return the contents of an invalid memory location. IIRC, the standard just says that the iterator you get from vector::end() must not be dereferenced. 7 7 8 8 I would argue that it's an almost identical situation with the simple_state::context() function. The reference docs say that you can't call this function in the constructor of a simple_state subclass: