allocator_wrapper should return NULL instead of propagating exceptions
add more attributes to allocation functions, fix #530