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

Fix Issue 19775 - multiple argument string mixin doesn't expand tuples #9521

Merged
merged 1 commit into from
Apr 5, 2019

Conversation

ntrel
Copy link
Contributor

@ntrel ntrel commented Mar 30, 2019

No description provided.

@dlang-bot
Copy link
Contributor

Thanks for your pull request and interest in making D better, @ntrel! We are looking forward to reviewing it, and you should be hearing from a maintainer soon.
Please verify that your PR follows this checklist:

  • My PR is fully covered with tests (you can see the annotated coverage diff directly on GitHub with CodeCov's browser extension
  • My PR is as minimal as possible (smaller, focused PRs are easier to review than big ones)
  • I have provided a detailed rationale explaining my changes
  • New or modified functions have Ddoc comments (with Params: and Returns:)

Please see CONTRIBUTING.md for more information.


If you have addressed all reviews or aren't sure how to proceed, don't hesitate to ping us with a simple comment.

Bugzilla references

Auto-close Bugzilla Severity Description
19775 normal multiple argument string mixin doesn't expand tuples

Testing this PR locally

If you don't have a local development environment setup, you can use Digger to test this PR:

dub fetch digger
dub run digger -- build "master + dmd#9521"

@ntrel ntrel force-pushed the mixin-tuple branch 2 times, most recently from 7d2b704 to 49201b1 Compare March 30, 2019 18:24
@thewilsonator
Copy link
Contributor

compilable/b19775.d-mixin-3(3): Error: function expected before `()`, not `42` of type `int`
compilable/b19775.d(5): Error: template instance `b19775.ident!"x1"` error instantiating
compilable/b19775.d(10):        while evaluating: `static assert(x2 == 42)`
compilable/b19775.d(11):        while evaluating: `static assert(x3 == 42)`
compilable/b19775.d(12):        while evaluating: `static assert(x4 == 42)`
compilable/b19775.d(13):        while evaluating: `static assert(x5 == 42)`

enum ident(alias a, args...) = mixin(a, args);

//enum x2 = ident!("x1"); //FIXME - empty args
enum x2 = x1;
Copy link
Contributor Author

Choose a reason for hiding this comment

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

For now I've given up on getting an empty sequence to be ignored by mixin(). It still gets turned into "()".

@ntrel
Copy link
Contributor Author

ntrel commented Apr 5, 2019

@thewilsonator I fixed the test failures, except I don't know why semaphoreci is failing.

@thewilsonator
Copy link
Contributor

Semaphore occasionally fails with reproducibility test, dunno why.

@dlang-bot dlang-bot merged commit 6e33159 into dlang:master Apr 5, 2019
@ntrel ntrel deleted the mixin-tuple branch April 6, 2019 10:23
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.

4 participants