SFML - Access Violation Error?

  • (2 Pages)
  • +
  • 1
  • 2

15 Replies - 1221 Views - Last Post: 10 January 2013 - 09:01 AM Rate Topic: -----

#16 vividexstance  Icon User is online

  • D.I.C Lover
  • member icon

Reputation: 651
  • View blog
  • Posts: 2,232
  • Joined: 31-December 10

Re: SFML - Access Violation Error?

Posted 10 January 2013 - 09:01 AM

View PostGryphonClaws, on 10 January 2013 - 03:11 AM, said:

Yeah, I remember now, I changed x and y from 0 to 1 by using the 'Undo' command too many times, but I never checked it. Why didn't I get an out of range error instead of a access violation?

With vector's you can use the vector::at() member function to throw an out-of-range exception instead of using the subscript operator which doesn't check if the index is out-of-range.
Was This Post Helpful? 0
  • +
  • -

  • (2 Pages)
  • +
  • 1
  • 2