Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[rpc] AsyncRPCOperation: std::move instead of assignment #33

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

ch4ot1c
Copy link
Contributor

@ch4ot1c ch4ot1c commented Jul 14, 2018

No description provided.

@ch4ot1c ch4ot1c changed the title AsyncRPCOperation: std::move instead of assignment [rpc] AsyncRPCOperation: std::move instead of assignment Jul 15, 2018
Copy link
Contributor

@jc23424 jc23424 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

utACK

Can consider upstreaming to zcash part of this commit

// Set a unique reference for each operation
boost::uuids::uuid uuid = uuidgen();
id_ = "opid-" + boost::uuids::to_string(uuid);
creation_time_ = (int64_t)time(NULL);

set_state(OperationStatus::READY);
}

AsyncRPCOperation::AsyncRPCOperation(const AsyncRPCOperation& o) :
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

should consider getting rid of this copy constructor too for same reason

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done

@ch4ot1c ch4ot1c force-pushed the improvement/AsyncRPCOperation-assignment branch 2 times, most recently from cba6ca1 to 0a6f2f1 Compare July 15, 2018 22:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants