[#issue-31] enable c++11 support to use r-value semantics