Fix incompatibility with Boost 1.56

The fix is based on the proposal of Andrew McMahon (@McDamon, #864).