From 94f7a5bd3051906e2fd7de270bf7fc9b088909ac Mon Sep 17 00:00:00 2001 From: Tim Blechmann Date: Sat, 8 Sep 2012 16:36:11 +0000 Subject: [PATCH] atomic: fix const-correctnes of double-width load [SVN r80454] --- include/boost/atomic/detail/gcc-x86.hpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/include/boost/atomic/detail/gcc-x86.hpp b/include/boost/atomic/detail/gcc-x86.hpp index a1c9867..ea3d651 100644 --- a/include/boost/atomic/detail/gcc-x86.hpp +++ b/include/boost/atomic/detail/gcc-x86.hpp @@ -1556,11 +1556,11 @@ platform_store64(T value, volatile T * ptr) template T -platform_load64(volatile T * ptr) +platform_load64(const volatile T * ptr) { T expected = *ptr; do { - } while (!platform_cmpxchg64_strong(expected, expected, ptr)); + } while (!platform_cmpxchg64_strong(expected, expected, const_cast(ptr))); return expected; }