Guest User

Untitled

a guest
Apr 21st, 2018
68
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.24 KB | None | 0 0
  1. #include <thebc/array.hpp>
  2.  
  3. int main() {
  4. char buf[256];
  5. thebc::array<char, 128> arr;
  6.  
  7. std::memcpy( arr.data(), buf, 128 );
  8. arr.validate(); // no problems
  9.  
  10. std::memcpy( arr.data(), buf, 129 );
  11. arr.validate(); // assertion failure
  12. }
Add Comment
Please, Sign In to add comment