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

Deduplicate mock_trait Macro #7

Closed
DonaldWhyte opened this issue Aug 3, 2017 · 1 comment
Closed

Deduplicate mock_trait Macro #7

DonaldWhyte opened this issue Aug 3, 2017 · 1 comment

Comments

@DonaldWhyte
Copy link
Owner

Currently, the mock_trait has two duplicate definitions. One is for private mocks and the other is for public (pub) mocks.

As shown by the following Rust issue, there is currently no way to define a single macro that has an optional (i.e. 0-or-1) token to be included:

rust-lang/rust#18317

This issue is here so we don't forget to deduplicate this macro when the relevant changes have been made to Rust to allow optional tokens.

Originated from PR: #6

@DonaldWhyte
Copy link
Owner Author

I'm closing this issue. #10 has just landed, which mostly removes most of the duplicated code in mock_trait! caused by the pub/non-pub versions.

I don't think there's a reason to wait for issue rust-lang/rust#18317 to be resolved for this, since most of the duplicated has been removed now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant