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 20041 - CTFE incorrect result with __vector #12057
Conversation
Thanks for your pull request, @WalterBright! Bugzilla references
Testing this PR locallyIf you don't have a local development environment setup, you can use Digger to test this PR: dub run digger -- build "master + dmd#12057" |
34cce56
to
5327d96
Compare
@@ -38,6 +38,7 @@ import dmd.identifier; | |||
import dmd.init; | |||
import dmd.initsem; | |||
import dmd.mtype; | |||
import dmd.printast; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
import dmd.printast; | |
debug import dmd.printast; |
Or delete ;)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I keep needing to add it back in. It doesn't hurt to leave it in.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
With debug
you don't have to remove it. It will be there just for your local debugging, but not compiled in the final release.
The same applies for all these printf
lines, which could be prefixed with debug (ctfe)
or something like that, so that you don't need to manually comment/uncomment them.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
One of the new developers on my team (who was primary a TypeScript developer before joining the team), told me that his favorite D feature is the ability to do:
debug import std.stdio : writeln, writefln;
//...
debug
{
// various writefln/writeln debug statements...
writeln(...);
}
;)
All bug fixes should target the
Let me expand the first step a bit, as I've seen people sometimes run into troubles with it:
This may sound like quite the process, but I'm just being extra verbose, to make sure we don't miss something. Once you know that your git fetch upstream master stable
git rebase --onto upstream/stable upstream/master |
That said, @WalterBright I'd be happy to do the rebasing for you if you don't want to mess with it now. |
@PetarKirov Thanks for the explicit instructions. I'll take you up on your kind offer to do it for me! :-) |
All done! There was a merge conflict in |
Apparently this relies on other fixes to master. So it should move back to master. |
@PetarKirov can you please update the rebase to stable instructions with your new version? Thanks! |
Took me a lot longer that it should have to find the source of this problem. CTFE is much too complicated.