Split get_default() into two for deferred default construction and added...
Split get_default() into two for deferred default construction and added forwarding to speed up default element construction with rvalues Summary: As it stood currently folly::get_default() would unnecessarily construct a value into the third parameter, which was unnecessary in the code path where the element was found in the map. Also the default value can be forwarded to the return type in the code path where the element is not found and an rvalue parameter is passed as the default value Reviewed By: yfeldblum Differential Revision: D6390315 fbshipit-source-id: ef692b827d5a36751b4eb1e12042869e8fbba2e5
Showing
Please register or sign in to comment