use static_pointer_cast (boost 1.53 compatibility)